diff --git a/.github/scripts/resolve-ci-modules.sh b/.github/scripts/resolve-ci-modules.sh
index 5c505bc9b0c6..9b41d5ff4e5b 100644
--- a/.github/scripts/resolve-ci-modules.sh
+++ b/.github/scripts/resolve-ci-modules.sh
@@ -41,9 +41,24 @@ add_module() {
modules+=("${module}")
}
+is_root_reactor_module() {
+ local module="$1"
+ local candidate="${module}"
+
+ while [[ "${candidate}" == */* ]]; do
+ if grep -Fq "${candidate}" pom.xml; then
+ return 0
+ fi
+ candidate="${candidate%/*}"
+ done
+
+ grep -Fq "${candidate}" pom.xml
+}
+
find_module() {
local path="$1"
local dir
+ local module
if [[ -d "${path}" ]]; then
dir="${path}"
@@ -53,7 +68,10 @@ find_module() {
while [[ "${dir}" != "." && "${dir}" != "/" ]]; do
if [[ -f "${dir}/pom.xml" ]]; then
- printf '%s\n' "${dir#./}"
+ module="${dir#./}"
+ if is_root_reactor_module "${module}"; then
+ printf '%s\n' "${module}"
+ fi
return
fi
dir="$(dirname "${dir}")"
@@ -95,6 +113,8 @@ while IFS= read -r file; do
module="$(find_module "${file}")"
if [[ -n "${module:-}" ]]; then
add_module "${module}"
+ else
+ full_build_required=true
fi
fi
done < <(printf '%s' "${changed_files_json}" | jq -r '.[]')
diff --git a/shenyu-examples/shenyu-examples-dubbo/shenyu-examples-apache-dubbo-service-xml/Dockerfile b/shenyu-examples/shenyu-examples-dubbo/shenyu-examples-apache-dubbo-service-xml/Dockerfile
index f7583ce639b1..e0f157323c98 100644
--- a/shenyu-examples/shenyu-examples-dubbo/shenyu-examples-apache-dubbo-service-xml/Dockerfile
+++ b/shenyu-examples/shenyu-examples-dubbo/shenyu-examples-apache-dubbo-service-xml/Dockerfile
@@ -17,6 +17,9 @@
FROM amazoncorretto:17.0.11-alpine3.19
ENV APP_NAME shenyu-examples-apache-dubbo-service-xml
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN addgroup -S shenyu && \
+ adduser -S shenyu -G shenyu -h /home/shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8011/actuator/health | grep -q UP"]
EXPOSE 8011
EXPOSE 20888
diff --git a/shenyu-examples/shenyu-examples-dubbo/shenyu-examples-apache-dubbo-service/Dockerfile b/shenyu-examples/shenyu-examples-dubbo/shenyu-examples-apache-dubbo-service/Dockerfile
index 0bcaf01c768c..2848c7dafc5d 100644
--- a/shenyu-examples/shenyu-examples-dubbo/shenyu-examples-apache-dubbo-service/Dockerfile
+++ b/shenyu-examples/shenyu-examples-dubbo/shenyu-examples-apache-dubbo-service/Dockerfile
@@ -17,6 +17,9 @@
FROM amazoncorretto:17.0.11-alpine3.19
ENV APP_NAME shenyu-examples-apache-dubbo-service
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN addgroup -S shenyu && \
+ adduser -S shenyu -G shenyu -h /home/shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8011/actuator/health | grep -q UP"]
EXPOSE 8011
EXPOSE 20888
diff --git a/shenyu-examples/shenyu-examples-eureka/Dockerfile b/shenyu-examples/shenyu-examples-eureka/Dockerfile
index ef303fb48ee6..1d60943d9383 100644
--- a/shenyu-examples/shenyu-examples-eureka/Dockerfile
+++ b/shenyu-examples/shenyu-examples-eureka/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-eureka
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["bash", "-c", ": >/dev/tcp/127.0.0.1/8761"]
EXPOSE 8761
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-grpc/Dockerfile b/shenyu-examples/shenyu-examples-grpc/Dockerfile
index 930ca9aa9262..e2801f9afe72 100644
--- a/shenyu-examples/shenyu-examples-grpc/Dockerfile
+++ b/shenyu-examples/shenyu-examples-grpc/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-grpc
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:55290/actuator/health | grep -q UP"]
EXPOSE 55290
EXPOSE 8080
diff --git a/shenyu-examples/shenyu-examples-http-swagger3/Dockerfile b/shenyu-examples/shenyu-examples-http-swagger3/Dockerfile
index 6c1108c95acf..442ffd0fc3e2 100644
--- a/shenyu-examples/shenyu-examples-http-swagger3/Dockerfile
+++ b/shenyu-examples/shenyu-examples-http-swagger3/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-http-swagger3
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8190/actuator/health | grep -q UP"]
EXPOSE 8190
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-http/Dockerfile b/shenyu-examples/shenyu-examples-http/Dockerfile
index c7ac7d3bc202..7923ccad62c9 100644
--- a/shenyu-examples/shenyu-examples-http/Dockerfile
+++ b/shenyu-examples/shenyu-examples-http/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-http
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8189/actuator/health | grep -q UP"]
EXPOSE 8189
CMD java --add-opens java.base/java.lang=ALL-UNNAMED -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-https/Dockerfile b/shenyu-examples/shenyu-examples-https/Dockerfile
index eec4c68c9525..f665db14fde5 100644
--- a/shenyu-examples/shenyu-examples-https/Dockerfile
+++ b/shenyu-examples/shenyu-examples-https/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-https
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget --no-check-certificate -q -O - https://127.0.0.1:8190/actuator/health | grep -q UP"]
EXPOSE 8080
EXPOSE 8190
diff --git a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-dubbo/shenyu-examples-sdk-apache-dubbo-consumer/Dockerfile b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-dubbo/shenyu-examples-sdk-apache-dubbo-consumer/Dockerfile
index 8f1d1bd67171..190500b2a477 100644
--- a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-dubbo/shenyu-examples-sdk-apache-dubbo-consumer/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-dubbo/shenyu-examples-sdk-apache-dubbo-consumer/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sdk-apache-dubbo-consumer
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8899/actuator/health | grep -q UP"]
EXPOSE 8899
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-dubbo/shenyu-examples-sdk-apache-dubbo-provider/Dockerfile b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-dubbo/shenyu-examples-sdk-apache-dubbo-provider/Dockerfile
index 63367dbc7f4c..be843f590414 100644
--- a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-dubbo/shenyu-examples-sdk-apache-dubbo-provider/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-dubbo/shenyu-examples-sdk-apache-dubbo-provider/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sdk-apache-dubbo-provider
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8011/actuator/health | grep -q UP"]
EXPOSE 8011
EXPOSE 20888
diff --git a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-feign/Dockerfile b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-feign/Dockerfile
index c72364d3f4c7..38d0df749348 100644
--- a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-feign/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-feign/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sdk-feign
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8898/actuator/health | grep -q UP"]
EXPOSE 8898
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-grpc/shenyu-examples-sdk-grpc-consumer/Dockerfile b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-grpc/shenyu-examples-sdk-grpc-consumer/Dockerfile
index 5fe8904c5bcb..9f29451ec0c2 100644
--- a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-grpc/shenyu-examples-sdk-grpc-consumer/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-grpc/shenyu-examples-sdk-grpc-consumer/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sdk-grpc-consumer
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8899/actuator/health | grep -q UP"]
EXPOSE 8899
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-grpc/shenyu-examples-sdk-grpc-provider/Dockerfile b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-grpc/shenyu-examples-sdk-grpc-provider/Dockerfile
index 1f1b9a056f9b..acf24ac4da5f 100644
--- a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-grpc/shenyu-examples-sdk-grpc-provider/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-grpc/shenyu-examples-sdk-grpc-provider/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sdk-grpc-provider
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:55222/actuator/health | grep -q UP"]
EXPOSE 8899
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-http/Dockerfile b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-http/Dockerfile
index e98d9ec9b728..7ee7720e3919 100644
--- a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-http/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-http/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sdk-http
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8899/actuator/health | grep -q UP"]
EXPOSE 8899
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-springcloud/shenyu-examples-sdk-springcloud-consumer/Dockerfile b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-springcloud/shenyu-examples-sdk-springcloud-consumer/Dockerfile
index 1da88515edeb..6e47ce099dbd 100644
--- a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-springcloud/shenyu-examples-sdk-springcloud-consumer/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-springcloud/shenyu-examples-sdk-springcloud-consumer/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sdk-springcloud-consumer
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8899/actuator/health | grep -q UP"]
EXPOSE 8899
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-springcloud/shenyu-examples-sdk-springcloud-provider/Dockerfile b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-springcloud/shenyu-examples-sdk-springcloud-provider/Dockerfile
index 1ae1a64f4884..e4b008c9ce74 100644
--- a/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-springcloud/shenyu-examples-sdk-springcloud-provider/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sdk/shenyu-examples-sdk-springcloud/shenyu-examples-sdk-springcloud-provider/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sdk-springcloud-provider
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8884/actuator/health | grep -q UP"]
EXPOSE 8761
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-sofa/shenyu-examples-sofa-service/Dockerfile b/shenyu-examples/shenyu-examples-sofa/shenyu-examples-sofa-service/Dockerfile
index e37d49de6122..f86b4a33ed8b 100644
--- a/shenyu-examples/shenyu-examples-sofa/shenyu-examples-sofa-service/Dockerfile
+++ b/shenyu-examples/shenyu-examples-sofa/shenyu-examples-sofa-service/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-sofa
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:28011/actuator/health | grep -q UP"]
EXPOSE 28011
EXPOSE 8888
diff --git a/shenyu-examples/shenyu-examples-springcloud/Dockerfile b/shenyu-examples/shenyu-examples-springcloud/Dockerfile
index 776dc2823aca..e84c725f3740 100644
--- a/shenyu-examples/shenyu-examples-springcloud/Dockerfile
+++ b/shenyu-examples/shenyu-examples-springcloud/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-springcloud
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8884/actuator/health | grep -q UP"]
EXPOSE 8761
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-springmvc/Dockerfile b/shenyu-examples/shenyu-examples-springmvc/Dockerfile
index 1251fe80190d..18a57596f505 100644
--- a/shenyu-examples/shenyu-examples-springmvc/Dockerfile
+++ b/shenyu-examples/shenyu-examples-springmvc/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-examples-springmvc
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["bash", "-c", ": >/dev/tcp/127.0.0.1/8289"]
EXPOSE 8289
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-websocket/shenyu-example-spring-annotation-websocket/Dockerfile b/shenyu-examples/shenyu-examples-websocket/shenyu-example-spring-annotation-websocket/Dockerfile
index 6bac3dfa91dd..68b2bbd194d5 100644
--- a/shenyu-examples/shenyu-examples-websocket/shenyu-example-spring-annotation-websocket/Dockerfile
+++ b/shenyu-examples/shenyu-examples-websocket/shenyu-example-spring-annotation-websocket/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-example-spring-annotation-websocket
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8001/actuator/health | grep -q UP"]
EXPOSE 8001
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-examples/shenyu-examples-websocket/shenyu-example-spring-native-websocket/Dockerfile b/shenyu-examples/shenyu-examples-websocket/shenyu-example-spring-native-websocket/Dockerfile
index 2733edb3278b..342f1456bec3 100644
--- a/shenyu-examples/shenyu-examples-websocket/shenyu-example-spring-native-websocket/Dockerfile
+++ b/shenyu-examples/shenyu-examples-websocket/shenyu-example-spring-native-websocket/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-example-spring-native-websocket
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:8868/actuator/health | grep -q UP"]
EXPOSE 8848
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-apache-dubbo/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-apache-dubbo/Dockerfile
index 0cc49ae31dec..414717a26113 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-apache-dubbo/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-apache-dubbo/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-apache-dubbo
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-combination/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-combination/Dockerfile
index aab9a70cf86c..b84b2f9af151 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-combination/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-combination/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-combination
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/sun.net.util=ALL-UNNAMED -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-grpc/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-grpc/Dockerfile
index ce90f086f4da..f0d24f5acfd0 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-grpc/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-grpc/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-grpc
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-http/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-http/Dockerfile
index 70cd9aa49b64..93c9f95aacfd 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-http/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-http/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-http
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-https/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-https/Dockerfile
index bb147a4b1e5f..ce45e86139bc 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-https/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-https/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-https
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-apache-dubbo/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-apache-dubbo/Dockerfile
index e9bbdd8e89ac..c867dbe9f06a 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-apache-dubbo/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-apache-dubbo/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-k8s-ingress-apache-dubbo
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-grpc/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-grpc/Dockerfile
index 8fcf63c1b17a..d12075fb7871 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-grpc/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-grpc/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-k8s-ingress-grpc
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-http/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-http/Dockerfile
index 7ace540bdd87..ca92b04c312e 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-http/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-http/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-k8s-ingress-http
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-sofa/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-sofa/Dockerfile
index e48f867d68c6..97bde1b4e3df 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-sofa/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-sofa/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-k8s-ingress-sofa
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java --add-opens java.base/java.lang=ALL-UNNAMED -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-websocket/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-websocket/Dockerfile
index 725421fd0c53..e091ceb1108b 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-websocket/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-k8s-ingress-websocket/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-k8s-ingress-websocket
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-rewrite/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-rewrite/Dockerfile
index ed98b898ea05..02d238d13444 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-rewrite/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-rewrite/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-rewrite
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-sdk-apache-dubbo/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-sdk-apache-dubbo/Dockerfile
index ad4c8a416aaf..ffb84364c788 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-sdk-apache-dubbo/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-sdk-apache-dubbo/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-sdk-apache-dubbo
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-sdk-http/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-sdk-http/Dockerfile
index ad5ebf8b3421..3793d898736a 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-sdk-http/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-sdk-http/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-sdk-http
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-sofa/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-sofa/Dockerfile
index 522abe705137..fe47c2995c94 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-sofa/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-sofa/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-sofa
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java --add-opens java.base/java.lang=ALL-UNNAMED -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-spring-cloud/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-spring-cloud/Dockerfile
index a61b9c75bdbd..e7365b6e5893 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-spring-cloud/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-spring-cloud/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-spring-cloud
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-custom-plugin/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-custom-plugin/Dockerfile
index a370a575910c..a0ed82bda08d 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-custom-plugin/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-custom-plugin/Dockerfile
@@ -16,7 +16,14 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-custom-plugin
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ADD target/${APP_NAME}.jar /opt/shenyu-custom-plugin.jar
RUN ls -l
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown shenyu:shenyu /opt/shenyu-custom-plugin.jar
+USER shenyu
diff --git a/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-admin/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-admin/Dockerfile
index ea27ef782566..28c6f170d4d8 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-admin/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-admin/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-admin
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,8 +27,12 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}-bin.tar.gz ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
-
RUN ls -l
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9095/actuator/health | grep -q UP"]
EXPOSE 9095
diff --git a/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-upload-plugin-case/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-upload-plugin-case/Dockerfile
index 28f462f9af7a..1e299b921f0a 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-upload-plugin-case/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-upload-plugin-case/Dockerfile
@@ -16,6 +16,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-upload-plugin-case
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -25,6 +28,11 @@ COPY --from=apache/shenyu-integrated-test-custom /opt/shenyu-custom-plugin.jar
RUN chmod 755 ${LOCAL_PATH}/shenyu-custom-plugin.jar
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar
diff --git a/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-upload-plugin-case/pom.xml b/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-upload-plugin-case/pom.xml
index 2d7a0a01f565..9ad4393e469e 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-upload-plugin-case/pom.xml
+++ b/shenyu-integrated-test/shenyu-integrated-test-upload-plugin/shenyu-integrated-test-upload-plugin-case/pom.xml
@@ -28,6 +28,14 @@
shenyu-integrated-test-upload-plugin-case
+
+
+ org.apache.shenyu
+ shenyu-custom-plugin
+ ${project.version}
+ pom
+ test
+
org.apache.shenyu
shenyu-integrated-test-common
diff --git a/shenyu-integrated-test/shenyu-integrated-test-websocket/Dockerfile b/shenyu-integrated-test/shenyu-integrated-test-websocket/Dockerfile
index da16e9b336bf..3c06be17ebfd 100644
--- a/shenyu-integrated-test/shenyu-integrated-test-websocket/Dockerfile
+++ b/shenyu-integrated-test/shenyu-integrated-test-websocket/Dockerfile
@@ -17,6 +17,9 @@
FROM eclipse-temurin:17-centos7
ENV APP_NAME shenyu-integrated-test-websocket
+LABEL org.opencontainers.image.title="${APP_NAME}" \
+ org.opencontainers.image.source="https://github.com/apache/shenyu" \
+ org.opencontainers.image.licenses="Apache-2.0"
ENV LOCAL_PATH /opt/${APP_NAME}
RUN mkdir -p ${LOCAL_PATH}
@@ -24,6 +27,11 @@ RUN mkdir -p ${LOCAL_PATH}
ADD target/${APP_NAME}.jar ${LOCAL_PATH}
WORKDIR ${LOCAL_PATH}
+RUN groupadd --system shenyu && \
+ useradd --system --gid shenyu --create-home --home-dir /home/shenyu shenyu && \
+ chown -R shenyu:shenyu ${LOCAL_PATH}
+USER shenyu
+HEALTHCHECK --interval=30s --timeout=5s --start-period=30s --retries=3 CMD ["sh", "-c", "wget -q -O - http://127.0.0.1:9195/actuator/health | grep -q UP"]
EXPOSE 9195
CMD java -jar ${APP_NAME}.jar