configure-oglivelgromero-new-oglivemainmaint-cronmount-efivarfsmultivmmultivm-ogboot-installerogClonningEngineogboot-installer-jenkinsoglive-ipv6test-python-scriptsticket-301ticket-50ticket-50-oldticket-577ticket-585ticket-611ticket-612ticket-693ticket-700ubu24tplunification2use-local-agent-oglivevarios-instalacion
Last change
on this file since 915580e was
1107cf8,
checked in by Nicolas Arenas <nicolas.arenas@…>, 20 months ago
|
FIxes IP
|
-
Property mode set to
100644
|
File size:
445 bytes
|
Line | |
---|
1 | #!/bin/bash |
---|
2 | |
---|
3 | SERVER=$1 |
---|
4 | BRANCH=$2 |
---|
5 | |
---|
6 | #NGINX docker folder config |
---|
7 | NGINXCONF=/opt/nginx/conf |
---|
8 | DEST=$NGINXCONF/$BRANCH.location |
---|
9 | |
---|
10 | IP=$(vagrant ssh $SERVER -c "ifdata -pa eth0" | tr -d '\r') |
---|
11 | IP=$(echo "${IP//[$'\t\r\n']}") |
---|
12 | cp config/nginx-template.location $DEST |
---|
13 | |
---|
14 | echo server IP es $IP |
---|
15 | |
---|
16 | # Configure proxy |
---|
17 | sed -i "s/##IPADDRESS##/$IP/g" $DEST |
---|
18 | sed -i "s/##BRANCH##/$BRANCH/g" $DEST |
---|
19 | |
---|
20 | # Reload nginx |
---|
21 | |
---|
22 | docker exec nginx_reverse_proxy nginx -s reload |
---|
23 | |
---|
24 | |
---|
25 | |
---|
26 | |
---|
Note: See
TracBrowser
for help on using the repository browser.