FROM acs-reg.alipay.com/antquality/centos:centos7.0.6 MAINTAINER chaocai.lcc <chaocai.lcc@alibaba-inc.com> ENV APP=learntest-service-1.0.0-SNAPSHOT-executable ENV FINAL_APP=learn-test-1.0.3-openapi-executable COPY ccbin /home/admin/ccbin/ # 拷贝本地代码 COPY . /home/admin/mvn_build/ # 执行编译 RUN source /etc/profile && cd /home/admin/mvn_build/ && mvn -B -e clean install -Dmaven.test.skip=true -Dmaven.repo.local=/home/admin/mvnrepo -s /home/admin/setting/settings-xx.xml -P dev && mkdir -p /home/admin/release/run && cp ./target/boot/${APP}.jar /home/admin/release/run # 清理编译数据 RUN rm -rf /home/admin/mvn_build/ /home/admin/mvnrepo # 同步jar包至云启 RUN source /etc/profile && spider -fileName ${FINAL_APP}.jar -filePath /home/admin/release/run/${APP}.jar -fileServer image-shanghai-finance-cloud.alipay.com ENV LANG en_US.utf8 ENTRYPOINT ["/bin/bash", "/home/admin/ccbin/start.sh"]