From f7030aff32a5c00af768a3c1745702b2d36cc1b6 Mon Sep 17 00:00:00 2001 From: salbishri Date: Sun, 15 May 2022 13:27:35 +1000 Subject: [PATCH 1/3] Updated docker-compose.yml to remove server.pid cache file on container startup --- production/docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/production/docker-compose.yml b/production/docker-compose.yml index 0d37fec..8325ee9 100644 --- a/production/docker-compose.yml +++ b/production/docker-compose.yml @@ -50,7 +50,7 @@ services: - doubtfire_logs:/doubtfire/log - ./shared-files:/shared-files - ./shared-files/aliases:/etc/aliases:ro - command: /bin/bash -c "bundle exec rails s -b 0.0.0.0" + command: /bin/bash -c "rm -f /doubtfire/tmp/pids/server.pid; bundle exec rails s -b 0.0.0.0" restart: on-failure:5 # Database server - could be external to docker From 6ae522b046cb6f8b89b642072a8f788086d616b2 Mon Sep 17 00:00:00 2001 From: salbishri Date: Sun, 15 May 2022 13:29:34 +1000 Subject: [PATCH 2/3] updated proxy-nginx.conf with external ip address of test vm instance running on gcp --- production/shared-files/proxy-nginx.conf | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/production/shared-files/proxy-nginx.conf b/production/shared-files/proxy-nginx.conf index b5537ae..6c0501d 100644 --- a/production/shared-files/proxy-nginx.conf +++ b/production/shared-files/proxy-nginx.conf @@ -9,25 +9,25 @@ http { # and drop www if present server { listen 80; - server_name www.localhost localhost; #update to remove localhost name - return 301 https://localhost$request_uri; #replace localhost with domain name of server + server_name www.34.129.246.4 34.129.246.4#update to remove localhost name + return 301 https://34.129.246.4$request_uri; #replace localhost with domain name of server } # Drop www if present in https connections server { # This new server will watch for traffic on 443 listen 443 ssl; - server_name www.localhost; #replace localhost with domain name of server + server_name www.34.129.246.4; #replace localhost with domain name of server ssl_certificate /etc/nginx/cert.crt; ssl_certificate_key /etc/nginx/key.key; underscores_in_headers on; - return 301 https://localhost$request_uri; #replace localhost with domain name of server + return 301 https://34.129.246.4$request_uri; #replace localhost with domain name of server } # We have a direct ssl connection to the domain name... # Route requests to internal servers server { listen 443 ssl; - server_name localhost; #replace localhost with domain name of server + server_name 34.129.246.4; #replace localhost with domain name of server ssl_certificate /etc/nginx/cert.crt; ssl_certificate_key /etc/nginx/key.key; From 8973d63e9578fef71525486997053289ac95b192 Mon Sep 17 00:00:00 2001 From: salbishri Date: Sun, 15 May 2022 17:10:14 +1000 Subject: [PATCH 3/3] updated ipaddress with the vm instance running on university gcp account (production) --- production/shared-files/proxy-nginx.conf | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/production/shared-files/proxy-nginx.conf b/production/shared-files/proxy-nginx.conf index 6c0501d..92ef0f5 100644 --- a/production/shared-files/proxy-nginx.conf +++ b/production/shared-files/proxy-nginx.conf @@ -9,25 +9,25 @@ http { # and drop www if present server { listen 80; - server_name www.34.129.246.4 34.129.246.4#update to remove localhost name - return 301 https://34.129.246.4$request_uri; #replace localhost with domain name of server + server_name www.34.129.127.168 34.129.127.168#update to remove localhost name + return 301 https://34.129.127.168$request_uri; #replace localhost with domain name of server } # Drop www if present in https connections server { # This new server will watch for traffic on 443 listen 443 ssl; - server_name www.34.129.246.4; #replace localhost with domain name of server + server_name www.34.129.127.168; #replace localhost with domain name of server ssl_certificate /etc/nginx/cert.crt; ssl_certificate_key /etc/nginx/key.key; underscores_in_headers on; - return 301 https://34.129.246.4$request_uri; #replace localhost with domain name of server + return 301 https://34.129.127.168$request_uri; #replace localhost with domain name of server } # We have a direct ssl connection to the domain name... # Route requests to internal servers server { listen 443 ssl; - server_name 34.129.246.4; #replace localhost with domain name of server + server_name 34.129.127.168; #replace localhost with domain name of server ssl_certificate /etc/nginx/cert.crt; ssl_certificate_key /etc/nginx/key.key;