File: puppetdb.sh

package info (click to toggle)
puppetdb 6.2.0-3
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 7,648 kB
  • sloc: ruby: 5,071; sh: 2,329; xml: 1,056; python: 393; makefile: 72; sql: 2
file content (31 lines) | stat: -rwxr-xr-x 520 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/sh

JAVA_ARGS="-Xmx192M"

if [ -f /etc/default/puppetdb ]; then
	. /etc/default/puppetdb
fi

jar_cmd() {
	exec /usr/bin/java $JAVA_ARGS -cp /usr/share/puppetdb/puppetdb.jar clojure.main -m puppetlabs.puppetdb.core "$@"
}

usage() {
	cat <<-EOF
	usage: $0 import|export|version -h|ARGS
	EOF
}

case "$1" in
	version|import|export|anonymize)
		jar_cmd "$@"
		;;
	ssl-setup|config-migration)
		echo "'$1' is not supported, see /usr/share/doc/puppetdb/README.Debian." >&2
		exit 1
		;;
	*)
		usage
		exit 1
		;;
esac