diff --git a/packaging/pom.xml b/packaging/pom.xml index 6f261b61..98e43551 100644 --- a/packaging/pom.xml +++ b/packaging/pom.xml @@ -36,6 +36,84 @@ + + deb + + [1.8,) + + + + + jdeb + org.vafer + 1.7 + + + package + + jdeb + + + + + false + ${project.build.directory}/arthas.deb + + + ${project.build.directory}/arthas-${project.version}-bin + directory + + + perm + 1 + /usr/share/arthas + loader + loader + + + + + ${project.build.directory}/arthas-${project.version}-bin/as.sh + file + + perm + 1 + /usr/bin + 755 + root + root + + + + ../packaging/src/deb/man1/arthas.1 + file + + perm + 1 + /usr/share/man/man1 + 755 + loader + loader + + + + ../packaging/src/deb/copyright/copyright.1 + file + + perm + 1 + /usr/share/doc/arthas + 755 + loader + loader + + + + + + + + full diff --git a/packaging/src/deb/control/control b/packaging/src/deb/control/control new file mode 100644 index 00000000..6b37d60c --- /dev/null +++ b/packaging/src/deb/control/control @@ -0,0 +1,10 @@ +Package: arthas +Version: [[version]] +Section: misc +Priority: optional +Architecture: all +Depends: jdk (>= 1.5) +Maintainer: arthas +Description: Arthas is a Java Diagnostic tool open sourced by Alibaba. +Distribution: development +Depends: telnet, curl, unzip diff --git a/packaging/src/deb/copyright/copyright.1 b/packaging/src/deb/copyright/copyright.1 new file mode 100644 index 00000000..96c16508 --- /dev/null +++ b/packaging/src/deb/copyright/copyright.1 @@ -0,0 +1,17 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: arthas +Source: https://github.com/alibaba/arthas + +Files: * +Copyright: 2019, Alibaba +License: Apache-2.0 or GPL-3 + +License: Apache-2.0 + On Debian systems, the full text of the Apache-2.0 license + can be found in the file '/usr/share/common-licenses/Apache-2.0' + +License: GPL-3 + On Debian systems, the full text of the GPL-3 license + can be found in the file '/usr/share/common-licenses/GPL-3' + + diff --git a/packaging/src/deb/man1/arthas.1 b/packaging/src/deb/man1/arthas.1 new file mode 100644 index 00000000..60e4b8b6 --- /dev/null +++ b/packaging/src/deb/man1/arthas.1 @@ -0,0 +1,108 @@ +.\" Manpage for Arthas +.\" Submit an issue to https://github.com/alibaba/arthas to coreect errors and fix typos. +.TH man 1 "3.1.2" "Arthas man page" + +.SH NAME +Arthas \- Alibaba Java Diagnostic Tool + +.SH SYNOPSIS +.B as [-h] [--target-ip ] [--telnet-port ] + [--http-port ] [--session-timeout ] [--arthas-home ] + [--use-version ] [--repo-mirror ] [--versions] [--use-http] + [--attach-only] [-c ] [-f ] [-v] [pid] + +.SH DESCRIPTION +Arthas is a Java Diagnostic tool open sourced by Alibaba, Arthas allows developers +to troubleshsoot production issues for Java applications without modifying code +or restarting servers. + +Oftentimes the production system network is inaccessible from local development +envoirnment. if issues are encountered in production systems, it is impossible to +use the IDE to debug the application remotely, What's even worse, debugging in +production envoirnment is unacceptable, as it will suspend all the threads, leading +to services downtime. + +And if you're thinking of adding some logs to your code to help troubleshsoot the +issue, you'll have to go through the following lifecycle: test, staging, and then to +production, which is for sure going to take a lot of time and also this is an inefficient +approach! Worse still, the issue may not be fixed since it might be irreproduceable +once the JVM is restarted as above. + +Arthas is built to solve these issues. A developer can troubleshoot production +issues on the fly. No JVM restart. no additional code changes. Arthas works as +an observer, that is, it will never suspend your running threads. + +.SH OPTIONS AND ARGUEMENTS + +.TP +.B -h, --help +print usage + +.TP +.B --target-ip +The target JVM listen ip, the default ip is 127.0.0.1 + +.TP +.B --telnet-port +The target jvm listen telnet port, default is 3658 + +.TP +.B --http-port +The target jvm listen http port, default is 8563 + +.TP +.B --session-timeout +The session timeout time in seconds, default 1800 (30min) + +.TP +.B --arthas-home +The arthas home + +.TP +.B --use-version +Use specific version of arthas + +.TP +.B --repo-mirror +Use special maven repository mirror, value is center/aliyun or http repo url. + +.TP +.B --versions +List local and remote arthas versions + +.TP +.B --use-http +Enforce use http to download, default use https + +.TP +.B --attach-only +Attach target process only, do not connect + +.TP +.B --debug-attach +Debug attach agent + +.TP +.B -c, --command +Command to execute, multiple commands separated by ";" + +.TP +.B -f, --batch-file +The batch file to execute + +.TP +.B --height +arthas-client terminal height + +.TP +.B --width +arthas-client terminal width + +.TP +.B -v, --verbose +Verbose, print debug info. + +.TP +.B +Target pid + diff --git a/packaging/src/main/assembly/assembly.xml b/packaging/src/main/assembly/assembly.xml index 9a020f47..a871e65d 100644 --- a/packaging/src/main/assembly/assembly.xml +++ b/packaging/src/main/assembly/assembly.xml @@ -4,6 +4,7 @@ bin false + dir zip