Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- CONFLUENCE_CONFIG_FILE="/opt/synchrony/confluence.cfg.xml"
- ## Set some variables and find the node IP's
- CONFLUENCE_BASEURL="http://localhost:8090/"
- SYNCHRONY_LOG="/opt/synchrony/atlassian-synchrony.log"
- SYNCHRONY_SERVER_IP="1.2.3.4"
- #JWT_PRIVATE_KEY=$(cat ${CONFLUENCE_CONFIG_FILE} | grep 'jwt.private.key\">' | cut -f2 -d">" | cut -f1 -d"<")
- #JWT_PUBLIC_KEY=$(cat ${CONFLUENCE_CONFIG_FILE} | grep 'jwt.public.key\">' | cut -f2 -d">" | cut -f1 -d"<")
- DATABASE_URL="jdbc:oracle:thin:@clu-um-dal-scan.prod.edc.equifax.com:1521:DUMUSDLC_DAL_APP"
- DATABASE_USER=$(cat ${CONFLUENCE_CONFIG_FILE} | grep 'hibernate.connection.username\">' | cut -f2 -d">" | cut -f1 -d"<")
- DATABASE_PASSWORD=$(cat ${CONFLUENCE_CONFIG_FILE} | grep 'hibernate.connection.password\">' | cut -f2 -d">" | cut -f1 -d"<")
- DATABASE_DRIVER_PATH="/opt/synchrony/ojdbc-8.jar"
- SYNCHRONY_CLASSPATH="/opt/synchrony/synchrony-6_2_4.jar"
- SYNCHRONY_CONTEXT_PATH="/synchrony"
- SYNCHRONY_SERVICE_URL="http://uat.confluence.equifax.com/synchrony"
- SYNCHRONY_PID="/opt/synchrony/synchrony.pid"
- _RUNJAVA="/opt/java/jdk1.8.0_131/bin/java -Xms2048k -Xmx2g"
- SYNCHRONY_PROPERTIES="\
- -classpath ${SYNCHRONY_CLASSPATH}:${DATABASE_DRIVER_PATH} \
- -Dsynchrony.cluster.impl=hazelcast-btf \
- -Dsynchrony.port=8091 \
- -Dcluster.listen.port=5701 \
- -Dsynchrony.cluster.base.port=25500 \
- -Dcluster.join.type=tcpip \
- -Dcluster.join.tcpip.members=${SYNCHRONY_SERVER_IP} \
- -Dsynchrony.context.path=${SYNCHRONY_CONTEXT_PATH} \
- -Dsynchrony.cluster.bind=${SYNCHRONY_SERVER_IP} \
- -Dsynchrony.bind=${SYNCHRONY_SERVER_IP} \
- -Dcluster.interfaces=${SYNCHRONY_SERVER_IP} \
- -Dsynchrony.service.url=${SYNCHRONY_SERVICE_URL} \
- -Djwt.private.key=${JWT_PRIVATE_KEY} \
- -Djwt.public.key=${JWT_PUBLIC_KEY} \
- -Dsynchrony.database.url=${DATABASE_URL} \
- -Dsynchrony.database.username=${DATABASE_USER} \
- -Dsynchrony.database.password=${DATABASE_PASSWORD} \
- -Djava.net.preferIPv4Stack=true \
- -Dip.whitelist=127.0.0.1,localhost"
- "(${_RUNJAVA} ${SYNCHRONY_PROPERTIES} -jar /opt/synchrony/synchrony-6_2_4.jar synchrony.core sql & ) >> ${SYNCHRONY_LOG} 2>&1"
- echo "Started synchrony locally..."
- echo "Cluster Bind = $SYNCHRONY_SERVER_IP:8091"
- echo "SYNCHRONY SERVICE URL = $SYNCHRONY_SERVICE_URL"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement