better way to set permissions and groups and users

Created by Joseph Mills
Keywords:

Right now in the debian postinst file it is adding users and groups that I think can be altered to make better and might not even need in the long run. If any one can give me any suggestions I would [real like that.

Thanks
Joseph

code

chmod -R 2775 /var/zpanel/vmail
addgroup vmail
adduser vmail --home /var/zpanel/vmail --shell /bin/bash --ingroup vmail
chown -R vmail:vmail /var/zpanel/vmail
addgroup ftpgroup
adduser ftpuser --shell /bin/dash --ingroup ftpgroup
find /var/zpanel/logs/proftpd -type f -print0 | xargs -0 chmod 644
find /var/zpanel/logs/proftpd -type d -print0 | xargs -0 chmod 755
chmod -R 2775 /var/zpanel/logs/bind/bind.log