简体   繁体   English

如何创建自定义 Snapcraft 频道?

[英]How to create a custom Snapcraft channel?

I can only even find a couple places in the docs that suggests this is possible, but it clearly is possible.我什至只能在文档中找到几个地方表明这是可能的,但显然是可能的。

Moving a snap between channels helps to manage a user's expectations in any trade-off between stability in the stable channel, and cutting edge features in the edge channel (as an arbitrary example).在通道之间移动快照有助于管理用户在稳定通道中的稳定性和边缘通道中的尖端特征之间的任何权衡的期望(作为任意示例)。 But its also a useful technique for beta testing, or for when a snap needs to revert to a previous revision.但它也是一种有用的技术,用于beta 测试,或者当 snap 需要恢复到以前的版本时。 -- https://snapcraft.io/docs/release-management -- https://snapcraft.io/docs/release-management


Take for example kubectl (see below) which has a channel for each old minor version, in addition to the default latest channel.kubectl (见下文)为例,除了默认的latest频道外,它还为每个旧的次要版本都有一个频道。

We're about to release a new version which will not be compatible with Ubuntu 16.04 and below, and we'd like to make the old version available to those users.我们即将发布与 Ubuntu 16.04 及以下版本不兼容的新版本,我们希望将旧版本提供给这些用户。 How can we achieve that?我们怎样才能做到这一点?

❯ snap info kubectl
name:      kubectl
summary:   Command line client for controlling a Kubernetes cluster.
publisher: Canonical✓
store-url: https://snapcraft.io/kubectl
contact:   https://www.ubuntu.com/kubernetes
license:   Apache-2.0
description: [...]
snap-id: ZgG2URycDgvxSVskfoZxn44uaRMw0iwe
channels:
  latest/stable:    1.21.1         2021-05-14 (1976) 11MB classic
  latest/candidate: 1.21.1         2021-05-14 (1976) 11MB classic
  latest/beta:      1.21.1         2021-05-14 (1976) 11MB classic
  latest/edge:      1.21.1         2021-05-14 (1976) 11MB classic
  1.22/stable:      –                                     
  1.22/candidate:   –                                     
  1.22/beta:        –                                     
  1.22/edge:        1.22.0-alpha.1 2021-04-29 (1945) 11MB classic
  1.21/stable:      1.21.1         2021-05-13 (1976) 11MB classic
  1.21/candidate:   1.21.1         2021-05-13 (1976) 11MB classic
  1.21/beta:        1.21.1         2021-05-13 (1976) 11MB classic
  1.21/edge:        1.21.1         2021-05-13 (1976) 11MB classic
  1.20/stable:      1.20.7         2021-05-13 (1949)  9MB classic
  1.20/candidate:   1.20.7         2021-05-13 (1949)  9MB classic
  1.20/beta:        1.20.7         2021-05-13 (1949)  9MB classic
  1.20/edge:        1.20.7         2021-05-13 (1949)  9MB classic
  1.19/stable:      1.19.11        2021-05-13 (1947) 10MB classic
  1.19/candidate:   1.19.11        2021-05-13 (1947) 10MB classic
  1.19/beta:        1.19.11        2021-05-13 (1947) 10MB classic
  1.19/edge:        1.19.11        2021-05-13 (1947) 10MB classic
  1.18/stable:      1.18.19        2021-05-13 (1951) 10MB classic
  1.18/candidate:   1.18.19        2021-05-13 (1951) 10MB classic
  1.18/beta:        1.18.19        2021-05-13 (1951) 10MB classic
  1.18/edge:        1.18.19        2021-05-13 (1951) 10MB classic
  1.17/stable:      1.17.17        2021-01-15 (1777) 10MB classic
  1.17/candidate:   1.17.17        2021-01-15 (1777) 10MB classic
  1.17/beta:        1.17.17        2021-01-15 (1777) 10MB classic
  1.17/edge:        1.17.17        2021-01-15 (1777) 10MB classic
  1.16/stable:      1.16.15        2020-10-20 (1639) 10MB classic
  1.16/candidate:   1.16.15        2020-10-20 (1639) 10MB classic
  1.16/beta:        1.16.15        2020-10-20 (1639) 10MB classic
  1.16/edge:        1.16.15        2020-10-20 (1639) 10MB classic
  [...]

These are known as "Tracks".这些被称为“轨道”。 Each one has their own edge, beta, candidate, and stable channels.每个人都有自己的优势、beta、候选和稳定渠道。

There is a process that requires you to request new tracks via the forum.snapcraft.io discourse.有一个过程要求您通过 forum.snapcraft.io 话语请求新曲目。 See https://snapcraft.io/docs/process-for-aliases-auto-connections-and-tracks for more details on the procedure.有关该过程的更多详细信息,请参阅https://snapcraft.io/docs/process-for-aliases-auto-connections-and-tracks

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM