Skip to content

Commit

Permalink
Fix vagrant regression, add flag to easily enable v1beta3
Browse files Browse the repository at this point in the history
  • Loading branch information
derekwaynecarr committed Jan 30, 2015
1 parent 922148a commit 4dd50a1
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 1 deletion.
8 changes: 7 additions & 1 deletion cluster/saltbase/salt/kube-apiserver/default
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
{% set etcd_servers = "--etcd_servers=http://" + ips[0][0] + ":4001" -%}
{% endif -%}

{% set cloud_config = "" -%}
{% if grains.cloud is defined -%}
{% if grains.cloud == 'gce' -%}
{% set cloud_provider = "--cloud_provider=gce" -%}
Expand Down Expand Up @@ -55,4 +56,9 @@
{% set admission_control = "--admission_control=" + grains.admission_control -%}
{% endif -%}

DAEMON_ARGS="{{daemon_args}} {{address}} {{etcd_servers}} {{ cloud_provider }} {{ cloud_config }} {{admission_control}} --allow_privileged={{pillar['allow_privileged']}} {{portal_net}} {{cert_file}} {{key_file}} {{secure_port}} {{token_auth_file}} {{publicAddressOverride}} {{pillar['log_level']}}"
{% set runtime_config = "" -%}
{% if grains.runtime_config is defined -%}
{% set runtime_config = "--runtime_config=" + grains.runtime_config -%}
{% endif -%}

DAEMON_ARGS="{{daemon_args}} {{address}} {{etcd_servers}} {{ cloud_provider }} {{ cloud_config }} {{ runtime_config }} {{admission_control}} --allow_privileged={{pillar['allow_privileged']}} {{portal_net}} {{cert_file}} {{key_file}} {{secure_port}} {{token_auth_file}} {{publicAddressOverride}} {{pillar['log_level']}}"
4 changes: 4 additions & 0 deletions cluster/vagrant/config-default.sh
Original file line number Diff line number Diff line change
Expand Up @@ -66,3 +66,7 @@ ENABLE_CLUSTER_DNS=true
DNS_SERVER_IP="10.247.0.10"
DNS_DOMAIN="kubernetes.local"
DNS_REPLICAS=1

# Optional: Enable setting flags for kube-apiserver to turn on behavior in active-dev
RUNTIME_CONFIG=""
#RUNTIME_CONFIG="api/v1beta3"
1 change: 1 addition & 0 deletions cluster/vagrant/provision-master.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ grains:
roles:
- kubernetes-master
admission_control: AlwaysAdmit
runtime_config: '$(echo "$RUNTIME_CONFIG" | sed -e "s/'/''/g")'
EOF

mkdir -p /srv/salt-overlay/pillar
Expand Down
1 change: 1 addition & 0 deletions cluster/vagrant/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ function create-provision-scripts {
echo "ENABLE_CLUSTER_DNS='${ENABLE_CLUSTER_DNS:-false}'"
echo "DNS_SERVER_IP='${DNS_SERVER_IP:-}'"
echo "DNS_DOMAIN='${DNS_DOMAIN:-}'"
echo "RUNTIME_CONFIG='${RUNTIME_CONFIG:-}'"
grep -v "^#" "${KUBE_ROOT}/cluster/vagrant/provision-master.sh"
) > "${KUBE_TEMP}/master-start.sh"

Expand Down

0 comments on commit 4dd50a1

Please sign in to comment.