2019-12-16 skyworking

dockerfile的配置

FROM harbor.matrixport.com/library/java:alpine-skyagent-public as build
WORKDIR /app
ADD . /app
RUN mvn clean package -Dmaven.test.skip=true -Dmaven.repo.local=/app/.m2/repository/

FROM harbor.matrixport.com/library/java:8
WORKDIR /app
COPY --from=build /app/target/payment-0.0.1-SNAPSHOT.jar .
COPY --from=build /app/sky_agent /app/sky_agent
COPY --from=build /app/sky_config/agent.config /app/sky_agent/config/agent.config
RUN echo "Asia/Shanghai" > /etc/timezone \
    && dpkg-reconfigure -f noninteractive tzdata
VOLUME ["/tmp"]
EXPOSE 8080
ENTRYPOINT ["java", "-javaagent:/app/sky_agent/skywalking-agent.jar", "-jar", "payment-0.0.1-SNAPSHOT.jar"]

在agent.config 文件里,修改sky-working server的地址和端口号

你可能感兴趣的:(2019-12-16 skyworking)