Skip to content
This repository has been archived by the owner on Jan 21, 2022. It is now read-only.

Commit

Permalink
Added creation of RUN_DIR to pre-start script
Browse files Browse the repository at this point in the history
[#130384795]

Signed-off-by: Christian Ang <[email protected]>
  • Loading branch information
angelachin authored and christianang committed Sep 15, 2016
1 parent 95ffe94 commit 351bae9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions jobs/consul_agent/templates/pre-start.erb
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ DATA_DIR=<%= p('consul.agent.mode') == 'server' ? '/var/vcap/store/consul_agent'
CONF_DIR=/var/vcap/jobs/consul_agent/config
CERT_DIR=$CONF_DIR/certs
PKG_DIR=/var/vcap/packages
RUN_DIR=/var/vcap/sys/run/consul_agent

function setup_resolvconf() {
local resolvconf_file
Expand Down Expand Up @@ -35,6 +36,9 @@ function create_directories_and_chown_to_vcap() {
mkdir -p "${CONF_DIR}"
chown -R vcap:vcap "${CONF_DIR}"

mkdir -p "${RUN_DIR}"
chown -R vcap:vcap "${RUN_DIR}"

chown vcap:vcap ${CERT_DIR}/*.{crt,key}
chmod 640 ${CERT_DIR}/*.{crt,key}
}
Expand Down

0 comments on commit 351bae9

Please sign in to comment.