diff --git a/devstack/lib/common b/devstack/lib/common index 94f0c21b..38769d1a 100644 --- a/devstack/lib/common +++ b/devstack/lib/common @@ -17,7 +17,7 @@ function get_kubernetes_service_ip { local svc="$1" - for i in {1..30}; do + for i in {1..60}; do ip=$(kubectl get svc/$svc -ojsonpath='{.spec.clusterIP}') && break || sleep 1; done @@ -27,7 +27,7 @@ function get_kubernetes_service_ip { function kubernetes_rollout_status { local deployment="$1" - for i in {1..30}; do + for i in {1..60}; do kubectl get deploy/$deployment && break || sleep 1; done @@ -37,7 +37,7 @@ function kubernetes_rollout_status { function kubernetes_rollout_restart { local deployment="$1" - for i in {1..30}; do + for i in {1..60}; do kubectl get deploy/$deployment && break || sleep 1; done diff --git a/devstack/lib/keystone b/devstack/lib/keystone index 11534d8f..202277b3 100644 --- a/devstack/lib/keystone +++ b/devstack/lib/keystone @@ -76,6 +76,7 @@ function start_keystone { # (re)start memcached to make sure we have a clean memcache. kubectl rollout restart statefulset/memcached-devstack -n default + sleep 10 } export -f start_keystone diff --git a/openstack_operator/templates/horizon/deployment.yml.j2 b/openstack_operator/templates/horizon/deployment.yml.j2 index a252ea8b..2af2fade 100644 --- a/openstack_operator/templates/horizon/deployment.yml.j2 +++ b/openstack_operator/templates/horizon/deployment.yml.j2 @@ -68,13 +68,47 @@ spec: securityContext: runAsUser: 1001 volumeMounts: - - mountPath: /etc/horizon - name: config + - name: config + mountPath: /etc/horizon + {% if 'logo' in spec %} + - name: logo + mountPath: /usr/local/lib/python3.7/site-packages/static/dashboard/img/logo.svg + subPath: logo.svg + - name: logo-fav + mountPath: /usr/local/lib/python3.7/site-packages/static/dashboard/img/favicon.ico + subPath: favicon.ico + - name: logo-splash + mountPath: /usr/local/lib/python3.7/site-packages/static/dashboard/img/logo-splash.svg + subPath: logo-splash.svg + {% endif %} volumes: - - configMap: + - name: config + configMap: defaultMode: 420 name: horizon - name: config + {% if 'logo' in spec %} + - name: logo + configMap: + defaultMode: 420 + name: {{ spec.logo }} + items: + - key: logo.svg + path: logo.svg + - name: logo-fav + configMap: + defaultMode: 420 + name: {{ spec.logo }} + items: + - key: favicon.ico + path: favicon.ico + - name: logo-splash + configMap: + defaultMode: 420 + name: {{ spec.logo }} + items: + - key: logo-splash.svg + path: logo-splash.svg + {% endif %} {% if 'nodeSelector' in spec %} nodeSelector: {{ spec.nodeSelector | to_yaml | indent(8) }}