Salt configuration to add basic auth to GCE.

This commit is contained in:
Robert Bailey
2015-04-27 22:39:39 -07:00
parent 01f201945d
commit 8206aa9eac
5 changed files with 39 additions and 4 deletions

View File

@@ -52,6 +52,7 @@
{% endif -%}
{% set token_auth_file = "--token_auth_file=/dev/null" -%}
{% set basic_auth_file = "" -%}
{% if grains.cloud is defined -%}
{% if grains.cloud in [ 'aws', 'gce', 'vagrant' ] -%}
@@ -59,6 +60,10 @@
{% endif -%}
{% endif -%}
{% if grains['cloud'] is defined and grains['cloud'] == 'gce' %}
{% set basic_auth_file = "--basic_auth_file=/srv/kubernetes/basic_auth.csv" -%}
{% endif -%}
{% set admission_control = "" -%}
{% if pillar['admission_control'] is defined -%}
{% set admission_control = "--admission_control=" + pillar['admission_control'] -%}
@@ -95,6 +100,7 @@
"--secure_port={{secure_port}}",
"{{token_auth_file}}",
"{{client_ca_file}}",
"{{basic_auth_file}}",
"{{publicAddressOverride}}",
"{{pillar['log_level']}}"
],