Skip to content
This repository has been archived by the owner on Sep 30, 2020. It is now read-only.

Commit

Permalink
Add networking-daemonsets feature
Browse files Browse the repository at this point in the history
  • Loading branch information
davidmccormick committed Mar 22, 2018
1 parent 05354e5 commit d0b6895
Show file tree
Hide file tree
Showing 9 changed files with 1,504 additions and 78 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ _book
*.mobi
*.pdf
node_modules
kube-aws
34 changes: 31 additions & 3 deletions core/controlplane/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@ const (

credentialsDir = "credentials"
userDataDir = "userdata"

NdsDefaultCalicoNodeImageTag = "v3.0.3"
NdsDefaultCalicoCniImageTag = "v2.0.1"
NdsDefaultFlannelImageTag = "v0.9.1"
NdsDefaultFlannelCniImageTag = "v0.3.0"
NdsDefaultTyphaImageTag = "v0.6.2"
)

func NewDefaultCluster() *Cluster {
Expand Down Expand Up @@ -114,6 +120,15 @@ func NewDefaultCluster() *Cluster {
UsernameClaim: "email",
GroupsClaim: "groups",
},
NetworkingDaemonSets: NetworkingDaemonSets{
Enabled: false,
Typha: false,
CalicoNodeImage: model.Image{Repo: "quay.io/calico/node", Tag: NdsDefaultCalicoNodeImageTag, RktPullDocker: false},
CalicoCniImage: model.Image{Repo: "quay.io/calico/cni", Tag: NdsDefaultCalicoCniImageTag, RktPullDocker: false},
FlannelImage: model.Image{Repo: "quay.io/coreos/flannel", Tag: NdsDefaultFlannelImageTag, RktPullDocker: false},
FlannelCniImage: model.Image{Repo: "quay.io/coreos/flannel-cni", Tag: NdsDefaultFlannelCniImageTag, RktPullDocker: false},
TyphaImage: model.Image{Repo: "quay.io/calico/typha", Tag: NdsDefaultTyphaImageTag, RktPullDocker: false},
},
}

ipvsMode := IPVSMode{
Expand Down Expand Up @@ -458,9 +473,11 @@ type DeploymentSettings struct {
KubeDns `yaml:"kubeDns,omitempty"`
KubernetesDashboard `yaml:"kubernetesDashboard,omitempty"`
// Images repository
HyperkubeImage model.Image `yaml:"hyperkubeImage,omitempty"`
AWSCliImage model.Image `yaml:"awsCliImage,omitempty"`
CalicoNodeImage model.Image `yaml:"calicoNodeImage,omitempty"`
HyperkubeImage model.Image `yaml:"hyperkubeImage,omitempty"`
AWSCliImage model.Image `yaml:"awsCliImage,omitempty"`

CalicoNodeImage model.Image `yaml:"calicoNodeImage,omitempty"`

CalicoCniImage model.Image `yaml:"calicoCniImage,omitempty"`
CalicoCtlImage model.Image `yaml:"calicoCtlImage,omitempty"`
CalicoKubeControllersImage model.Image `yaml:"calicoKubeControllersImage,omitempty"`
Expand Down Expand Up @@ -561,6 +578,7 @@ type Experimental struct {
DisableSecurityGroupIngress bool `yaml:"disableSecurityGroupIngress"`
NodeMonitorGracePeriod string `yaml:"nodeMonitorGracePeriod"`
model.UnknownKeys `yaml:",inline"`
NetworkingDaemonSets NetworkingDaemonSets `yaml:"networkingDaemonSets"`
}

type Admission struct {
Expand Down Expand Up @@ -675,6 +693,16 @@ type LocalStreaming struct {
interval int `yaml:"interval"`
}

type NetworkingDaemonSets struct {
Enabled bool `yaml:"enabled"`
Typha bool `yaml:"typha"`
CalicoNodeImage model.Image `yaml:"calico-node-image"`
CalicoCniImage model.Image `yaml:"calico-cni-image"`
FlannelImage model.Image `yaml:"flannel-image"`
FlannelCniImage model.Image `yaml:"flannel-cni-image"`
TyphaImage model.Image `yaml:"typha-image"`
}

func (c *LocalStreaming) Interval() int64 {
// Convert from seconds to milliseconds (and return as int64 type)
return int64(c.interval * 1000)
Expand Down
Loading

0 comments on commit d0b6895

Please sign in to comment.