Explorar o código

Add remove cache and chmod to var/cache

Bug
gabriel %!s(int64=6) %!d(string=hai) anos
pai
achega
49a08b9d10
Modificáronse 2 ficheiros con 12 adicións e 1 borrados
  1. 12 0
      tools/playbook.yml
  2. 0 1
      tools/src/Services/Mongodb.php

+ 12 - 0
tools/playbook.yml

@@ -304,3 +304,15 @@
 
     - name: Docker up nginx
       command: "docker-compose up -d nginx"
+
+- name: "Clear all cache. Tag=clear_cache_all"
+  hosts: 127.0.0.1
+  connection: local
+  tags: clear_cache_all
+  tasks:
+    - name: "Clear all cache"
+      command: "rm -rf /opt/flowdat/{{ item }}/var/cache/*/"
+      with_items: "{{ lookup('env', 'MODULES_INSTALL').split(',') }}"
+    - name: "Chmod cache"
+      command: "chmod 777 -R /opt/flowdat/{{ item }}/var/cache"
+      with_items: "{{ lookup('env', 'MODULES_INSTALL').split(',') }}"

+ 0 - 1
tools/src/Services/Mongodb.php

@@ -44,7 +44,6 @@ class Mongodb extends InitialService
                 ->addVolumes("./mongodb", "/data/db")
                 ->addVolumes("./extra/statsd/statsd/backend/mongodb/scripts", "/scripts")
                 ->setReservationMemory('10g')
-                ->setReservationCPU("0.2")
                 ->network($this->getRelease()->_network_name)->ipv4_address($this->generateIP($this->ip_server));
         }
     }