From b9724607f4658e4a8db2b0db312a7184afd3b878 Mon Sep 17 00:00:00 2001 From: LianChongsen <75706802@qq.com> Date: Sat, 7 Oct 2023 13:38:21 +0800 Subject: [PATCH] fix: docker desktop startup failure (#501) --- centos/docker-entrypoint.sh | 5 +++++ debian-dev/docker-entrypoint.sh | 5 +++++ debian/docker-entrypoint.sh | 5 +++++ redhat/docker-entrypoint.sh | 5 +++++ 4 files changed, 20 insertions(+) diff --git a/centos/docker-entrypoint.sh b/centos/docker-entrypoint.sh index 93565ef6..a8a34a9e 100755 --- a/centos/docker-entrypoint.sh +++ b/centos/docker-entrypoint.sh @@ -49,6 +49,11 @@ _EOC_ /usr/bin/apisix init /usr/bin/apisix init_etcd fi + + # For versions below 3.5.0 whose conf_server has not been removed. + if [ -e "/usr/local/apisix/conf/config_listen.sock" ]; then + rm -f "/usr/local/apisix/conf/config_listen.sock" + fi exec /usr/local/openresty/bin/openresty -p /usr/local/apisix -g 'daemon off;' fi diff --git a/debian-dev/docker-entrypoint.sh b/debian-dev/docker-entrypoint.sh index b9d54c44..e7fdc010 100755 --- a/debian-dev/docker-entrypoint.sh +++ b/debian-dev/docker-entrypoint.sh @@ -49,6 +49,11 @@ _EOC_ /usr/bin/apisix init /usr/bin/apisix init_etcd fi + + # For versions below 3.5.0 whose conf_server has not been removed. + if [ -e "/usr/local/apisix/conf/config_listen.sock" ]; then + rm -f "/usr/local/apisix/conf/config_listen.sock" + fi exec /usr/local/openresty-debug/bin/openresty -p /usr/local/apisix -g 'daemon off;' fi diff --git a/debian/docker-entrypoint.sh b/debian/docker-entrypoint.sh index 93565ef6..a8a34a9e 100755 --- a/debian/docker-entrypoint.sh +++ b/debian/docker-entrypoint.sh @@ -49,6 +49,11 @@ _EOC_ /usr/bin/apisix init /usr/bin/apisix init_etcd fi + + # For versions below 3.5.0 whose conf_server has not been removed. + if [ -e "/usr/local/apisix/conf/config_listen.sock" ]; then + rm -f "/usr/local/apisix/conf/config_listen.sock" + fi exec /usr/local/openresty/bin/openresty -p /usr/local/apisix -g 'daemon off;' fi diff --git a/redhat/docker-entrypoint.sh b/redhat/docker-entrypoint.sh index 93565ef6..a8a34a9e 100755 --- a/redhat/docker-entrypoint.sh +++ b/redhat/docker-entrypoint.sh @@ -49,6 +49,11 @@ _EOC_ /usr/bin/apisix init /usr/bin/apisix init_etcd fi + + # For versions below 3.5.0 whose conf_server has not been removed. + if [ -e "/usr/local/apisix/conf/config_listen.sock" ]; then + rm -f "/usr/local/apisix/conf/config_listen.sock" + fi exec /usr/local/openresty/bin/openresty -p /usr/local/apisix -g 'daemon off;' fi