Dockerfile 1.2 KB

12345678910111213141516171819202122232425262728293031323334
  1. # Dockerfile for apollo-portal-server
  2. # Build with:
  3. # docker build -t apollo-portal-server:v1.0.0 .
  4. FROM openjdk:8-jre-alpine3.8
  5. RUN \
  6. echo "http://mirrors.aliyun.com/alpine/v3.8/main" > /etc/apk/repositories && \
  7. echo "http://mirrors.aliyun.com/alpine/v3.8/community" >> /etc/apk/repositories && \
  8. apk update upgrade && \
  9. apk add --no-cache procps curl bash tzdata && \
  10. ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && \
  11. echo "Asia/Shanghai" > /etc/timezone && \
  12. mkdir -p /apollo-portal-server
  13. ADD . /apollo-portal-server/
  14. ENV APOLLO_PORTAL_SERVICE_NAME="service-apollo-portal-server.sre"
  15. ENV DATASOURCES_URL="jdbc:mysql://service-mysql-for-apollo.sre:3306/ApolloPortalDB?characterEncoding=utf8"
  16. ENV DATASOURCES_USERNAME="FillInCorrectUser"
  17. ENV DATASOURCES_PASSWORD="FillInCorrectPassword"
  18. ENV DEV_META_SERVICE_NAME="service-apollo-config-server-dev.sre"
  19. ENV TEST_ALPHA_META_SERVICE_NAME="service-apollo-config-server-test-alpha.sre"
  20. ENV TEST_BETA_META_SERVICE_NAME="service-apollo-config-server-test-beta.sre"
  21. ENV PROD_META_SERVICE_NAME="service-apollo-config-server-prod.sre"
  22. EXPOSE 8070
  23. ENTRYPOINT ["/apollo-portal-server/entrypoint.sh"]
  24. CMD ["/apollo-portal-server/scripts/startup-kubernetes.sh"]