problem with remote fonction
Hi,
I use a ispconfig's module to create clients and websites with th API. I have a problem when I would like to create websites, the website is creating but with the wrong owner: the client's default ( client0).
The output of
cat /etc/passwd/
web17:x:10017:10001::/var/www/clients/client0/web17:/bin/false
web19:x:10019:10001::/var/www/clients/client0/web19:/bin/false
web21:x:10021:10001::/var/www/clients/client0/web21:/bin/false
Each user is creating with the group of the client0 10001
cat /etc/group/
sshusers:x:5002:web1,.........web17,web19,web21
.
.
.
.
client19:x:10015
......
web17 and web21 are not in this file
The output of ispconfig.log
14.03.2012-23:57 - DEBUG - Adding the user: web21
14.03.2012-23:57 - DEBUG - Creating symlink: ln -s /var/log/ispconfig/httpd/testtest.net /var/www/clients/client0/web21/log
14.03.2012-23:57 - DEBUG - Creating symlink: ln -s /var/www/clients/client0/web21/ /var/www/testtest.net
14.03.2012-23:57 - DEBUG - Creating symlink: ln -s /var/www/clients/client0/web21/ /var/www/clients/client0/testtest.net
14.03.2012-23:57 - DEBUG - exec: chown -R web21:client0 /var/www/clients/client0/web21/web
14.03.2012-23:57 - DEBUG - exec: chown web21:client0 /var/www/clients/client0/web21/web
14.03.2012-23:57 - DEBUG - exec: chmod 751 /var/www/clients/client0/web21
14.03.2012-23:57 - DEBUG - exec: chmod 751 /var/www/clients/client0/web21/*
14.03.2012-23:57 - DEBUG - exec: chmod 710 /var/www/clients/client0/web21/web
14.03.2012-23:57 - DEBUG - exec: chmod 777 /var/www/clients/client0/web21/tmp
14.03.2012-23:57 - DEBUG - exec: chmod 755 /var/www/clients/client0/web21/log
14.03.2012-23:57 - DEBUG - exec: chown web21:client0 /var/www/clients/client0/web21
14.03.2012-23:57 - DEBUG - exec: chown web21:client0 /var/www/clients/client0/web21/cgi-bin
14.03.2012-23:57 - DEBUG - exec: chown web21:client0 /var/www/clients/client0/web21/log
14.03.2012-23:57 - DEBUG - exec: chown web21:client0 /var/www/clients/client0/web21/ssl
14.03.2012-23:57 - DEBUG - exec: chown web21:client0 /var/www/clients/client0/web21/tmp
14.03.2012-23:57 - DEBUG - exec: chown -R web21:client0 /var/www/clients/client0/web21/web
14.03.2012-23:57 - DEBUG - exec: chown web21:client0 /var/www/clients/client0/web21/log/error.log
14.03.2012-23:57 - DEBUG - Creating fastcgi starter script directory: /var/www/php-fcgi-scripts/web21/
14.03.2012-23:57 - DEBUG - Creating fastcgi starter script: /var/www/php-fcgi-scripts/web21/.php-fcgi-starter
14.03.2012-23:57 - DEBUG - Creating fastcgi starter script: /var/www/php-fcgi-scripts/web21/.php-fcgi-starter
14.03.2012-23:57 - DEBUG - Writing the vhost file: /etc/apache2/sites-available/testtest.net.vhost
14.03.2012-23:57 - DEBUG - Creating symlink: /etc/apache2/sites-enabled/100-testtest.net.vhost->/etc/apache2/sites-available/testtest.net.vhost
14.03.2012-23:57 - DEBUG - Apache status is: 1
14.03.2012-23:57 - DEBUG - Calling function 'restartHttpd' from module 'web_module'.
The problem comes from ispconfig don't add the group of the user in the website's creation.
When I change manually the owner I have this output
15.03.2012-00:12 - DEBUG - Adding the group: client25
15.03.2012-00:12 - DEBUG - Removed symlink: rm -f /var/www/testtest.net
15.03.2012-00:12 - DEBUG - Removed symlink: rm -f /var/www/clients/client0/testtest.net
15.03.2012-00:12 - DEBUG - Renaming existing directory in new docroot location. mv /var/www/clients/client25/web21 /var/www/clients/client25/web21_bak_2012_03_15
15.03.2012-00:12 - DEBUG - Moving site to new document root: mv /var/www/clients/client0/web21 /var/www/clients/client25
15.03.2012-00:12 - DEBUG - Creating symlink: ln -s /var/www/clients/client25/web21/ /var/www/testtest.net
15.03.2012-00:12 - DEBUG - Creating symlink: ln -s /var/www/clients/client25/web21/ /var/www/clients/client25/testtest.net
I use this same module to create domains on ispconfig and it's work well with the right owner only websites are this problem.
Thank you your help
|