]> gitweb.fluxo.info Git - templater.git/commitdiff
Drupal: composer: Makefile: updates settings and adds dumpfiles
authorSilvio Rhatto <rhatto@riseup.net>
Wed, 29 Jul 2020 12:17:04 +0000 (09:17 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Wed, 29 Jul 2020 12:17:04 +0000 (09:17 -0300)
share/templater/drupal-composer/files/Makefile.drupal-composer

index 451f4816e2e5d74d92c8c33076bc1159f77351d9..3ebbceb4c6667edf837bca9bafb5b42789013840 100644 (file)
@@ -53,11 +53,16 @@ composer:
 
 # Drupal settings
 settings:
-       test -s   $(SITES_FOLDER)/sites.php         || cp $(SITES_FOLDER)/example.sites.php            $(SITES_FOLDER)/sites.php
-       test -s   $(SITE_FOLDER)/settings.php       || cp $(SITE_FOLDER)/../example.settings.php       $(SITE_FOLDER)/settings.php
-       test -s   $(SITE_FOLDER)/settings.local.php || cp $(SITE_FOLDER)/../example.settings.local.php $(SITE_FOLDER)/settings.local.php
+       test -s   $(SITES_FOLDER)/sites.php          || cp $(SITES_FOLDER)/example.sites.php           $(SITES_FOLDER)/sites.php
+       test -s   $(SITE_FOLDER)/settings.php        || cp $(SITE_FOLDER)/default.settings.php         $(SITE_FOLDER)/settings.php
+       test -s   $(SITE_FOLDER)/services.yml        || cp $(SITE_FOLDER)/default.services.yml         $(SITE_FOLDER)/services.yml
+       #test -s   $(SITE_FOLDER)/settings.local.php || cp $(SITES_FOLDER)/example.settings.local.php  $(SITE_FOLDER)/settings.local.php
+       #test -s   $(SITE_FOLDER)/settings.local.php || cp $(SITE_FOLDER)/settings.custom.php          $(SITE_FOLDER)/settings.local.php
+       test -s   $(SITE_FOLDER)/settings.local.php  ||                                                touch $(SITE_FOLDER)/settings.local.php
        chmod 640 $(SITE_FOLDER)/settings.local.php
+       chmod 640 $(SITE_FOLDER)/settings.php
        chmod 640 $(SITE_FOLDER)/services.yml
+       chmod 640 $(SITES_FOLDER)/sites.php
 
 # Permissions
 perms:
@@ -78,6 +83,11 @@ deploy: perms reset submodules
        $(DRUSH) cache-rebuild
        $(DRUSH) config-import -y
 
+# Dump files
+dumpfiles:
+       #cp -alf web/sites/default/files backups/$(DATE)
+       tar jcvf backups/$(DATE).tar.bz2 web/sites/default/files
+
 # Load pristine db from the initial upstream developer
 initdb_pristine: settings
        test -s sql/dumps/pristinet.sql.gz && gzip -dc sql/dumps/pristinet.sql.gz | $(DRUSH) sql-cli || true