Merge "[opensuse] Enabling external loadbalancer feature"
This commit is contained in:
commit
34e92a9c54
@ -37,14 +37,14 @@ sed -i '
|
||||
sed -i '
|
||||
/^KUBE_API_ADDRESS=/ s|=.*|="--advertise-address='"$KUBE_NODE_IP"' --insecure-bind-address=0.0.0.0 --bind_address=0.0.0.0"|
|
||||
/^KUBE_SERVICE_ADDRESSES=/ s|=.*|="--service-cluster-ip-range='"$PORTAL_NETWORK_CIDR"'"|
|
||||
/^KUBE_API_ARGS=/ s|=.*|="'"$KUBE_API_ARGS"'"|
|
||||
/^KUBE_API_ARGS=/ s|=.*|="--service-account-key-file='"$SERVICE_ACCOUNT_KEY"' --runtime-config=api\/all=true"|
|
||||
/^KUBE_ETCD_SERVERS=/ s/=.*/="--etcd-servers=http:\/\/127.0.0.1:2379"/
|
||||
/^KUBE_ADMISSION_CONTROL=/ s/=.*/="--admission-control=NamespaceLifecycle,LimitRanger,ServiceAccount,ResourceQuota"/
|
||||
' /etc/kubernetes/apiserver
|
||||
|
||||
cat >> /etc/kubernetes/apiserver <<EOF
|
||||
#Uncomment the following line to enable Load Balancer feature
|
||||
#KUBE_API_ARGS="--runtime-config=api/all=true --cloud-config=/etc/sysconfig/kubernetes_openstack_config --cloud-provider=openstack"
|
||||
#KUBE_API_ARGS="--service-account-key-file='"$SERVICE_ACCOUNT_KEY"' --runtime-config=api\/all=true" --runtime-config=api\/all=true --cloud-config=/etc/sysconfig/kubernetes_openstack_config --cloud-provider=openstack"
|
||||
EOF
|
||||
|
||||
sed -i '
|
||||
@ -52,19 +52,20 @@ sed -i '
|
||||
' /etc/kubernetes/controller-manager
|
||||
|
||||
cat >> /etc/kubernetes/controller-manager <<EOF
|
||||
|
||||
#Uncomment the following line to enable Kubernetes Load Balancer feature
|
||||
#KUBE_CONTROLLER_MANAGER_ARGS="--cloud-config=/etc/sysconfig/kubernetes_openstack_config --cloud-provider=openstack"
|
||||
#Uncomment the following line to enable Load Balancer feature
|
||||
#KUBE_CONTROLLER_MANAGER_ARGS="--service_account_private_key_file='"$SERVICE_ACCOUNT_KEY"' --leader-elect=true --cluster-name=kubernetes --cluster-cidr='"$FLANNEL_NETWORK_CIDR"' --cloud-config=/etc/sysconfig/kubernetes_openstack_config --cloud-provider=openstack"
|
||||
EOF
|
||||
|
||||
# Generate a the configuration for Kubernetes services to talk to OpenStack Neutron
|
||||
cat > /etc/sysconfig/kubernetes_openstack_config <<EOF
|
||||
[Global]
|
||||
auth-url=$AUTH_URL
|
||||
Username=$USERNAME
|
||||
Password=$PASSWORD
|
||||
username=$USERNAME
|
||||
password=$PASSWORD
|
||||
tenant-name=$TENANT_NAME
|
||||
domain-name=$DOMAIN_NAME
|
||||
[LoadBalancer]
|
||||
lb-version=v2
|
||||
subnet-id=$CLUSTER_SUBNET
|
||||
create-monitor=yes
|
||||
monitor-delay=1m
|
||||
|
@ -35,3 +35,4 @@ write_files:
|
||||
TRUSTEE_USER_ID="$TRUSTEE_USER_ID"
|
||||
TRUSTEE_PASSWORD="$TRUSTEE_PASSWORD"
|
||||
TRUST_ID="$TRUST_ID"
|
||||
DOMAIN_NAME="$DOMAIN_NAME"
|
||||
|
@ -305,6 +305,11 @@ parameters:
|
||||
default: ""
|
||||
hidden: true
|
||||
|
||||
domain_name:
|
||||
type: string
|
||||
description: domain_name
|
||||
default: ""
|
||||
|
||||
resources:
|
||||
|
||||
######################################################################
|
||||
@ -555,6 +560,7 @@ resources:
|
||||
trustee_user_id: {get_param: trustee_user_id}
|
||||
trustee_password: {get_param: trustee_password}
|
||||
trust_id: {get_param: trust_id}
|
||||
domain_name: {get_param: domain_name}
|
||||
|
||||
######################################################################
|
||||
#
|
||||
|
@ -195,6 +195,10 @@ parameters:
|
||||
description: id of the trust which is used by the trustee
|
||||
hidden: true
|
||||
|
||||
domain_name:
|
||||
type: string
|
||||
description: domain name
|
||||
|
||||
resources:
|
||||
|
||||
master_wait_handle:
|
||||
@ -255,6 +259,7 @@ resources:
|
||||
"$TRUSTEE_USER_ID": {get_param: trustee_user_id}
|
||||
"$TRUSTEE_PASSWORD": {get_param: trustee_password}
|
||||
"$TRUST_ID": {get_param: trust_id}
|
||||
"$DOMAIN_NAME": {get_param: domain_name}
|
||||
|
||||
make_cert:
|
||||
type: OS::Heat::SoftwareConfig
|
||||
|
Loading…
Reference in New Issue
Block a user