Initial commit (I feel unsafe)

This commit is contained in:
2026-01-16 00:11:58 -08:00
commit d69daa37bf
121 changed files with 4153 additions and 0 deletions

35
authelia_server-setup Normal file
View File

@@ -0,0 +1,35 @@
#!/bin/bash
# shellcheck source=authelia_server-env
. "${HOME}"/"${USER}"-env
echo -e "\n[+] setting up authelia\n\n-------\n"
echo -e "\n[!] not really automated cuz of the nginx and secrets stuff\n"
mkdir -p "${REDIS_PATH}"
mkdir -p "${VOLUME_PATH}"
mkdir -p "${SECRETS_PATH}"
chown -R "${USER}":"${USER}" "${SECRETS_PATH}"
chmod -R 600 "${SECRETS_PATH}"
echo -e "\n[Q] STOP! scp the secrets if you haven't\n"
sleep 5
echo -e "\n[!] hope you've copied the secrets MANUALLY\n"
cp "${HOME}"/"${USER}"-configuration.yaml "${VOLUME_PATH}"/configuration.yml
envsubst <"${HOME}"/"${USER}"-compose_template.yaml >"${HOME}"/"${USER}"-compose.yaml
sudo docker network create -d bridge "${USER}"_network
sudo docker compose -f "${HOME}"/"${USER}"-compose.yaml up -d
echo "[+] restoring from backup..."
sudo docker compose -f "${HOME}"/"${USER}"-compose.yaml stop
rm -rf "${VOLUME_PATH}"
rclone copy "${BUCKET_PATH}" "${VOLUME_PATH}" -v
sudo docker compose -f "${HOME}"/"${USER}"-compose.yaml start