summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Timoney <dtimoney@att.com>2020-07-31 12:26:12 +0000
committerGerrit Code Review <gerrit@onap.org>2020-07-31 12:26:12 +0000
commit30aa3ac5fba597c06ca7ab6b3934649de67f414e (patch)
tree2e66ce4ba37d87aa1ced6744da5eecf0d42cf7fd
parentf4a9a8973ad027a1c5cf6203c4431042fbefb20d (diff)
parent8e80d435d580d696d60ac36cf6475da35905f961 (diff)
Merge "Use system DNS resolver"
Former-commit-id: 91f7662ab2a31ce11adbc1b1c527b57e47a4ed9e
-rw-r--r--installation/sdnc-web/src/main/docker/Dockerfile1
-rw-r--r--installation/sdnc-web/src/main/resources/http_site.conf8
-rw-r--r--installation/sdnc-web/src/main/resources/https_site.conf8
-rw-r--r--installation/sdnc-web/src/main/scripts/configure.sh2
-rw-r--r--installation/sdnc-web/src/main/scripts/run.sh3
5 files changed, 5 insertions, 17 deletions
diff --git a/installation/sdnc-web/src/main/docker/Dockerfile b/installation/sdnc-web/src/main/docker/Dockerfile
index 37de7166..5009a215 100644
--- a/installation/sdnc-web/src/main/docker/Dockerfile
+++ b/installation/sdnc-web/src/main/docker/Dockerfile
@@ -36,7 +36,6 @@ ENV WEBPROTOCOL="HTTP" \
SDNRPROTOCOL="HTTP" \
SDNRHOST="172.18.0.3" \
SDNRPORT="8181" \
- LOCALDNS="127.0.0.11" \
SSL_CERT_DIR="/app/cert" \
SSL_CERTIFICATE="cert.pem" \
SSL_CERTIFICATE_KEY="cert.key"
diff --git a/installation/sdnc-web/src/main/resources/http_site.conf b/installation/sdnc-web/src/main/resources/http_site.conf
index dd641418..640668a1 100644
--- a/installation/sdnc-web/src/main/resources/http_site.conf
+++ b/installation/sdnc-web/src/main/resources/http_site.conf
@@ -49,8 +49,6 @@ server {
server_name _;
- set $sdnrserver "SDNRHOST";
-
location ~ ^/$ {
return 301 /odlux/index.html;
}
@@ -61,15 +59,13 @@ server {
try_files $uri $uri/ @backend;
}
location /websocket {
- resolver LOCALDNS;
- proxy_pass SDNRPROTOCOL://$sdnrserver:SDNRPORT/websocket;
+ proxy_pass SDNRPROTOCOL://SDNRHOST:SDNRPORT/websocket;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location @backend {
- resolver LOCALDNS;
- proxy_pass SDNRPROTOCOL://$sdnrserver:SDNRPORT;
+ proxy_pass SDNRPROTOCOL://SDNRHOST:SDNRPORT;
}
}
diff --git a/installation/sdnc-web/src/main/resources/https_site.conf b/installation/sdnc-web/src/main/resources/https_site.conf
index 49afa079..5dc4cfba 100644
--- a/installation/sdnc-web/src/main/resources/https_site.conf
+++ b/installation/sdnc-web/src/main/resources/https_site.conf
@@ -68,8 +68,6 @@ server {
server_name _;
- set $sdnrserver "SDNRHOST";
-
location ~ ^/$ {
return 301 /odlux/index.html;
}
@@ -80,15 +78,13 @@ server {
try_files $uri $uri/ @backend;
}
location /websocket {
- resolver LOCALDNS;
- proxy_pass SDNRPROTOCOL://$sdnrserver:SDNRPORT/websocket;
+ proxy_pass SDNRPROTOCOL://SDNRHOST:SDNRPORT/websocket;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
location @backend {
- resolver LOCALDNS;
- proxy_pass SDNRPROTOCOL://$sdnrserver:SDNRPORT;
+ proxy_pass SDNRPROTOCOL://SDNRHOST:SDNRPORT;
}
}
diff --git a/installation/sdnc-web/src/main/scripts/configure.sh b/installation/sdnc-web/src/main/scripts/configure.sh
index b8385fd5..ca2ea764 100644
--- a/installation/sdnc-web/src/main/scripts/configure.sh
+++ b/installation/sdnc-web/src/main/scripts/configure.sh
@@ -44,7 +44,6 @@ update_nginx_site_conf() {
sed -i 's|SDNRPROTOCOL|'$SDNRPROTOCOL'|g' /opt/bitnami/nginx/conf/server_blocks/https_site.conf
sed -i 's|SDNRHOST|'$SDNRHOST'|g' /opt/bitnami/nginx/conf/server_blocks/https_site.conf
sed -i 's|SDNRPORT|'$SDNRPORT'|g' /opt/bitnami/nginx/conf/server_blocks/https_site.conf
- sed -i 's|LOCALDNS|'$LOCALDNS'|g' /opt/bitnami/nginx/conf/server_blocks/https_site.conf
#cp /opt/bitnami/nginx/sbin/https_site.conf /opt/bitnami/nginx/conf/server_blocks
rm /opt/bitnami/nginx/conf/server_blocks/http_site.conf
@@ -54,7 +53,6 @@ update_nginx_site_conf() {
sed -i 's|SDNRPROTOCOL|'$SDNRPROTOCOL'|g' /opt/bitnami/nginx/conf/server_blocks/http_site.conf
sed -i 's|SDNRHOST|'$SDNRHOST'|g' /opt/bitnami/nginx/conf/server_blocks/http_site.conf
sed -i 's|SDNRPORT|'$SDNRPORT'|g' /opt/bitnami/nginx/conf/server_blocks/http_site.conf
- sed -i 's|LOCALDNS|'$LOCALDNS'|g' /opt/bitnami/nginx/conf/server_blocks/http_site.conf
#cp /opt/bitnami/nginx/sbin/http_site.conf /opt/bitnami/nginx/conf/server_blocks
rm /opt/bitnami/nginx/conf/server_blocks/https_site.conf
fi
diff --git a/installation/sdnc-web/src/main/scripts/run.sh b/installation/sdnc-web/src/main/scripts/run.sh
index 544dd473..604ebdee 100644
--- a/installation/sdnc-web/src/main/scripts/run.sh
+++ b/installation/sdnc-web/src/main/scripts/run.sh
@@ -30,7 +30,6 @@ echo " WEBPORT: $WEBPORT"
echo " SDNRPROTOCOL: $SDNRPROTOCOL"
echo " SDNRHOST: $SDNRHOST"
echo " SDNRPORT: $SDNRPORT"
-echo " LOCALDNS: $LOCALDNS"
echo " SSL_CERT_DIR: $SSL_CERT_DIR"
echo -n " SSL_CERTIFICATE: $SSL_CERTIFICATE"
if [ -f "$SSL_CERTIFICATE" ]; then
@@ -66,4 +65,4 @@ if [ ! -z "$DEBUG" ]; then
fi
# Call the base images' run.sh to start NGINX
-bash /run.sh \ No newline at end of file
+bash /run.sh