mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-04 18:00:08 +00:00
Merge pull request #5352 from zmerlynn/conditional_disk
Don't always run mount-master-pd
This commit is contained in:
commit
bc655681fe
@ -151,6 +151,10 @@ stop-salt-minion() {
|
|||||||
# formats an unformatted disk, and mkdir -p will leave a directory be if it
|
# formats an unformatted disk, and mkdir -p will leave a directory be if it
|
||||||
# already exists.
|
# already exists.
|
||||||
mount-master-pd() {
|
mount-master-pd() {
|
||||||
|
# TODO(zmerlynn): GKE is still lagging in master-pd creation
|
||||||
|
if [[ ! -e /dev/disk/by-id/google-master-pd ]]; then
|
||||||
|
return
|
||||||
|
fi
|
||||||
device_info=$(ls -l /dev/disk/by-id/google-master-pd)
|
device_info=$(ls -l /dev/disk/by-id/google-master-pd)
|
||||||
relative_path=${device_info##* }
|
relative_path=${device_info##* }
|
||||||
device_path="/dev/disk/by-id/${relative_path}"
|
device_path="/dev/disk/by-id/${relative_path}"
|
||||||
@ -200,7 +204,7 @@ enable_cluster_dns: '$(echo "$ENABLE_CLUSTER_DNS" | sed -e "s/'/''/g")'
|
|||||||
dns_replicas: '$(echo "$DNS_REPLICAS" | sed -e "s/'/''/g")'
|
dns_replicas: '$(echo "$DNS_REPLICAS" | sed -e "s/'/''/g")'
|
||||||
dns_server: '$(echo "$DNS_SERVER_IP" | sed -e "s/'/''/g")'
|
dns_server: '$(echo "$DNS_SERVER_IP" | sed -e "s/'/''/g")'
|
||||||
dns_domain: '$(echo "$DNS_DOMAIN" | sed -e "s/'/''/g")'
|
dns_domain: '$(echo "$DNS_DOMAIN" | sed -e "s/'/''/g")'
|
||||||
admission_control: '$(echo "$ADMISSION_CONTROL" | sed -e "s/'/''/g")'
|
admission_control: '$(echo "$ADMISSION_CONTROL" | sed -e "s/'/''/g")'
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
if [[ "${KUBERNETES_MASTER}" == "true" ]]; then
|
if [[ "${KUBERNETES_MASTER}" == "true" ]]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user