milis/talimatname/genel/n/nginx/nginx.kos-kur

19 lines
406 B
Plaintext
Raw Normal View History

2018-06-09 00:06:58 +02:00
#!/bin/sh
id www 2>/dev/null
if [ $? -eq 0 ]; then
echo "www kullanicisi zaten tanimli"
else
echo "www kullanicisi olusturuldu"
useradd -M -s /bin/false -c "www user" www
fi
if [ -z "`getent group nginx`" ]; then
/sbin/groupadd --system nginx
fi
if [ -z "`getent passwd nginx`" ]; then
/sbin/useradd -r -g nginx -d /etc/nginx -s /bin/false -c "nginx server" nginx
/bin/passwd -l nginx
fi