Clean-up and Caddyfile.example

1. Dismount includes directory when finished.
2. Copy Caddyfile.example to the Caddyfile location.
master
Basil Hendroff 2020-08-03 11:55:01 +08:00 committed by GitHub
parent ed92597233
commit bd92e12b70
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -147,9 +147,13 @@ fi
# Copy pre-written config files
iocage exec "${JAIL_NAME}" cp /mnt/includes/caddy /usr/local/etc/rc.d/
iocage exec "${JAIL_NAME}" cp /mnt/includes/Caddyfile.example /usr/local/www/
iocage exec "${JAIL_NAME}" cp -n /mnt/includes/Caddyfile /usr/local/www/ 2>/dev/null
iocage exec "${JAIL_NAME}" sysrc caddy_enable="YES"
iocage exec "${JAIL_NAME}" sysrc caddy_config="/usr/local/www/Caddyfile"
iocage restart "${JAIL_NAME}"
# Don't need /mnt/includes any more, so unmount it
iocage fstab -r "${JAIL_NAME}" "${INCLUDES_PATH}" /mnt/includes nullfs rw 0 0