-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
125 lines (114 loc) · 4.18 KB
/
Copy pathdocker-compose.yml
File metadata and controls
125 lines (114 loc) · 4.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
################################################################################
#
# This file is part of SplashSync Project.
#
# Copyright (C) Splash Sync <www.splashsync.com>
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
#
# For the full copyright and license information, please view the LICENSE
# file that was distributed with this source code.
#
# @author Bernard Paquier <contact@splashsync.com>
#
################################################################################
################################################################################
# Docker Compose File
#
# This Docker File intend to Create a Complete Dev Environment
# for Splash Modules on Magento 2
#
# To us different PS Version configured, you need to add hosts to /etc/hosts
#
# 172.104.0.99 latest.magento2.local
# 172.104.0.100 toolkit.magento2.local
# 172.104.0.200 phpmyadmin.magento2.local
#
################################################################################
version: '3.0'
services:
################################################################################
# Magento 2 Latest
magento:
build:
context: ./docker/magento
dockerfile: mage-2.4-php7.4.Dockerfile
container_name: magento2-latest
ports:
- "80:80"
depends_on:
- mysql
- elasticsearch
volumes:
- ./:/builds/SplashSync/Magento2:ro
entrypoint: docker-entrypoint.sh
env_file:
- docker/magento/env
networks:
magento2: { ipv4_address: 172.104.0.99 }
splashsync: { aliases: [ latest.magento2.local ] }
################################################################################
# MySQL Container
mysql:
image: mysql:5.7
container_name: magento2-mysql
logging: { driver: "none" }
env_file:
- docker/magento/env
networks:
- magento2
################################################################################
# ElasticSearch Container
elasticsearch:
image: 'docker.elastic.co/elasticsearch/elasticsearch:7.5.2'
container_name: magento2-elastic
logging: { driver: "none" }
environment:
ES_JAVA_OPTS: '${ES_JAVA_OPTS:--Xms512m -Xmx512m}'
discovery.type: 'single-node'
cluster.routing.allocation.disk.threshold_enabled: "false"
index.blocks.read_only_allow_delete: null
networks:
- 'magento2'
################################################################################
# Splash Toolkit Container
toolkit:
image: 'splashsync/toolkit'
container_name: magento2-toolkit
logging: { driver: "none" }
volumes:
# Specify Local Configuration File
- './docker/toolkit/splash.yml:/app/config/packages/splash.yml:ro'
hostname: toolkit.magento2.local
command: ["php", "/app/bin/console", "server:run", "172.104.0.100:80"]
networks:
magento2: { ipv4_address: 172.104.0.100, aliases: [ toolkit.magento2.local ] }
splashsync: { aliases: [ toolkit.magento2.local ] }
################################################################################
# PhpMyAdmin Container
phpmyadmin:
image: phpmyadmin/phpmyadmin:5
container_name: magento2-phpmyadmin
logging: { driver: "none" }
depends_on:
- mysql
env_file:
- docker/magento/env
networks:
magento2: { ipv4_address: 172.104.0.200, aliases: [ phpmyadmin.magento2.local ] }
volumes:
magento-data:
networks:
################################################################################
# Default Private Network
magento2:
driver: bridge
ipam:
config:
- subnet: 172.104.0.0/24
################################################################################
# External Splash Network
splashsync:
external: true