configure-oglivelgromero-new-oglivemainmount-efivarfsuse-local-agent-oglive
Last change
on this file since 267fa3c was
cf14a94,
checked in by Natalia Serrano <natalia.serrano@…>, 6 months ago
|
refs #941 try to make installer on ESXi pick oglive/ogagent from NFS
|
-
Property mode set to
100755
|
File size:
532 bytes
|
Line | |
---|
1 | #!/bin/bash |
---|
2 | |
---|
3 | set -eu |
---|
4 | |
---|
5 | SERVER=$1 |
---|
6 | BRANCH=$2 |
---|
7 | |
---|
8 | #NGINX docker folder config |
---|
9 | NGINXCONF=/opt/nginx/conf |
---|
10 | DEST=$NGINXCONF/$BRANCH.location |
---|
11 | |
---|
12 | IP=$(vagrant ssh $SERVER -c "ifdata -pa eth0" | tr -d '\r') |
---|
13 | IP=$(echo "${IP//[$'\t\r\n']}") |
---|
14 | if [ -z $IP ]; then |
---|
15 | echo "Couldn't detect IP" |
---|
16 | exit 1 |
---|
17 | fi |
---|
18 | |
---|
19 | echo "server IP es ($IP)" |
---|
20 | |
---|
21 | # Configure proxy |
---|
22 | cp installer/vagrant/config/nginx-template.location $DEST |
---|
23 | sed -i "s/##IPADDRESS##/$IP/g" $DEST |
---|
24 | sed -i "s/##BRANCH##/$BRANCH/g" $DEST |
---|
25 | |
---|
26 | # Reload nginx |
---|
27 | docker exec nginx_reverse_proxy nginx -s reload |
---|
Note: See
TracBrowser
for help on using the repository browser.