smartcat-labs / cassandra-diagnostics

Cassandra Node Diagnostics Tools
Apache License 2.0
51 stars 6 forks source link

Move diagnostics configuration to config dir #269

Closed nbozic-zz closed 7 years ago

nbozic-zz commented 7 years ago

When you use installer move first cassandra-diagnostics.yml to Cassandra configuration dir and then use path to add lines to cassandra-env.sh.

Currently this is generated:

### Begin cassandra-diagnostics-installer managed configuration. DO NOT EDIT! ###

JVM_OPTS="$JVM_OPTS -Dcassandra.diagnostics.config=/vagrant/bash-installer/cassandra-diagnostics.yml"
JVM_OPTS="$JVM_OPTS -javaagent:/usr/share/cassandra/lib/cassandra-diagnostics-core-1.4.6.jar"

#### End cassandra-diagnostics-installer managed configuration. DO NOT EDIT! ####

Where you can see path of diagnostics yaml is bound to file I provided when using installer. Maybe we can check if file is in provided config path and if not, first move and then append to cassadra-env.sh -Dcassandra.diagnostics.config=[cassandra config path]/cassandra-diagnostics.yml"