diff options
| author | Daniel Gonzalez <daniel@gonzalez-nothnagel.de> | 2016-02-20 15:48:31 +0100 |
|---|---|---|
| committer | Daniel Gonzalez <daniel@gonzalez-nothnagel.de> | 2016-02-23 08:10:54 +0100 |
| commit | aaa38eaf5b9d36d59b4e6eb72fdd11764d19cee9 (patch) | |
| tree | a674321395f22c118b781d01b80658d8c9efaa5b /dev/vagrant/centos-bootstrap.sh | |
| parent | 33fd50e603d48de4f1f2fc25ba649561efc25cac (diff) | |
| download | kolla-aaa38eaf5b9d36d59b4e6eb72fdd11764d19cee9.tar.gz kolla-aaa38eaf5b9d36d59b4e6eb72fdd11764d19cee9.zip | |
Fix vagrant bootstrapping for ubuntu
The ubuntu-bootstrap.sh script used by vagrant to provision ubuntu
boxes was lacking many of the features of centos-bootstrap.sh. For
instance, ubuntu-bootstrap.sh did not install kolla, so the kolla-build
executable was not available after initial provisioning.
This patch adapts the bootstrap script to match the centos bootstrap
script as closely as possible.
Change-Id: I6cdacb993a9b6856912ea7cfb73a28f3867f472a
Closes-Bug: #1547114
Diffstat (limited to 'dev/vagrant/centos-bootstrap.sh')
| -rw-r--r-- | dev/vagrant/centos-bootstrap.sh | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/dev/vagrant/centos-bootstrap.sh b/dev/vagrant/centos-bootstrap.sh index 2555eb479..d73c130d7 100644 --- a/dev/vagrant/centos-bootstrap.sh +++ b/dev/vagrant/centos-bootstrap.sh @@ -40,7 +40,7 @@ function prep_work { # Install and configure a quick&dirty docker daemon. function install_docker { # Allow for an externally supplied docker binary. - if [ -f "/data/docker" ]; then + if [[ -f "/data/docker" ]]; then cp /vagrant/docker /usr/bin/docker chmod +x /usr/bin/docker else @@ -90,7 +90,7 @@ function configure_operator { pip install ~vagrant/kolla # Note: this trickery requires a patched docker binary. - if [ "$http_proxy" = "" ]; then + if [[ "$http_proxy" = "" ]]; then su - vagrant sh -c "echo BUILDFLAGS=\\\"--build-env=http_proxy=$http_proxy --build-env=https_proxy=$https_proxy\\\" > ~/kolla/.buildconf" fi @@ -136,7 +136,6 @@ EOF # Launch a local registry (and mirror) to speed up pulling images. - # 0.9.1 is actually the _latest_ tag. if [[ ! $(docker ps -a -q -f name=registry) ]]; then docker run -d \ --name registry \ @@ -154,6 +153,6 @@ EOF prep_work install_docker -if [ "$VM" = "operator" ]; then +if [[ "$VM" = "operator" ]]; then configure_operator fi |
