| 12345678910111213141516171819202122232425262728 |
- FROM openjdk:8-jdk-alpine
- MAINTAINER iamsee "root@iamsee.com"
- # The environment variable
- ENV APP_NAME="railway-admin"
- ENV APP_VERSION=""
- ENV JAVA_OPTS=""
- ENV SPRINGBOOT_OPTS="--spring.profiles.active=docker -Ddruid.mysql.usePingMethod=false"
- RUN #apk add --update ttf-dejavu fontconfig
- RUN echo -e "https://mirror.tuna.tsinghua.edu.cn/alpine/v3.13/main\n\
- https://mirror.tuna.tsinghua.edu.cn/alpine/v3.13/community" > /etc/apk/repositories
- RUN apk --update add tzdata && \
- cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && \
- echo "Asia/Shanghai" > /etc/timezone && \
- apk del tzdata && \
- rm -rf /var/cache/apk/*
- RUN apk --update add curl bash ttf-dejavu && \
- rm -rf /var/cache/apk/*
- EXPOSE 2021
- COPY $APP_NAME/target/$APP_NAME.jar /app.jar
- ENTRYPOINT exec java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -jar /app.jar $SPRINGBOOT_OPTS
|