FBA-DeploymentScripts/install.sh

27 lines
460 B
Bash
Raw Normal View History

2020-12-09 21:56:43 +00:00
#!/bin/bash
chmod +x /usr/bin/caddy
groupadd --system caddy
useradd --system \
--gid caddy \
--create-home \
--home-dir /var/lib/caddy \
--shell /usr/sbin/nologin \
--comment "Caddy web server" \
caddy
cp caddy.service /etc/systemd/system/
mkdir /etc/caddy
2020-12-09 23:20:43 +00:00
mkdir /var/www
2020-12-09 21:56:43 +00:00
cp Caddyfile /etc/caddy/
systemctl daemon-reload
systemctl enable caddy
systemctl start caddy
systemctl status caddy
ufw allow proto tcp from 10.25.0.0/24 port 80