Skip to content

Commit

Permalink
added variables
Browse files Browse the repository at this point in the history
  • Loading branch information
bdito committed Oct 21, 2015
1 parent fb9adb0 commit 34d2a42
Showing 1 changed file with 23 additions and 8 deletions.
31 changes: 23 additions & 8 deletions start.sh
Original file line number Diff line number Diff line change
@@ -1,14 +1,29 @@
#!/bin/bash
set -x
if [ ! -f '/a/data/KeyBoxConfig.properties' ]
then
mv /opt/KeyBox-jetty/jetty/keybox/WEB-INF/classes/KeyBoxConfig.properties /a/data/KeyBoxConfig.properties
fi
ln -sf /a/data/KeyBoxConfig.properties /opt/KeyBox-jetty/jetty/keybox/WEB-INF/classes/KeyBoxConfig.properties

mkdir -p /a/data/keydb
echo \
resetApplicationSSHKey=${resetApplicationSSHKey:-'false'}"
"sshKeyType=${sshKeyType:-'rsa'}"
"sshKeyLength=${sshKeyLength:-'2048'}"
"privateKey=${privateKey:-}"
"publicKey=${publicKey:-}"
"defaultSSHPassphrase=${defaultSSHPassphrase:-'${randomPassphrase}'}"
"enableInternalAudit=${enableInternalAudit:-'false'}"
"deleteAuditLogAfter=${deleteAuditLogAfter:-'90'}"
"auditLogAppender=${auditLogAppender:-}"
"serverAliveInterval=${serverAliveInterval:-'60'}"
"websocketTimeout=${websocketTimeout:-'0'}"
"agentForwarding=${agentForwarding:-'false'}"
"enableOTP=${enableOTP:-'true'}"
"keyManagementEnabled=${keyManagementEnabled:-'true'}"
"forceUserKeyGeneration=${forceUserKeyGeneration:-'true'}"
"authKeysRefreshInterval=${authKeysRefreshInterval:-'120'}"
"passwordComplexityRegEx=${passwordComplexityRegEx:-'((?=.*\\d)(?=.*[A-Z])(?=.*[a-z])(?=.*[!@#$%^&*()+=]).{8\,20})'}"
"passwordComplexityMsg=${passwordComplexityMsg:-'Passwords must be 8 to 20 characters\, contain one digit\, one lowercase\, one uppercase\, and one special character'}"
"jaasModule=${jaasModule:-}\
> /opt/KeyBox-jetty/jetty/keybox/WEB-INF/classes/KeyBoxConfig.properties

rm -rf /opt/KeyBox-jetty/jetty/keybox/WEB-INF/classes/keydb
ln -sf /a/data/keydb /opt/KeyBox-jetty/jetty/keybox/WEB-INF/classes/
ln -sf /a/keydb /opt/KeyBox-jetty/jetty/keybox/WEB-INF/classes/

cd /opt/KeyBox-jetty/jetty/
java -Xmx1024m -jar start.jar

0 comments on commit 34d2a42

Please sign in to comment.