Script Updates to Version 1.5

01 Jan 2012 by TuxAdmin

Domain.sh Changelog :-

  1. [Bugfix] Added code to create empty access and error log files when creating parent directory for vhosts. Without this code, the log files will be owned by root or www-data user when the webserver is started. Thanks Alexandre!
  2. [Bugfix] Changed logrotate entry so that logs are owned by the domain's user with 660 permissions. The ownership was previously user=www-data, group=adm. This prevented users from clearing/deleting the logfiles.
  3. Removed "root index.php" line from Nginx vhost code. That line does nothing when using a local fastcgi server.

Options.conf Changelog :-

  1. Updated Phpmyadmin download links for Nginx scripts to version 3.4.9.
  2. Added some hints for entering hostname values to be more beginner friendly.

Install.sh Changelog :-

  1. [Bugfix] Corrected the code to detect missing repos for installing mod_fastcgi. It was detecting "non-free" for the LAMP Ubuntu installers, when it should be "multiverse" instead. Thanks Shawn!

As usual, grab the scripts from the Download section.

Those who are affected by the access/error log bug. You can simply do a recursive ownership change on the /logs directory. Do note that this is simply a minor permissions bug and can be safely ignored.

cd /home/user/domains/domain.com/logs
chown -R user:user ./*

Interesting Notes On The Logfile Permissions

  1. Consider using user=www-data group=user for the logfiles. It may be necessary to give the webserver permissions for writing to the logfiles. From tests however, both Apache and Nginx can write to log files with 000 permissions. Might be because the master webserver processes are started by root.

  2. Nginx has a strange chown behavior when re-opening logfiles (invoked with the USR1 signal). After re-opening logfiles, the master Nginx process changes the logfile ownership to the Nginx user (www-data). This does not happen when using the "reload" (HUP) signal that is slower in execution.


Comments