aboutsummaryrefslogtreecommitdiff
path: root/nixos-switch.sh
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2020-08-23 13:57:52 -0300
committerEuAndreh <eu@euandre.org>2020-08-23 13:59:43 -0300
commit021b0dd10e1f6b60dc9fdbefd3b87d29aa0fc579 (patch)
tree907589f49375fa02039fc73fe0ab5a4c26732c7d /nixos-switch.sh
parentUpdate prosody user (diff)
downloadserver-021b0dd10e1f6b60dc9fdbefd3b87d29aa0fc579.tar.gz
server-021b0dd10e1f6b60dc9fdbefd3b87d29aa0fc579.tar.xz
Chage DNS record of prosody
Terraform file changes were du to me initially trying to do this via creating a SRV DNS record. However this is not required, because Prosody is already on the $TLD sever, the only difference being that it is listening on a different port.
Diffstat (limited to 'nixos-switch.sh')
-rwxr-xr-xnixos-switch.sh2
1 files changed, 2 insertions, 0 deletions
diff --git a/nixos-switch.sh b/nixos-switch.sh
index 12a7dfe..404cba4 100755
--- a/nixos-switch.sh
+++ b/nixos-switch.sh
@@ -11,6 +11,8 @@ rsync -avzP favicons/ "${TLD}:${DATA_ROOT}/favicons/"
# Ugly hack to change TLS certificates permissions
echo "${USER_PASSWORD}" | ssh "$TLD" sudo -S "\
+sudo chown -R nginx:prosody /var/lib/acme/; \
+sudo chmod 755 /var/lib/acme/; \
sudo chmod 640 /var/lib/acme/${PROSODY_TLD}/key.pem; \
sudo chmod 640 /var/lib/acme/${PROSODY_TLD}/fullchain.pem; \
sudo chmod 770 /var/lib/acme/${PROSODY_TLD}/; \