Skip to content

Instantly share code, notes, and snippets.

@mborodov
Created December 24, 2018 20:00
Show Gist options
  • Save mborodov/f05f94a382aae59a6f253a97dae5c135 to your computer and use it in GitHub Desktop.
Save mborodov/f05f94a382aae59a6f253a97dae5c135 to your computer and use it in GitHub Desktop.
Magento 2 docker sync yml config
version: '2'
services:
web:
image: s.kt-team.de/nike/magento:latest
volumes:
- m2-sync:/repo/magento #add 2
- ${PWD}/../../build/configs/nike.loc/20-xdebug.ini:/etc/php.d/15-xdebug.ini
- ${PWD}/../../build/configs/nike.loc/nginx:/etc/nginx
- ${PWD}/../../build/configs/nike.loc/ssmtp:/etc/ssmtp
- ${PWD}/../../build/configs/nike.loc/env.php:/repo/magento/app/etc/env.php
- ${PWD}/../../magento/pub/media:/repo/magento/pub/media
- ${PWD}/../../id_rsa:/root/.ssh/id_rsa
environment:
LOGIN: "admin"
PASS: "mlsclmcs2221ss"
frontName: "admin"
CACHE_HOST: "cache"
CACHE_PORT: "6379"
FPC_HOST: "fpc"
FPC_PORT: "6379"
SESSION_HOST: "session"
SESSION_PORT: "6379"
DB_HOST: "mysql"
DB_PORT: "3306"
DB_NAME: "magento2"
DB_USERNAME: "root"
DB_PASSWORD: "tmp"
STAND: "loc"
base_url: "http://nike.loc/"
PHP_IDE_CONFIG: "serverName=nike.loc"
links:
- mysql:mysql
- elasticsearch:elasticsearch
ports:
- 80:80/tcp
- 8080:8080/tcp
restart: always
mysql:
image: percona:5.7
environment:
MYSQL_ROOT_PASSWORD: tmp
volumes:
- ${PWD}/../../build/configs/my.cnf:/etc/mysql/conf.d/custom.cnf
- ${PWD}/../../mysql:/var/lib/mysql
ports:
- 3306:3306/tcp
restart: always
elasticsearch:
image: d.kt-team.de/elasticnike
ports:
- 9200:9200
environment:
ES_JAVA_OPTS: "-Xms512m -Xmx512m"
volumes:
- ${PWD}/../../elasticsearch/data:/usr/share/elasticsearch/data
restart: always
cache:
image: redis
command:
- redis-server
session:
image: redis
command:
- redis-server
fpc:
image: redis
command:
- redis-server
volumes:
m2-sync:
external: true
version: "2"
options:
compose-file-path: 'docker-compose.mac.yml'
unison_image: 'eugenmayer/unison:2.51.2.1'
syncs:
m2-sync:
src: '../../magento/'
sync_strategy: 'unison'
sync_excludes: [
'.idea',
'.DS_Store'
]
watch_excludes: [
'.idea',
'.DS_Store'
]
sync_userid: '33'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment