Skip to content

Commit

Permalink
Merge pull request #54475 from wojtek-t/automated-cherry-pick-of-#544…
Browse files Browse the repository at this point in the history
…03-upstream-release-1.7

Automatic merge from submit-queue.

Automated cherry pick of #54403 upstream release 1.7 

Cherrypick of #54403 to the 1.7 branch
#54403: Allow for configuring etcd hostname in the manifest
  • Loading branch information
Kubernetes Submit Queue committed Oct 24, 2017
2 parents b78915a + 87a07f4 commit 7b9aded
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions cluster/common.sh
Expand Up @@ -800,6 +800,11 @@ EOF
if [ -n "${ETCD_VERSION:-}" ]; then
cat >>$file <<EOF
ETCD_VERSION: $(yaml-quote ${ETCD_VERSION})
EOF
fi
if [ -n "${ETCD_HOSTNAME:-}" ]; then
cat >>$file <<EOF
ETCD_HOSTNAME: $(yaml-quote ${ETCD_HOSTNAME})
EOF
fi
if [ -n "${APISERVER_TEST_ARGS:-}" ]; then
Expand Down
2 changes: 1 addition & 1 deletion cluster/gce/configure-vm.sh
Expand Up @@ -446,7 +446,7 @@ kube_uid: '$(echo "${KUBE_UID}" | sed -e "s/'/''/g")'
initial_etcd_cluster: '$(echo "${INITIAL_ETCD_CLUSTER:-}" | sed -e "s/'/''/g")'
initial_etcd_cluster_state: '$(echo "${INITIAL_ETCD_CLUSTER_STATE:-}" | sed -e "s/'/''/g")'
ca_cert_bundle_path: '$(echo "${CA_CERT_BUNDLE_PATH:-}" | sed -e "s/'/''/g")'
hostname: $(hostname -s)
hostname: '$(echo "${ETCD_HOSTNAME:-$(hostname -s)}" | sed -e "s/'/''/g")'
enable_default_storage_class: '$(echo "$ENABLE_DEFAULT_STORAGE_CLASS" | sed -e "s/'/''/g")'
EOF
if [ -n "${STORAGE_BACKEND:-}" ]; then
Expand Down
2 changes: 1 addition & 1 deletion cluster/gce/container-linux/configure-helper.sh
Expand Up @@ -660,7 +660,7 @@ function start-kube-proxy {
# $4: value for variable 'cpulimit'
# $5: pod name, which should be either etcd or etcd-events
function prepare-etcd-manifest {
local host_name=$(hostname -s)
local host_name=${ETCD_HOSTNAME:-$(hostname -s)}
local etcd_cluster=""
local cluster_state="new"
local etcd_protocol="http"
Expand Down
2 changes: 1 addition & 1 deletion cluster/gce/gci/configure-helper.sh
Expand Up @@ -1029,7 +1029,7 @@ function start-kube-proxy {
# $4: value for variable 'cpulimit'
# $5: pod name, which should be either etcd or etcd-events
function prepare-etcd-manifest {
local host_name=$(hostname)
local host_name=${ETCD_HOSTNAME:-$(hostname -s)}
local etcd_cluster=""
local cluster_state="new"
local etcd_protocol="http"
Expand Down

0 comments on commit 7b9aded

Please sign in to comment.