File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed
Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -33,8 +33,8 @@ if [ -z "$IS_GREEN_EXIST" ];then
3333 done ;
3434 sleep 3
3535 echo " >>> reload nginx"
36- sudo cp /etc/nginx/conf.d/green-url.inc /etc/nginx/conf.d/service-url.inc
37- sudo /usr/sbin/ nginx -s reload
36+ cp /etc/nginx/conf.d/green-url.inc /etc/nginx/conf.d/service-url.inc
37+ nginx -s reload
3838 echo " >>> down blue container"
3939
4040 docker compose -f /home/ubuntu/docker-compose-dev.yml stop blue
6262 done ;
6363 sleep 3
6464 echo " >>> reload nginx"
65- sudo cp /etc/nginx/conf.d/blue-url.inc /etc/nginx/conf.d/service-url.inc
66- sudo /usr/sbin/ nginx -s reload
65+ cp /etc/nginx/conf.d/blue-url.inc /etc/nginx/conf.d/service-url.inc
66+ nginx -s reload
6767 echo " >>> down green container"
6868
6969 docker compose -f /home/ubuntu/docker-compose-dev.yml stop green
Original file line number Diff line number Diff line change @@ -31,8 +31,8 @@ if [ -z "$IS_GREEN_EXIST" ];then
3131 done ;
3232 sleep 3
3333 echo " >>> reload nginx"
34- sudo cp /etc/nginx/conf.d/green-url.inc /etc/nginx/conf.d/service-url.inc
35- sudo /usr/sbin/nginx -s reload
34+ cp /etc/nginx/conf.d/green-url.inc /etc/nginx/conf.d/service-url.inc
35+ /usr/sbin/nginx -s reload
3636 echo " >>> down blue container"
3737 docker compose stop blue
3838 docker image prune -f
5757 done ;
5858 sleep 3
5959 echo " >>> reload nginx"
60- sudo cp /etc/nginx/conf.d/blue-url.inc /etc/nginx/conf.d/service-url.inc
61- sudo /usr/sbin/ nginx -s reload
60+ cp /etc/nginx/conf.d/blue-url.inc /etc/nginx/conf.d/service-url.inc
61+ nginx -s reload
6262 echo " >>> down green container"
6363 docker compose stop green
6464 docker image prune -f
You can’t perform that action at this time.
0 commit comments