dist: drop dist/common/scripts/jmx_run, use scripts/scylla-jmx

This commit is contained in:
Takuya ASADA 2015-12-01 23:27:22 +09:00
parent c6fc4e8340
commit bcc99b274f
8 changed files with 15 additions and 15 deletions

View File

@ -1,5 +0,0 @@
#!/bin/sh -e
args="-Djava.net.preferIPv4Stack=true -Dcom.sun.management.jmxremote.port=$JMX_LOCAL_PORT -Dcom.sun.management.jmxremote.rmi.port=$JMX_LOCAL_PORT -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false"
exec java $args -jar /usr/lib/scylla/jmx/urchin-mbean-1.0.jar

View File

@ -1 +1,8 @@
JMX_LOCAL_PORT=7199
# The jmx port to open
JMX_PORT=7199
# The API port to connect to
API_PORT=10000
# The API address to connect to
ADDR=127.0.0.1

View File

@ -33,7 +33,7 @@ install -m644 dist/redhat/systemd/scylla-jmx.service $RPM_BUILD_ROOT%{_unitdir}/
install -d -m755 $RPM_BUILD_ROOT%{_prefix}/lib/scylla
install -d -m755 $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx
install -m644 target/urchin-mbean-1.0.jar $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx/
install -m755 dist/common/scripts/* $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx
install -m755 scripts/scylla-jmx $RPM_BUILD_ROOT%{_prefix}/lib/scylla/jmx
%pre
/usr/sbin/groupadd scylla 2> /dev/null || :
@ -66,7 +66,7 @@ rm -rf $RPM_BUILD_ROOT
%{_sysconfdir}/sysconfig/scylla-jmx
%{_unitdir}/scylla-jmx.service
%{_prefix}/lib/scylla/jmx/jmx_run
%{_prefix}/lib/scylla/jmx/scylla-jmx
%{_prefix}/lib/scylla/jmx/urchin-mbean-1.0.jar
%changelog

View File

@ -8,7 +8,7 @@ Type=simple
EnvironmentFile=/etc/sysconfig/scylla-jmx
User=scylla
Group=scylla
ExecStart=/usr/lib/scylla/jmx/jmx_run
ExecStart=/usr/lib/scylla/jmx/scylla-jmx -jp $JMX_PORT -p $API_PORT -a $ADDR -l /usr/lib/scylla/jmx
KillMode=process
Restart=always

View File

@ -20,7 +20,7 @@ override_dh_auto_install:
cp $(CURDIR)/NOTICE $(DOC)
mkdir -p $(DEST)
cp $(CURDIR)/dist/common/scripts/* $(DEST)
cp $(CURDIR)/scripts/scylla-jmx $(DEST)
cp $(CURDIR)/target/urchin-mbean-1.0.jar $(DEST)
%:

View File

@ -20,7 +20,6 @@ DESC="Scylla JMX server"
NAME=scylla-jmx
SCYLLA_JMX=scylla-jmx
DAEMON=/usr/lib/scylla/jmx/jmx_run
PIDFILE=/var/run/scylla-jmx.pid
SCRIPTNAME=/etc/init.d/$NAME
@ -30,7 +29,7 @@ SCRIPTNAME=/etc/init.d/$NAME
# Read configuration variable file if it is present
[ -r /etc/default/$NAME ] && . /etc/default/$NAME
export JMX_LOCAL_PORT
DAEMON=/usr/lib/scylla/jmx/scylla-jmx -jp $JMX_PORT -p $API_PORT -a $ADDR -l /usr/lib/scylla/jmx
# Define LSB log_* functions.
. /lib/lsb/init-functions

View File

@ -13,6 +13,5 @@ console log
script
. /etc/default/scylla-jmx
export JMX_LOCAL_PORT
exec /usr/lib/scylla/jmx/jmx_run
exec /usr/lib/scylla/jmx/scylla-jmx -jp $JMX_PORT -p $API_PORT -a $ADDR -l /usr/lib/scylla/jmx
end script

View File

@ -62,4 +62,4 @@ do
esac
done
java -Dapiaddress=$API_ADDR -Dapiport=$API_PORT -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=$JMX_PORT -Dcom.sun.management.jmxremote.rmi.port=$JMX_PORT -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -jar $LOCATION/urchin-mbean-1.0.jar
exec java -Dapiaddress=$API_ADDR -Dapiport=$API_PORT -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=$JMX_PORT -Dcom.sun.management.jmxremote.rmi.port=$JMX_PORT -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -jar $LOCATION/urchin-mbean-1.0.jar