run mkdir with full privileges
This commit is contained in:
parent
a3ba518176
commit
95ffe5898d
|
@ -37,7 +37,7 @@ Environment=XDG_DATA_HOME=/var/lib/barrier/barrier@%i
|
|||
# TrustedServers.txt Directory
|
||||
Environment=FP_DIR=/var/lib/barrier/barrier@%i/barrier/SSL/Fingerprints
|
||||
# Ensure the Fingerprints directory exists
|
||||
ExecStartPre=/usr/bin/mkdir -p "${FP_DIR}"
|
||||
ExecStartPre=+/usr/bin/mkdir -p "${FP_DIR}"
|
||||
|
||||
# This uses openssl commands and grep to get the server's key and
|
||||
# store it in the TrustedServers.txt file. OpenSSL is a requirement
|
||||
|
|
|
@ -28,7 +28,7 @@ Environment=XDG_DATA_HOME=/var/lib/barrier/barrier:24800
|
|||
Environment=CERT_DIR=/var/lib/barrier/barrier:24800/barrier/SSL
|
||||
|
||||
# Create the certificate directory
|
||||
ExecStartPre=/usr/bin/mkdir -p ${CERT_DIR}
|
||||
ExecStartPre=+/usr/bin/mkdir -p ${CERT_DIR}
|
||||
# Create the Barrier.pem certificate if it doesn't exist
|
||||
ExecStartPre=/usr/bin/sh -c "[ -f ${CERT_DIR}/Barrier.pem ] || openssl req -x509 -nodes -days 365 -subj '/CN=Barrier' -newkey rsa:2048 -text -keyout ${CERT_DIR}/Barrier.pem -out ${CERT_DIR}/Barrier.pem"
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@ Environment=XDG_DATA_HOME=/var/lib/barrier/barrier%i
|
|||
Environment=CERT_DIR=/var/lib/barrier/barrier%i/barrier/SSL
|
||||
|
||||
# Create the certificate directory
|
||||
ExecStartPre=/usr/bin/mkdir -p ${CERT_DIR}
|
||||
ExecStartPre=+/usr/bin/mkdir -p ${CERT_DIR}
|
||||
# Create the Barrier.pem certificate if it doesn't exist
|
||||
ExecStartPre=/usr/bin/sh -c "[ -f ${CERT_DIR}/Barrier.pem ] || openssl req -x509 -nodes -days 365 -subj '/CN=Barrier' -newkey rsa:2048 -text -keyout ${CERT_DIR}/Barrier.pem -out ${CERT_DIR}/Barrier.pem"
|
||||
|
||||
|
|
Loading…
Reference in New Issue