kezhenxu94 commented on a change in pull request #17: URL: https://github.com/apache/skywalking-docker/pull/17#discussion_r610973023
########## File path: java-agent/README.md ########## @@ -0,0 +1,69 @@ +# Apache SkyWalking Agent docker file + +**Docker images are not official ASF releases but provided for convenience. Recommended usage is always to build the +source** + +<img src="http://skywalking.apache.org/assets/logo.svg" alt="Sky Walking logo" height="90px" align="right" /> + +**SkyWalking**: an APM(application performance monitor) system, especially designed for microservices, cloud native and +container-based (Docker, Kubernetes, Mesos) architectures. + +[](https://github.com/apache/skywalking) +[](https://twitter.com/AsfSkyWalking) + +You could find docker file at [here](https://github.com/apache/skywalking-docker) + +This image only hosts the pre-built SkyWalking Java agent jars, and provides some convenient configurations for +containerization scenarios. + +# How to use this image + +## Build your Java application image on top of this image + +```dockerfile +FROM apache/skywalking-java-agent:8.5.0-jdk8 + +# ... build your java application +``` + +You can start your Java application with `CMD` or `ENTRYPOINT`, but you don't need to care about the Java options to +enable SkyWalking agent, it should be adopted automatically. + +## Use this image as sidecar of Kubernetes service + +In Kubernetes scenarios, you can also use this agent image as a sidecar. Review comment: > Why a system env could make users don't need to modify? Could do be more clear? > > They still to change like, don't they? > > > java $JAVA_TOOL_OPTIONS xxx.jar No, JAVA_TOOL_OPTIONS is automatically adopted by JVM, this is the typical use of this option IMO. Check [this](https://docs.oracle.com/javase/8/docs/technotes/guides/troubleshoot/envvars002.html) > In many environments the command line is not readily accessible to start the application with necessary command-line options. This often arises with applications that use embedded VMs (meaning they use the Java Native Interface (JNI) Invocation API to start the VM), or where the startup is deeply nested in scripts. In these environments the JAVA_TOOL_OPTIONS environment variable can be useful to augment a command line. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
