-
Notifications
You must be signed in to change notification settings - Fork 501
/
list.go
53 lines (40 loc) · 1.5 KB
/
list.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
package images
import (
"fmt"
criconfig "github.com/containerd/cri/pkg/config"
"github.com/talos-systems/talos/pkg/machinery/config"
"github.com/talos-systems/talos/pkg/version"
)
// Versions holds all the images (and their versions) that are used in Talos.
type Versions struct {
Etcd string
Flannel string
FlannelCNI string
CoreDNS string
Kubelet string
KubeAPIServer string
KubeControllerManager string
KubeProxy string
KubeScheduler string
Installer string
Pause string
}
// List returns default image versions.
func List(config config.Provider) Versions {
var images Versions
images.Etcd = config.Cluster().Etcd().Image()
images.CoreDNS = config.Cluster().CoreDNS().Image()
images.Flannel = "quay.io/coreos/flannel:v0.13.0"
images.FlannelCNI = fmt.Sprintf("ghcr.io/talos-systems/install-cni:%s", version.ExtrasVersion)
images.Kubelet = config.Machine().Kubelet().Image()
images.KubeAPIServer = config.Cluster().APIServer().Image()
images.KubeControllerManager = config.Cluster().ControllerManager().Image()
images.KubeProxy = config.Cluster().Proxy().Image()
images.KubeScheduler = config.Cluster().Scheduler().Image()
images.Installer = DefaultInstallerImage
images.Pause = criconfig.DefaultConfig().SandboxImage
return images
}