Skip to content

Commit

Permalink
Avoid a warning if directory exists
Browse files Browse the repository at this point in the history
PHP Warning:  mkdir(): File exists in /usr/lib/alternc/install.d/alternc-ssl on line 12
  • Loading branch information
kent1D committed Aug 6, 2017
1 parent c8b3d1a commit d375dc2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ssl/alternc-ssl.install.php
Expand Up @@ -9,7 +9,9 @@
// install ssl.conf
echo "[alternc-ssl] Installing ssl.conf template\n";
copy("/etc/alternc/templates/apache2/mods-available/ssl.conf","/etc/apache2/mods-available/ssl.conf");
mkdir("/var/run/alternc-ssl");
if (!is_dir('/var/run/alternc-ssl')) {
mkdir("/var/run/alternc-ssl");
}
chown("/var/run/alternc-ssl","alterncpanel");
chgrp("/var/run/alternc-ssl","alterncpanel");
// replace open_basedir line if necessary :
Expand Down

0 comments on commit d375dc2

Please sign in to comment.