36c7c8cbc05aed48e0a69d34450b849a360878c3
[demo.git] / heat / ONAP / cloud-config / so_install.sh
1 #!/bin/bash
2
3 # Read configuration files
4 #OPENSTACK_API_KEY=$(cat /opt/config/openstack_api_key.txt)
5 GERRIT_BRANCH=$(cat /opt/config/gerrit_branch.txt)
6 CODE_REPO=$(cat /opt/config/remote_repo.txt)
7 HTTP_PROXY=$(cat /opt/config/http_proxy.txt)
8 HTTPS_PROXY=$(cat /opt/config/https_proxy.txt)
9
10 if [ $HTTP_PROXY != "no_proxy" ]
11 then
12     export http_proxy=$HTTP_PROXY
13     export https_proxy=$HTTPS_PROXY
14 fi
15
16 # Clone Gerrit repository and run docker containers.
17 cd /opt
18 git clone -b $GERRIT_BRANCH --single-branch $CODE_REPO test_lab
19 #SO_ENCRYPTION_KEY=$(cat /opt/test_lab/encryption.key)
20 #echo -n "$OPENSTACK_API_KEY" | openssl aes-128-ecb -e -K $SO_ENCRYPTION_KEY -nosalt | xxd -c 256 -p > /opt/config/api_key.txt
21
22 ./so_vm_init.sh