diff --git a/bureau/class/m_dom.php b/bureau/class/m_dom.php index 87f9b809..2b5d2c31 100644 --- a/bureau/class/m_dom.php +++ b/bureau/class/m_dom.php @@ -408,7 +408,14 @@ class m_dom { if (! is_dir($dest_root . "/". $domshort)) { mkdir($dest_root . "/". $domshort); } - + + if (! is_dir($dest_root . "/tmp")) { + mkdir($dest_root . "/tmp"); + } + + //on corrige les permissions + exec("sudo /usr/lib/alternc/fixperms.sh -u ".$uid); + // Creation des 3 sous-domaines par défaut : Vide, www et mail $this->set_sub_domain($domain, '', $this->type_url, 'http://www.'.$domain); $this->set_sub_domain($domain, 'www', $this->type_local, '/'. $domshort); diff --git a/etc/alternc/templates/apache2/vhost.conf b/etc/alternc/templates/apache2/vhost.conf index 1e26e49e..2be756c0 100644 --- a/etc/alternc/templates/apache2/vhost.conf +++ b/etc/alternc/templates/apache2/vhost.conf @@ -5,6 +5,7 @@ php_admin_value open_basedir "%%account_root%%:/usr/share/php/:/var/alternc/tmp:/tmp" + php_admin_value upload_tmp_dir %%document_root%%/tmp Options +MultiViews -FollowSymLinks +SymLinksIfOwnerMatch AllowOverride AuthConfig FileInfo Limit Options Indexes diff --git a/src/functions_hosting.sh b/src/functions_hosting.sh index 1671a683..4968618a 100644 --- a/src/functions_hosting.sh +++ b/src/functions_hosting.sh @@ -59,7 +59,7 @@ host_create() { local U_ID=$(get_uid_by_name "$USER") local G_ID=$(get_uid_by_name "$USER") local user_letter=`print_user_letter "$USER"` - local DOCUMENT_ROOT="${HTML_HOME}/${user_letter}/${USER}/$TARGET_DIR" + local DOCUMENT_ROOT="${HTML_HOME}/${user_letter}/${USER}$TARGET_DIR" local ACCOUNT_ROOT="${HTML_HOME}/${user_letter}/${USER}/" local FILE_TARGET="$VHOST_DIR/${user_letter}/$USER/$FQDN.conf"