directus tmux et caddy 11

This commit is contained in:
Valentin 2024-02-24 14:35:26 +01:00
parent 6648bc7b0f
commit 66cf88fee4
1 changed files with 3 additions and 1 deletions

View File

@ -262,9 +262,11 @@ if [[ "$answer" == "y" ]]; then
npm init -y &&\
npx directus bootstrap" $username
chown -R caddy:caddy "/home/${username}/${cms_folder}"
session="directus"
su -c "tmux new-session -d -s ${session} &&\
tmux send-keys -t ${session} \"cd /home/${username}/${cms_folder} && npx directus start\" C-m" caddy
tmux send-keys -t ${session} \"cd /home/${username}/${cms_folder} && npx directus start\" C-m" $username
caddyfile="/etc/caddy/Caddyfile"
echo "cms.${domain_name} {" >> $caddyfile