diff options
| author | Jenkins <jenkins@review.openstack.org> | 2015-08-25 06:18:55 +0000 |
|---|---|---|
| committer | Gerrit Code Review <review@openstack.org> | 2015-08-25 06:18:55 +0000 |
| commit | f07f4387233f014c05edfe21ae7ab3ef298a1512 (patch) | |
| tree | b7d5ea0506a005b4f5dab7a12dea9b378024b092 /docker | |
| parent | f875586ebb83ee272ee1480593e81cde875fcc4c (diff) | |
| parent | 6a297265c5b1a3fa6ef134e8953ea5c1bbfdca02 (diff) | |
| download | kolla-f07f4387233f014c05edfe21ae7ab3ef298a1512.tar.gz kolla-f07f4387233f014c05edfe21ae7ab3ef298a1512.zip | |
Merge "Ubuntu - Horizon"
Diffstat (limited to 'docker')
| -rw-r--r-- | docker/common/horizon/config-external.sh | 15 | ||||
| -rwxr-xr-x | docker/common/horizon/start.sh | 17 |
2 files changed, 28 insertions, 4 deletions
diff --git a/docker/common/horizon/config-external.sh b/docker/common/horizon/config-external.sh index 373a82e64..8e9fc47a0 100644 --- a/docker/common/horizon/config-external.sh +++ b/docker/common/horizon/config-external.sh @@ -8,3 +8,18 @@ if [[ -f "$SOURCE" ]]; then chown ${OWNER}: $TARGET chmod 0644 $TARGET fi + +if [[ "${KOLLA_BASE_DISTRO}" == "ubuntu" || \ + "${KOLLA_BASE_DISTRO}" == "debian" ]]; then + SOURCE="/opt/kolla/horizon/horizon.conf" + TARGET="/etc/apache2/sites-enabled/000-default.conf" +else + SOURCE="/opt/kolla/horizon/horizon.conf" + TARGET="/etc/httpd/sites.d/horizon.conf" +fi + +if [[ -f "$SOURCE" ]]; then + cp $SOURCE $TARGET + chown ${OWNER}: $TARGET + chmod 0644 $TARGET +fi diff --git a/docker/common/horizon/start.sh b/docker/common/horizon/start.sh index 2470bda77..096326a3a 100755 --- a/docker/common/horizon/start.sh +++ b/docker/common/horizon/start.sh @@ -2,12 +2,21 @@ set -o errexit -CMD="/usr/sbin/httpd" -ARGS="-DFOREGROUND" - -# Loading common functions. +# Loading common functions source /opt/kolla/kolla-common.sh +if [[ "${KOLLA_BASE_DISTRO}" == "ubuntu" || \ + "${KOLLA_BASE_DISTRO}" == "debian" ]]; then + CMD="/usr/sbin/apache2" + ARGS="-DFOREGROUND" + + # Loading Apache2 ENV variables + source /etc/apache2/envvars +else + CMD="/usr/sbin/httpd" + ARGS="-DFOREGROUND" +fi + # Execute config strategy set_configs |
