-
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
122 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
version: '3.7' | ||
|
||
services: | ||
# nginx - web server | ||
nginx: | ||
build: | ||
context: ./docker-config/nginx | ||
dockerfile: ./Dockerfile | ||
env_file: &env | ||
- ./cms/.env | ||
init: true | ||
ports: | ||
- "8000:80" | ||
volumes: | ||
- cpresources:/var/www/project/cms/web/cpresources | ||
- ./cms/web:/var/www/project/cms/web:cached | ||
# php - run php-fpm | ||
php: | ||
build: &php-build | ||
context: ./docker-config/php-prod-craft | ||
dockerfile: ./Dockerfile | ||
depends_on: | ||
- "mysql" | ||
- "redis" | ||
env_file: | ||
*env | ||
expose: | ||
- "9000" | ||
init: true | ||
volumes: &php-volumes | ||
- cpresources:/var/www/project/cms/web/cpresources | ||
- storage:/var/www/project/cms/storage | ||
- ./cms:/var/www/project/cms:cached | ||
- ./cms/vendor:/var/www/project/cms/vendor:delegated | ||
- ./cms/storage/logs:/var/www/project/cms/storage/logs:delegated | ||
- ./cms/storage/runtime/compiled_templates:/var/www/project/cms/storage/runtime/compiled_templates:delegated | ||
# php - run php-fpm with xdebug | ||
php_xdebug: | ||
build: | ||
context: ./docker-config/php-dev-craft | ||
dockerfile: ./Dockerfile | ||
depends_on: | ||
- "php" | ||
env_file: | ||
*env | ||
expose: | ||
- "9000" | ||
init: true | ||
user: www-data | ||
volumes: | ||
*php-volumes | ||
# queue - runs queue jobs via ./craft queue/listen | ||
queue: | ||
build: | ||
*php-build | ||
command: /var/www/project/run_queue.sh | ||
depends_on: | ||
- "php" | ||
env_file: | ||
*env | ||
expose: | ||
- "9001" | ||
init: true | ||
user: www-data | ||
volumes: | ||
*php-volumes | ||
# mysql - database | ||
mysql: | ||
build: | ||
context: ./docker-config/mysql | ||
dockerfile: ./Dockerfile | ||
env_file: | ||
*env | ||
environment: | ||
MYSQL_ROOT_PASSWORD: secret | ||
MYSQL_DATABASE: project | ||
MYSQL_USER: project | ||
MYSQL_PASSWORD: project | ||
init: true | ||
ports: | ||
- "3306:3306" | ||
volumes: | ||
- db-data:/var/lib/mysql | ||
# redis - key/value database for caching & php sessions | ||
redis: | ||
build: | ||
context: ./docker-config/redis | ||
dockerfile: ./Dockerfile | ||
expose: | ||
- "6379" | ||
init: true | ||
# webpack - frontend build system | ||
webpack: | ||
build: | ||
context: ./docker-config/node-dev-webpack | ||
dockerfile: ./Dockerfile | ||
env_file: | ||
*env | ||
init: true | ||
ports: | ||
- "8080:8080" | ||
volumes: | ||
- ./tsconfig.json:/var/www/project/tsconfig.json:cached | ||
- ./buildchain:/var/www/project/buildchain:cached | ||
- ./buildchain/node_modules:/var/www/project/buildchain/node_modules:delegated | ||
- ./cms/web/dist:/var/www/project/cms/web/dist:delegated | ||
- ./src:/var/www/project/src:cached | ||
- ./cms/templates:/var/www/project/cms/templates:cached | ||
|
||
volumes: | ||
db-data: | ||
cpresources: | ||
storage: |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
FROM mariadb:10.5 |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
FROM mysql:8 |