Merge "Add network config to stabilise multi-NIC scenario"

This commit is contained in:
Zuul 2019-08-01 11:01:55 +00:00 committed by Gerrit Code Review
commit 8f41778bb5
4 changed files with 14 additions and 2 deletions

View File

@ -292,7 +292,7 @@ spec:
command:
- /bin/openstack-cloud-controller-manager
- --v=2
- --cloud-config=/etc/kubernetes/cloud-config
- --cloud-config=/etc/kubernetes/cloud-config-occm
- --cluster-name=${CLUSTER_UUID}
- --use-service-account-credentials=true
- --bind-address=127.0.0.1

View File

@ -32,6 +32,7 @@ HEAT_PARAMS=/etc/sysconfig/heat-params
ETCD_DISCOVERY_URL="$ETCD_DISCOVERY_URL"
USERNAME="$USERNAME"
PASSWORD="$PASSWORD"
CLUSTER_NETWORK="$CLUSTER_NETWORK"
CLUSTER_SUBNET="$CLUSTER_SUBNET"
TLS_DISABLED="$TLS_DISABLED"
KUBE_DASHBOARD_ENABLED="$KUBE_DASHBOARD_ENABLED"

View File

@ -15,7 +15,7 @@ $ssh_cmd cp /etc/pki/tls/certs/ca-bundle.crt /etc/kubernetes/ca-bundle.crt
# Generate a the configuration for Kubernetes services
# to talk to OpenStack Neutron and Cinder
cat > $KUBE_OS_CLOUD_CONFIG <<EOF
CLOUD_CONFIG=$(cat <<EOF
[Global]
auth-url=$AUTH_URL
user-id=$TRUSTEE_USER_ID
@ -33,6 +33,8 @@ monitor-max-retries=3
[BlockStorage]
bs-version=v2
EOF
)
echo $CLOUD_CONFIG > $KUBE_OS_CLOUD_CONFIG
# Provide optional region parameter if it's set.
if [ -n "${REGION_NAME}" ]; then
@ -41,3 +43,11 @@ fi
# backwards compatibility, some apps may expect this file from previous magnum versions.
$ssh_cmd cp ${KUBE_OS_CLOUD_CONFIG} /etc/kubernetes/kube_openstack_config
# Append additional networking config to config file provided to openstack
# cloud controller manager (not supported by in-tree Cinder).
cat > ${KUBE_OS_CLOUD_CONFIG}-occm <<EOF
$CLOUD_CONFIG
[Networking]
internal-network-name=$CLUSTER_NETWORK
EOF

View File

@ -572,6 +572,7 @@ resources:
"$AUTH_URL": {get_param: auth_url}
"$USERNAME": {get_param: username}
"$PASSWORD": {get_param: password}
"$CLUSTER_NETWORK": {get_param: fixed_network}
"$CLUSTER_SUBNET": {get_param: fixed_subnet}
"$TLS_DISABLED": {get_param: tls_disabled}
"$TRAEFIK_INGRESS_CONTROLLER_TAG": {get_param: traefik_ingress_controller_tag}