Files
integral-shop/deploy/docker/single-shop/front-api.Dockerfile
2026-06-15 09:33:00 +08:00

50 lines
1.7 KiB
Docker
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# =============================================================
# 积分商城 用户端 APImiao-front-2.2.jar
# JAR 由宿主机 bind-mount 进来(/app/app.jar无需 Maven 编译
# 宿主机路径:${SINGLE_FRONT_JAR} -> /app/app.jar
# FTP 更新 JAR 后docker compose --env-file .env restart single-front-api
# =============================================================
FROM eclipse-temurin:17-jre-jammy
ENV TZ=Asia/Shanghai \
LANG=C.UTF-8 LC_ALL=C.UTF-8 \
DEBIAN_FRONTEND=noninteractive
RUN sed -i \
-e 's|http://archive.ubuntu.com|https://mirrors.aliyun.com|g' \
-e 's|http://security.ubuntu.com|https://mirrors.aliyun.com|g' \
/etc/apt/sources.list
RUN apt-get update && apt-get install -y --no-install-recommends \
tzdata ca-certificates curl \
fontconfig fonts-dejavu fonts-wqy-zenhei \
&& ln -sf /usr/share/zoneinfo/$TZ /etc/localtime \
&& echo $TZ > /etc/timezone \
&& rm -rf /var/lib/apt/lists/* \
&& mkdir -p /app /config /usr/local/crmeb/crmebimage /app/log
ENV JAVA_HEAP_OPTS="-Xms128m -Xmx256m"
ENV JAVA_MODULE_OPTS="\
--add-opens java.base/java.lang=ALL-UNNAMED \
--add-opens java.base/java.lang.reflect=ALL-UNNAMED \
--add-opens java.base/java.util=ALL-UNNAMED \
--add-opens java.base/java.io=ALL-UNNAMED \
--add-opens java.base/java.math=ALL-UNNAMED \
--add-opens java.base/sun.net.util=ALL-UNNAMED \
--add-opens java.base/java.net=ALL-UNNAMED"
WORKDIR /app
EXPOSE 30033
ENTRYPOINT ["sh","-c","exec java \
$JAVA_HEAP_OPTS \
$JAVA_MODULE_OPTS \
-Dfile.encoding=UTF-8 \
-Duser.timezone=$TZ \
-jar /app/app.jar \
--spring.profiles.active=${SPRING_PROFILES_ACTIVE:-docker} \
--spring.config.additional-location=file:/config/ \
--server.port=${SERVER_PORT:-30033}"]