-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
指定 --kubeadm-config string 配置文件初始化集群问题 #75
Comments
@fanux
让用户自定义修改这个模板。如果不传入kubeadm-config参数就走咱默认的。可行? |
sealos generator -t kubeadm-config //生成模板文件 |
可以, 名字改成generate
|
https://github.com/fanux/sealos/releases/tag/v2.0.4 download v2.0.4 to solve this problem |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
因为集群需要通过外网访问APIserver,当执行初始化集群的时候指定 --kubeadm-config config.yaml 配置,sealos还是使用默认参数重新渲染了一次kubeadm的配置,导致自定义的floatingip参数被覆盖掉。
初始化命令
sealos init --kubeadm-config kubeadm-config.yaml --master 172.16.10.31 --master 172.16.10.32 --master 172.16.10.33 --node 172.16.10.34 --user root --passwd redhat --pkg-url kube1.14.4.tar.gz --version v1.14.4
相关日志
2019-07-28 03:58:30 [DEBG] [github.com/fanux/sealos/install/send_package.go:36] please wait for tar zxvf exec
2019-07-28 03:58:30 [INFO] [github.com/fanux/sealos/install/utils.go:81] 172.16.10.32 ls -l /root | grep kube1.14.4.tar.gz | wc -l
2019-07-28 03:58:30 [DEBG] [github.com/fanux/sealos/install/send_package.go:56] please wait for tar zxvf exec
2019-07-28 03:58:30 [INFO] [github.com/fanux/sealos/install/utils.go:81] 172.16.10.34 ls -l /root | grep kube1.14.4.tar.gz | wc -l
2019-07-28 03:58:30 [DEBG] [github.com/fanux/sealos/install/send_package.go:36] please wait for tar zxvf exec
2019-07-28 03:58:30 [INFO] [github.com/fanux/sealos/install/utils.go:81] 172.16.10.33 ls -l /root | grep kube1.14.4.tar.gz | wc -l
2019-07-28 03:58:30 [DEBG] [github.com/fanux/sealos/install/send_package.go:36] please wait for tar zxvf exec
2019-07-28 03:58:30 [INFO] [github.com/fanux/sealos/install/utils.go:81] 172.16.10.31 ls -l /root | grep kube1.14.4.tar.gz | wc -l
2019-07-28 03:58:30 [DEBG] [github.com/fanux/sealos/install/utils.go:90] command result is: 1
...
...
2019-07-28 03:59:48 [INFO] [github.com/fanux/sealos/install/utils.go:81] 172.16.10.31 echo "apiVersion: kubeadm.k8s.io/v1beta1
kind: ClusterConfiguration
kubernetesVersion: v1.14.4
controlPlaneEndpoint: apiserver.cluster.local:6443
networking:
podSubnet: 100.64.0.0/10
apiServer:
certSANs:
- 127.0.0.1
- apiserver.cluster.local
- 172.16.10.31
- 172.16.10.32
- 172.16.10.33
- 10.103.97.2
- 172.16.10.100
- k8s-cluster.viken.local
apiVersion: kubeproxy.config.k8s.io/v1alpha1
kind: KubeProxyConfiguration
mode: ipvs
ipvs:
excludeCIDRs:
- 10.103.97.2/32
" > /root/kubeadm-config.yaml
2019-07-28 03:59:48 [DEBG] [github.com/fanux/sealos/install/utils.go:90] command result is:
2019-07-28 03:59:48 [INFO] [github.com/fanux/sealos/install/utils.go:81] 172.16.10.31 echo 172.16.10.31 apiserver.cluster.local >> /etc/hosts
2019-07-28 03:59:48 [DEBG] [github.com/fanux/sealos/install/utils.go:90] command result is:
2019-07-28 03:59:48 [INFO] [github.com/fanux/sealos/install/utils.go:81] 172.16.10.31 echo "apiVersion: kubeadm.k8s.io/v1beta1
kind: ClusterConfiguration
kubernetesVersion: v1.14.4
controlPlaneEndpoint: "apiserver.cluster.local:6443"
networking:
podSubnet: 100.64.0.0/10
apiServer:
certSANs:
- 127.0.0.1
- apiserver.cluster.local
- 172.16.10.31
- 172.16.10.32
- 172.16.10.33
- 10.103.97.2
apiVersion: kubeproxy.config.k8s.io/v1alpha1
kind: KubeProxyConfiguration
mode: "ipvs"
ipvs:
excludeCIDRs:
- "10.103.97.2/32"" > /root/kubeadm-config.yaml
2019-07-28 03:59:48 [DEBG] [github.com/fanux/sealos/install/utils.go:90] command result is:
这里sealos第两次渲染把 kubeadm-config.yaml 自定义参数给覆盖掉了。
The text was updated successfully, but these errors were encountered: