diff --git a/src/Handler.php b/src/Handler.php
index 978e5311cb7405ec108aacb2a7bcdebe64e78ccf..275608a4ec3855b1bb7595fdfd1b3318ed6bd3d8 100644
--- a/src/Handler.php
+++ b/src/Handler.php
@@ -139,10 +139,13 @@ class Handler extends BaseHandler {
       $file = $projectRoot . '/settings/default/' . $template;
       $link = $webRoot . '/sites/default/' . $template;
       $rendered = $this->config->render($template, file_get_contents($pluginRoot . '/templates/' . $template . '.twig'));
+      if (file_exists($file)) {
+        $fs->chmod($file, 0664);
+      }
       file_put_contents($file, $rendered);
       $rel = substr($fs->makePathRelative($file, $projectRoot . '/' . $link), 3, -1);
       $fs->symlink($rel, $link);
-      $fs->chmod($file, 0664);
+      $fs->chmod($file, 0444);
       if ($this->config->readValue('chg-acl')) {
         $fs->chgrp($file, $this->config->readValue('webserver-groupname'));
       }