Преглед изворни кода

Added syncargs to docker-sync for better performance

Mark Shust пре 7 година
родитељ
комит
559f71afc0

+ 3 - 3
README.md

@@ -57,7 +57,7 @@ rm -rf compose .git
 git init
 ```
 
-2. Set a custom name for the external volume. Within `docker-sync.yml` and `docker-compose-dev.yml` there are three references to `magento222_appdata`. Feel free to change these values to your project's name, for example `myapp_appdata`. This will be important when you want to run multiple Docker Compose setups with multiple projects.
+2. Set a custom name for the external volume. Within `docker-sync.yml` and `docker-compose-dev.yml` there are three references to `magento2_appdata`. Feel free to change these values to your project's name, for example `myapp_appdata`. This will be important when you want to run multiple Docker Compose setups with multiple projects.
 
 3. Download the Magento source code to the `src` folder with: `./bin/download 2.2.2`
 
@@ -65,11 +65,11 @@ git init
 
 5. Setup your ip loopback for proper IP resolution with Docker: `./bin/initloopback`
 
-6. Add an entry to `/etc/hosts` with your custom domain: `10.254.254.254 magento-2.2.2.test` (assuming the domain  you want to setup is `magento-2.2.2.test`). Be sure to use a `.test` tld, as `.localhost` and `.dev` will present issues with domain resolution.
+6. Add an entry to `/etc/hosts` with your custom domain: `10.254.254.254 magento2.test` (assuming the domain  you want to setup is `magento2.test`). Be sure to use a `.test` tld, as `.localhost` and `.dev` will present issues with domain resolution.
 
 7. Run Magento's setup install process with the command: `./bin/setup`. Feel free to edit this file to your liking; at the very least you will probably need to update the `base-url` value to the domain you setup in step 6.
 
-8. You may now access your site at `http://magento-2.2.2.test` (or whatever domain you setup). Note that initial page loads will take a bit of time. Once items are primed, everything should load quite fast.
+8. You may now access your site at `http://magento2.test` (or whatever domain you setup). Note that initial page loads will take a bit of time. Once items are primed, everything should load quite fast.
 
 ## Existing Magento Project Setup
 

+ 5 - 2
compose/magento-1/docker-compose-dev.yml

@@ -1,9 +1,12 @@
+# Mark Shust's Magento Docker Compose (https://github.com/markoshust/magento-docker)
+# Version 11.1.3
+
 version: "3"
 
 services:
   app:
     volumes: &appvolumes
-      - foo_appdata:/var/www/html:nocopy
+      - magento1_appdata:/var/www/html:nocopy
       - ~/.composer:/var/www/.composer
 
   phpfpm:
@@ -15,5 +18,5 @@ services:
 
 volumes:
   dbdata:
-  foo_appdata:
+  magento1_appdata:
     external: true

+ 1 - 1
compose/magento-1/docker-compose.yml

@@ -1,5 +1,5 @@
 # Mark Shust's Magento Docker Compose (https://github.com/markoshust/magento-docker)
-# Version 11.0.0
+# Version 11.1.3
 
 version: "3"
 

+ 12 - 2
compose/magento-1/docker-sync.yml

@@ -1,9 +1,19 @@
+# Mark Shust's Magento Docker Compose (https://github.com/markoshust/magento-docker)
+# Version 11.1.3
+
 version: "2"
 
 syncs:
-  foo_appdata:
-    notify_terminal: true
+  magento1_appdata:
+    notify_terminal: false
     src: ./src
     sync_strategy: native_osx
     sync_userid: 1000
     sync_groupid: 1000
+    sync_args:
+      - "-ignore='Path .idea'"
+      - "-ignore='Path .git'"
+      - "-ignore='BelowPath .git'"
+      - "-ignore='Path var/cache/*'"
+      - "-ignore='Path var/sessions/*'"
+      - "-ignore='Path node_modules/*'"

+ 1 - 1
compose/magento-2/bin/setup

@@ -6,7 +6,7 @@ docker-compose exec phpfpm su -c "/usr/local/bin/php ./bin/magento setup:install
   --db-name=magento \
   --db-user=magento \
   --db-password=magento \
-  --base-url=http://magento-2.2.2.test/ \
+  --base-url=http://magento2.test/ \
   --admin-firstname=Admin \
   --admin-lastname=User \
   --admin-email=dummy@gmail.com \

+ 3 - 3
compose/magento-2/docker-compose-dev.yml

@@ -1,12 +1,12 @@
 # Mark Shust's Magento Docker Compose (https://github.com/markoshust/magento-docker)
-# Version 11.1.2
+# Version 11.1.3
 
 version: "3"
 
 services:
   app:
     volumes: &appvolumes
-      - magento222_appdata:/var/www/html:nocopy
+      - magento2_appdata:/var/www/html:nocopy
       - ~/.composer:/var/www/html/var/composer_home
 
   phpfpm:
@@ -18,5 +18,5 @@ services:
 
 volumes:
   dbdata:
-  magento222_appdata:
+  magento2_appdata:
     external: true

+ 1 - 1
compose/magento-2/docker-compose.yml

@@ -1,5 +1,5 @@
 # Mark Shust's Magento Docker Compose (https://github.com/markoshust/magento-docker)
-# Version 11.1.2
+# Version 11.1.3
 
 version: "3"
 

+ 10 - 3
compose/magento-2/docker-sync.yml

@@ -1,12 +1,19 @@
 # Mark Shust's Magento Docker Compose (https://github.com/markoshust/magento-docker)
-# Version 11.1.2
+# Version 11.1.3
 
 version: "2"
 
 syncs:
-  magento222_appdata:
-    notify_terminal: true
+  magento2_appdata:
+    notify_terminal: false
     src: ./src
     sync_strategy: native_osx
     sync_userid: 1000
     sync_groupid: 1000
+    sync_args:
+      - "-ignore='Path .idea'"
+      - "-ignore='Path .git'"
+      - "-ignore='BelowPath .git'"
+      - "-ignore='Path var/cache/*'"
+      - "-ignore='Path var/sessions/*'"
+      - "-ignore='Path node_modules/*'"