@@ -203,7 +203,7 @@ def post_pref(self, apt_packages, packages):
203203 '/etc/nginx/common' )
204204 os .makedirs ('/etc/nginx/common' )
205205
206- data = dict ()
206+ data = dict (webroot = EEVariables . ee_webroot )
207207 Log .debug (self , 'Writting the nginx configuration to '
208208 'file /etc/nginx/common/acl.conf' )
209209 ee_nginx = open ('/etc/nginx/common/acl.conf' , 'w' )
@@ -450,8 +450,9 @@ def post_pref(self, apt_packages, packages):
450450 myfile .write ("<?php\n phpinfo();\n ?>" )
451451
452452 EEFileUtils .chown (self , "{0}22222"
453- .format (EEVariables .ee_webroot ), 'www-data' ,
454- 'www-data' , recursive = True )
453+ .format (EEVariables .ee_webroot ),
454+ EEVariables .ee_php_user ,
455+ EEVariables .ee_php_user , recursive = True )
455456
456457 EEGit .add (self , ["/etc/php5" ], msg = "Adding PHP into Git" )
457458 EEService .reload_service (self , 'php5-fpm' )
@@ -644,7 +645,7 @@ def post_pref(self, apt_packages, packages):
644645 " receive_override_options=no_header_body"
645646 "_checks/\" /etc/postfix/master.cf" )
646647
647- amavis_master = """smtp-amavis unix - - n - 2 smtp
648+ amavis_master = ( """smtp-amavis unix - - n - 2 smtp
648649 -o smtp_data_done_timeout=1200
649650 -o smtp_send_xforward_command=yes
650651 -o disable_dns_lookups=yes
@@ -665,9 +666,9 @@ def post_pref(self, apt_packages, packages):
665666 -o smtpd_hard_error_limit=1000
666667 -o smtpd_client_connection_count_limit=0
667668 -o smtpd_client_connection_rate_limit=0
668- -o receive_override_options=no_header_body_checks,no_unknown_recipient_checks
669- -o local_header_rewrite_clients=
670- """
669+ -o receive_override_options=no_header_body_checks,""" +
670+ """no_unknown_recipient_check
671+ -o local_header_rewrite_clients= """)
671672
672673 with open ("/etc/postfix/master.cf" , "a" ) as am_config :
673674 am_config .write (amavis_master )
@@ -709,11 +710,9 @@ def post_pref(self, apt_packages, packages):
709710 shutil .move ('/tmp/phpmyadmin-STABLE/' ,
710711 '{0}22222/htdocs/db/pma/'
711712 .format (EEVariables .ee_webroot ))
712- Log .debug (self , 'Setting Privileges of www-data:www-data to '
713+ Log .debug (self , 'Setting Privileges of webroot permission to '
713714 '{0}22222/htdocs/db/pma file '
714715 .format (EEVariables .ee_webroot ))
715- # EEShellExec.cmd_exec(self, 'chown -R www-data:www-data '
716- # '/var/www/22222/htdocs/db/pma')
717716 EEFileUtils .chown (self , '{0}22222'
718717 .format (EEVariables .ee_webroot ),
719718 EEVariables .ee_php_user ,
@@ -730,8 +729,6 @@ def post_pref(self, apt_packages, packages):
730729 Log .debug (self , "Setting Privileges to "
731730 "{0}22222/htdocs/cache/memcache file"
732731 .format (EEVariables .ee_webroot ))
733- # EEShellExec.cmd_exec(self, 'chown -R www-data:www-data '
734- # '/var/www/22222/htdocs/cache/memcache')
735732 EEFileUtils .chown (self , '{0}22222'
736733 .format (EEVariables .ee_webroot ),
737734 EEVariables .ee_php_user ,
@@ -757,11 +754,9 @@ def post_pref(self, apt_packages, packages):
757754 "/usr/bin/dot\' \" {0}22222/htdocs/"
758755 "php/webgrind/config.php"
759756 .format (EEVariables .ee_webroot ))
760- Log .debug (self , "Setting Privileges of www-data:www-data to "
757+ Log .debug (self , "Setting Privileges of webroot permission to "
761758 "{0}22222/htdocs/php/webgrind/ file "
762759 .format (EEVariables .ee_webroot ))
763- # EEShellExec.cmd_exec(self, 'chown -R www-data:www-data '
764- # '/var/www/22222/htdocs/php/webgrind/')
765760 EEFileUtils .chown (self , '{0}22222'
766761 .format (EEVariables .ee_webroot ),
767762 EEVariables .ee_php_user ,
@@ -858,7 +853,8 @@ def post_pref(self, apt_packages, packages):
858853
859854 # Custom Vimbadmin configuration by EasyEngine
860855 data = dict (salt = vm_salt , host = EEVariables .ee_mysql_host ,
861- password = vm_passwd )
856+ password = vm_passwd ,
857+ php_user = EEVariables .ee_php_user )
862858 Log .debug (self , 'Writting the ViMbAdmin configuration to '
863859 'file {0}22222/htdocs/vimbadmin/application/'
864860 'configs/application.ini'
@@ -1017,7 +1013,7 @@ def post_pref(self, apt_packages, packages):
10171013 static = False ,
10181014 basic = True , wp = False , w3tc = False , wpfc = False ,
10191015 wpsc = False , multisite = False , wpsubdir = False ,
1020- webroot = '/var/www' , ee_db_name = '' ,
1016+ webroot = EEVariables . ee_webroot , ee_db_name = '' ,
10211017 ee_db_user = '' , ee_db_pass = '' , ee_db_host = '' ,
10221018 rc = True )
10231019
0 commit comments