You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
opts.on('-o','--os-type os-type','the os that kubernetes will run on')do |os|
23
-
options[:os]=os;
24
-
end
25
-
26
-
opts.on('-v','--version version','the kubernetes version to install')do |version|
27
-
options[:version]=version;
28
-
end
29
-
30
-
opts.on('-r','--container_runtime container runtime','the container runtime to use. this can only be docker or cri_containerd')do |container_runtime|
31
-
options[:container_runtime]=container_runtime;
32
-
end
33
-
34
-
opts.on('-c','--cni-provider cni-provider','the networking provider to use, flannel, weave, calico or cilium are supported')do |cni_provider|
35
-
options[:cni_provider]=cni_provider;
36
-
end
37
-
opts.on('-p','--cni-provider-version [cni_provider_version]','the networking provider version to use, calico and cilium will use this to reference the correct deployment download link')do |cni_provider_version|
opts.on('-t','--etcd-ip etcd_ip','ip address etcd will listen on')do |etcd_ip|
46
-
options[:etcd_ip]=etcd_ip;
47
-
end
48
-
49
-
opts.on('-a','--api-address api_address','the ip address that kube api will listen on')do |api_address|
50
-
options[:kube_api_advertise_address]=api_address;
51
-
end
52
-
53
-
opts.on('-b','--key-size key_size','Specifies the number of bits in the key to create')do |key_size|
54
-
options[:key_size]=key_size
55
-
end
56
-
57
-
opts.on('-d','--install-dashboard dashboard','install the kube dashboard')do |dashboard|
58
-
options[:install_dashboard]=dashboard;
59
-
end
60
-
61
-
opts.on('-h','--help','Displays Help')do
62
-
putsopts
63
-
exit
9
+
classKube_tool
10
+
defself.parse_args
11
+
begin
12
+
opts=Slop.parsedo |o|
13
+
o.string'-o','--os','The OS that Kubernetes will run on',default: ENV['OS']
14
+
o.string'-v','--version','The Kubernetes version to install',default: ENV['VERSION']
15
+
o.string'-r','--container_runtime','The container runtime to use. This can only be "docker" or "cri_containerd"',default: ENV['CONTAINER_RUNTIME']
16
+
o.string'-c','--cni_provider','The networking provider to use, flannel, weave, calico, calico-tigera or cilium are supported',default: ENV['CNI_PROVIDER']
17
+
o.string'-p','--cni_provider_version','The networking provider version to use, calico and cilium will use this to reference the correct deployment download link',default: ENV['CNI_PROVIDER_VERSION']
18
+
o.string'-t','--etcd_ip','The IP address etcd will listen on',default: ENV['ETCD_IP']
19
+
o.string'-i','--etcd_initial_cluster','The list of servers in the etcd cluster',default: ENV['ETCD_INITIAL_CLUSTER']
20
+
o.string'-a','--api_address','The IP address (or fact) that kube api will listen on',default: ENV['KUBE_API_ADVERTISE_ADDRESS']
21
+
o.int'-b','--key_size','Specifies the number of bits in the key to create',default: ENV['KEY_SIZE'].to_i
22
+
o.int'--ca_algo','Algorithm to generate CA certificates, default: ecdsa',default: ENV['CA_ALGO']
0 commit comments