Merge pull request #16986 from pmorie/gce-sc

Auto commit by PR queue bot
This commit is contained in:
k8s-merge-robot 2015-11-10 11:15:27 -08:00
commit 18c74de9a8
3 changed files with 7 additions and 2 deletions

View File

@ -113,7 +113,7 @@ if [[ "${ENABLE_DAEMONSETS}" == "true" ]]; then
fi
# Admission Controllers to invoke prior to persisting objects in cluster
ADMISSION_CONTROL=NamespaceLifecycle,LimitRanger,SecurityContextDeny,ServiceAccount,ResourceQuota
ADMISSION_CONTROL=NamespaceLifecycle,LimitRanger,ServiceAccount,ResourceQuota
# Optional: if set to true kube-up will automatically check for existing resources and clean them up.
KUBE_UP_AUTOMATIC_CLEANUP=${KUBE_UP_AUTOMATIC_CLEANUP:-false}

View File

@ -713,7 +713,7 @@ function kube-up {
# curl in mavericks is borked.
secure=""
if which sw_vers > /dev/null; then
if which sw_vers >& /dev/null; then
if [[ $(sw_vers | grep ProductVersion | awk '{print $2}') = "10.9."* ]]; then
secure="--insecure"
fi

View File

@ -225,6 +225,7 @@ func ModifyConfig(configAccess ConfigAccess, newConfig clientcmdapi.Config, rela
configToWrite := getConfigFromFileOrDie(destinationFile)
t := *cluster
configToWrite.Clusters[key] = &t
configToWrite.Clusters[key].LocationOfOrigin = destinationFile
if relativizePaths {
@ -429,6 +430,10 @@ func getConfigFromFileOrDie(filename string) *clientcmdapi.Config {
return clientcmdapi.NewConfig()
}
if config.Clusters == nil {
config.Clusters = map[string]*clientcmdapi.Cluster{}
}
return config
}