From 92523742b7187a69bde6016b406cc7b117df16d4 Mon Sep 17 00:00:00 2001 From: keyan Date: Mon, 21 Feb 2022 13:09:41 -0600 Subject: [PATCH] try to fix nginx issues on config deploy --- .ebextensions/removenginx.config | 3 +++ .platform/hooks/postdeploy/99_kill_default_nginx.sh | 4 ++++ 2 files changed, 7 insertions(+) create mode 100644 .ebextensions/removenginx.config create mode 100644 .platform/hooks/postdeploy/99_kill_default_nginx.sh diff --git a/.ebextensions/removenginx.config b/.ebextensions/removenginx.config new file mode 100644 index 00000000..fc5e0bdc --- /dev/null +++ b/.ebextensions/removenginx.config @@ -0,0 +1,3 @@ +container_commands: + removeconfig: + command: "rm -f /tmp/deployment/config/#etc#nginx#conf.d#00_elastic_beanstalk_proxy.conf /etc/nginx/conf.d/00_elastic_beanstalk_proxy.conf" \ No newline at end of file diff --git a/.platform/hooks/postdeploy/99_kill_default_nginx.sh b/.platform/hooks/postdeploy/99_kill_default_nginx.sh new file mode 100644 index 00000000..e90fd819 --- /dev/null +++ b/.platform/hooks/postdeploy/99_kill_default_nginx.sh @@ -0,0 +1,4 @@ +#!/bin/bash -xe +rm -f /etc/nginx/conf.d/00_elastic_beanstalk_proxy.conf +service nginx stop +service nginx start \ No newline at end of file