1
0
forked from ports/contrib
contrib/lighttpd/post-install

15 lines
269 B
Plaintext
Raw Normal View History

2021-02-05 02:19:41 +01:00
#!/bin/sh -
usr=lighttpd
grp=${usr}
dir=${usr}
2021-02-05 02:19:41 +01:00
getent group ${grp} || groupadd -r ${grp}
if [ -z "`getent passwd ${usr}`" ]; then
useradd -r -g ${grp} -d /var/www/${usr} -s /bin/false ${usr}
passwd -l ${usr}
2021-02-05 02:19:41 +01:00
fi
chown ${usr}:daemon /var/log/${usr} /var/lib/${usr}