Dockerfile 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. FROM centos:7
  2. LABEL author="robert[robert_du@easou.cn]"
  3. ENV LANG C.UTF-8
  4. ENV TZ=Asia/Shanghai
  5. ENV JAVA_HOME /usr/java/jdk1.8.0_271
  6. ENV RESIN_HOME /app/soft/resin-4.0.65
  7. #install jdk8 & resin4 & flume
  8. RUN yum install -y wget rsync epel-release \
  9. && useradd book \
  10. && yum install -y supervisor \
  11. && mkdir -p /usr/java /app/soft \
  12. && curl -O http://10.26.22.185:9000/psop/soft/jdk-8u271-linux-x64.tar.gz \
  13. && curl -O http://10.26.22.185:9000/book/api-rs/resin-4.0.65-relase.tar.gz \
  14. && tar -zxf jdk-8u101-linux-x64.tar.gz -C /usr/java/ \
  15. && tar -zxf resin-4.0.65-relase.tar.gz -C /app/soft/ \
  16. && rm -f jdk-8u101-linux-x64.tar.gz resin-4.0.65-relase.tar.gz \
  17. && ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
  18. #COPY resin.xml /app/soft/resin-4.0.65/conf/resin.xml
  19. COPY resin.properties /app/soft/resin-4.0.65/conf/resin.properties
  20. COPY entrypoint.sh /usr/bin/entrypoint.sh
  21. COPY release /etc/release
  22. COPY supervisord.conf /etc/supervisord.conf
  23. RUN export RELEASE=`head -n 1 /etc/release` \
  24. && rsync -avz $RELEASE/ROOT.war /tmp/ROOT.war \
  25. && chmod +x /usr/bin/entrypoint.sh
  26. #start resin
  27. ENTRYPOINT ["entrypoint.sh"]
  28. CMD ["supervisord"]