Skip to content

Commit

Permalink
Merge pull request #346 from like-it/develop
Browse files Browse the repository at this point in the history
moved it
  • Loading branch information
remco-pc committed Nov 9, 2022
2 parents cdd2e45 + 24c0246 commit 1f43933
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 0 additions & 4 deletions src/Cli/Configure/Plugin/Function_domain_add.php
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,6 @@ function function_domain_add(Parse $parse, Data $data, $domain=''){
try {
File::write($url, Core::object($route->data(), Core::OBJECT_JSON));
File::chmod($url, 0666);
Core::execute('chown www-data:www-data -R ' . $host_dir_root);
Core::execute('chmod 777 -R ' . $host_dir_root);
} catch (Exception | FileWriteException | ObjectException $exception){
return $exception->getMessage() . PHP_EOL;
}
Expand Down Expand Up @@ -243,8 +241,6 @@ function function_domain_add(Parse $parse, Data $data, $domain=''){
try {
File::write($url, Core::object($route->data(), Core::OBJECT_JSON));
File::chmod($url, 0666);
Core::execute('chown www-data:www-data -R ' . $host_dir_root);
Core::execute('chmod 777 -R ' . $host_dir_root);
} catch (Exception | FileWriteException | ObjectException $exception){
return $exception->getMessage() . "\n";
}
Expand Down
4 changes: 4 additions & 0 deletions src/Cli/Configure/Plugin/Function_host_create.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ function function_host_create(Parse $parse, Data $data, $host='', $public_html='
$output = [];
Core::execute('a2enmod rewrite', $output);
$output = [];
$host_dir_root = $object->config(Config::DATA_PROJECT_DIR_ROOT) . 'Host' . $object->config('ds');
Core::execute('chown www-data:www-data -R ' . $host_dir_root);
Core::execute('chmod 777 -R ' . $host_dir_root);
Core::execute('service apache2 restart', $output);

}

0 comments on commit 1f43933

Please sign in to comment.