summarylogtreecommitdiffstats
path: root/caddy.install
blob: d56cbe21244a199bb59513bd611d1c2d47fef3c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
post_install() {
    setcap 'cap_net_bind_service=+ep' /usr/local/bin/caddy

    getent passwd www-data || useradd --system -s /usr/bin/nologin -d / -U www-data

    mkdir -p /etc/ssl/caddy
    chmod 770 /etc/ssl/caddy
    chown www-data:www-data /etc/ssl/caddy
}

post_upgrade() {
    post_install
}