fix(deploy): nginx custom changes are overriden in install
Signed-off-by: Rajesh Rajendran <rjshrjndrn@gmail.com>
This commit is contained in:
parent
cf824b8237
commit
b5e6989e18
1 changed files with 2 additions and 3 deletions
|
|
@ -122,11 +122,10 @@ type() {
|
||||||
function app(){
|
function app(){
|
||||||
case $1 in
|
case $1 in
|
||||||
nginx)
|
nginx)
|
||||||
git checkout -- nginx-ingress/nginx-ingress/templates/configmap.yaml
|
# Resetting the redirection rule
|
||||||
|
sed -i "s/.* return 301 .*/# return 301 https:\/\/$host$request_uri/g" nginx-ingress/nginx-ingress/templates/configmap.yaml
|
||||||
[[ NGINX_REDIRECT_HTTPS -eq 1 ]] && {
|
[[ NGINX_REDIRECT_HTTPS -eq 1 ]] && {
|
||||||
sed -i "s/# return 301/return 301/g" nginx-ingress/nginx-ingress/templates/configmap.yaml
|
sed -i "s/# return 301/return 301/g" nginx-ingress/nginx-ingress/templates/configmap.yaml
|
||||||
# Toggles first occurrence of location list include.
|
|
||||||
sed -i "0,/include \/etc\/nginx\/conf.d\/location.list/s//# include \/etc\/nginx\/conf.d\/location.list/" nginx-ingress\/nginx-ingress\/templates\/configmap.yaml
|
|
||||||
}
|
}
|
||||||
ansible-playbook -c local setup.yaml -e @vars.yaml -e scale=$installation_type --tags nginx -v
|
ansible-playbook -c local setup.yaml -e @vars.yaml -e scale=$installation_type --tags nginx -v
|
||||||
exit 0
|
exit 0
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue