Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix mount path of deployment dir in apim job #42

Merged
merged 3 commits into from
Dec 10, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions pattern-2/bosh-release/config/blobs.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
mysqldriver/mysql-connector-java-5.1.45-bin.jar:
size: 999810
object_id: c8b7c254-97cf-48ac-63a7-53ccd2336cc2
sha: 6223be933fbc8d81f819aacad0ce09346d5911c4
mysqldriver/mysql-connector-java-5.1.46-bin.jar:
size: 1004840
object_id: 0a7c82a6-c76d-4670-4f1e-158a88562956
sha: 0a22bced42a2f076aaa17feee67fc6b998cfd4f9
openjdk/jdk-8u202-ea-bin-b03-linux-x64-07_nov_2018.tar.gz:
size: 139097684
object_id: 917acae4-9dd8-47df-59b9-5a8298d18805
object_id: cb15cef2-fcd1-42a2-740a-af8e6d4fef06
sha: 43df5d55fff80327cc83680cda6170f33308883c
wso2am/wso2am-2.6.0.zip:
size: 444084271
object_id: 49748b60-83c3-4839-77d0-c0320fc6cbe8
sha: c31c9c9dd87a6a6065779c28c6908bd76e4914f3
size: 437096938
object_id: 43ce4312-d8b6-4c8c-5ff8-5f0bb9bf7265
sha: 721c82e0a54ab1dc878b19db6654a3db24837109
wso2am_analytics/wso2am-analytics-2.6.0.zip:
size: 180832478
object_id: 72c29a00-c6b5-493d-643d-a0314e0d51ec
sha: b60e811d5abb500f5793cc73012f1040bc2a88c0
size: 174219759
object_id: 3bb62e85-8cea-4d0a-6200-4aaa11619995
sha: 58f7b9013efb0b76721b6b171613ae72f8a51897
4 changes: 2 additions & 2 deletions pattern-2/bosh-release/jobs/gateway/templates/ctl.erb
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ case $1 in
cp -Tr /tmp/gateway/repository/deployment/server/ ${NFS_SHARE_SERVER_DIR}/
fi

ln -s ${NFS_SHARE_SERVER_DIR} $WSO2_APIM_HOME/repository/deployment/server/synapse-configs/
ln -s ${NFS_SHARE_TENANTS_DIR} $WSO2_APIM_HOME/repository/tenants
# ln -s ${NFS_SHARE_SERVER_DIR} $WSO2_APIM_HOME/repository/deployment/server/synapse-configs/
# ln -s ${NFS_SHARE_TENANTS_DIR} $WSO2_APIM_HOME/repository/tenants

$WSO2_APIM_HOME/bin/wso2server.sh start

Expand Down
2 changes: 1 addition & 1 deletion pattern-2/bosh-release/jobs/nfs_server/templates/ctl.erb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ pid_file=${run_dir}/pid
mkdir -p ${run_dir} ${log_dir}
chown -R vcap:vcap ${run_dir} ${log_dir}

export NFS_EXPORT_SERVER_DIR=/mnt/nfs-export/wso2am/deployment/server
export NFS_EXPORT_SERVER_DIR=/mnt/nfs-export/wso2am/deployment-server
export NFS_EXPORT_TENANTS_DIR=/mnt/nfs-export/wso2am/tenants

export DEBUG_LOG=${log_dir}/nfs_server.log
Expand Down
12 changes: 6 additions & 6 deletions pattern-2/bosh-release/jobs/wso2apim/templates/ctl.erb
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ export JAVA_OPTS=" -Xmx${MAX_HEAP}m -Xms${MIN_HEAP}m -XX:MaxPermSize=${MAX_PERMG

export DEBUG_LOG=${log_dir}/wso2apim.log

export NFS_EXPORT_SERVER_DIR=/mnt/nfs-export/wso2am/repository/deployment/server
export NFS_EXPORT_SERVER_DIR=/mnt/nfs-export/wso2am/deployment-server

export NFS_SHARE_SERVER_DIR=/mnt/nfs-share/wso2am/repository/deployment/server/jaggeryapps
export NFS_SHARE_SERVER_DIR=/mnt/nfs-share/wso2am/repository/deployment/server

touch $DEBUG_LOG
chmod -R 755 /var/vcap/sys
Expand Down Expand Up @@ -98,15 +98,15 @@ case $1 in
cp /var/vcap/packages/mysqldriver/* ${WSO2_APIM_HOME}/repository/components/lib/

mkdir /tmp/wso2am
mv $WSO2_APIM_HOME/repository/deployment/server/jaggeryapps/ /tmp/wso2am
mv $WSO2_APIM_HOME/repository/deployment/server/ /tmp/wso2am

mount -t nfs <%= link("nfs-server").instances[0].address %>:${NFS_EXPORT_SERVER_DIR}/jaggeryapps ${NFS_SHARE_SERVER_DIR}
mount -t nfs <%= link("nfs-server").instances[0].address %>:${NFS_EXPORT_SERVER_DIR} ${NFS_SHARE_SERVER_DIR}

if [ -z "$(ls -A ${NFS_SHARE_SERVER_DIR})" ]; then
cp -Tr /tmp/wso2am/repository/deployment/server/jaggeryapps/ ${NFS_SHARE_SERVER_DIR}/
cp -r /tmp/wso2am/server/* ${NFS_SHARE_SERVER_DIR}
fi

ln -s ${NFS_SHARE_SERVER_DIR} $WSO2_APIM_HOME/repository/deployment/server/jaggeryapps
ln -s ${NFS_SHARE_SERVER_DIR} $WSO2_APIM_HOME/repository/deployment/

$WSO2_APIM_HOME/bin/wso2server.sh start

Expand Down