2018-06-07 18:52:53 +03:00
|
|
|
version: '3.4'
|
|
|
|
services:
|
|
|
|
# Run browser-sync and compile static assets.
|
|
|
|
#
|
|
|
|
# This is the primary server and it proxies
|
|
|
|
# the Django app so that it can add the fancy
|
|
|
|
# browser refresh JS.
|
|
|
|
assets:
|
|
|
|
build:
|
|
|
|
context: .
|
|
|
|
target: assets
|
2020-05-20 12:47:29 +03:00
|
|
|
image: mozmeao/bedrock_assets:${GIT_COMMIT:-latest}
|
2021-09-07 18:25:20 +03:00
|
|
|
platform: linux/amd64
|
2019-02-25 13:45:53 +03:00
|
|
|
command: gulp
|
2018-06-07 18:52:53 +03:00
|
|
|
ports:
|
2018-06-14 20:41:07 +03:00
|
|
|
- "8000-8010:8000-8010"
|
2018-06-07 18:52:53 +03:00
|
|
|
volumes:
|
|
|
|
- ./media/:/app/media:delegated
|
|
|
|
- ./bedrock/:/app/bedrock:delegated
|
|
|
|
environment:
|
2018-06-07 21:48:13 +03:00
|
|
|
BS_PROXY_URL: "app:8080"
|
2018-06-07 18:52:53 +03:00
|
|
|
BS_OPEN_BROWSER: "false"
|
|
|
|
|
|
|
|
# the django app
|
|
|
|
app:
|
|
|
|
build:
|
|
|
|
context: .
|
|
|
|
target: devapp
|
2020-05-20 12:47:29 +03:00
|
|
|
image: mozmeao/bedrock_test:${GIT_COMMIT:-latest}
|
2021-09-07 18:25:20 +03:00
|
|
|
platform: linux/amd64
|
2018-06-07 21:48:13 +03:00
|
|
|
command: python manage.py runserver 0.0.0.0:8080
|
2018-06-07 18:52:53 +03:00
|
|
|
env_file: .env
|
|
|
|
ports:
|
2018-06-07 21:48:13 +03:00
|
|
|
- "8080:8080"
|
2018-06-07 18:52:53 +03:00
|
|
|
volumes:
|
|
|
|
- ./bedrock/:/app/bedrock:delegated
|
|
|
|
- ./bin/:/app/bin:delegated
|
|
|
|
- ./docker/:/app/docker:delegated
|
|
|
|
- ./etc/:/app/etc:delegated
|
|
|
|
- ./lib/:/app/lib:delegated
|
2019-01-10 03:21:23 +03:00
|
|
|
- ./docs/:/app/docs:delegated
|
2018-06-07 18:52:53 +03:00
|
|
|
- ./media/:/app/media:delegated
|
|
|
|
- ./root_files/:/app/root_files:delegated
|
|
|
|
- ./scripts/:/app/scripts:delegated
|
|
|
|
- ./wsgi/:/app/wsgi:delegated
|
2019-09-06 23:53:00 +03:00
|
|
|
- ./locale/:/app/locale:delegated
|
|
|
|
- ./l10n/:/app/l10n:delegated
|
2018-06-07 18:52:53 +03:00
|
|
|
|
|
|
|
# run the tests against local changes
|
|
|
|
test:
|
2020-05-20 12:47:29 +03:00
|
|
|
image: mozmeao/bedrock_test:${GIT_COMMIT:-latest}
|
2018-06-07 18:52:53 +03:00
|
|
|
env_file: docker/envfiles/test.env
|
|
|
|
volumes:
|
|
|
|
- ./bedrock/:/app/bedrock:delegated
|
|
|
|
- ./bin/:/app/bin:delegated
|
|
|
|
- ./docker/:/app/docker:delegated
|
|
|
|
- ./etc/:/app/etc:delegated
|
|
|
|
- ./lib/:/app/lib:delegated
|
|
|
|
- ./media/:/app/media:delegated
|
|
|
|
- ./root_files/:/app/root_files:delegated
|
|
|
|
- ./scripts/:/app/scripts:delegated
|
2018-11-14 18:54:32 +03:00
|
|
|
- ./tests/:/app/tests:delegated
|
2020-10-21 21:58:45 +03:00
|
|
|
- ./test_infra/:/app/test_infra:delegated
|
2018-06-07 18:52:53 +03:00
|
|
|
- ./wsgi/:/app/wsgi:delegated
|
2019-09-06 23:53:00 +03:00
|
|
|
- ./l10n/:/app/l10n:delegated
|
2018-06-07 18:52:53 +03:00
|
|
|
|
|
|
|
# run tests with no volumes
|
|
|
|
test-image:
|
2020-05-20 12:47:29 +03:00
|
|
|
image: mozmeao/bedrock_test:${GIT_COMMIT:-latest}
|
2018-06-07 18:52:53 +03:00
|
|
|
env_file: docker/envfiles/test.env
|
|
|
|
|
|
|
|
# the django app
|
|
|
|
release:
|
|
|
|
build:
|
|
|
|
context: .
|
|
|
|
target: release
|
|
|
|
args:
|
|
|
|
GIT_SHA: ${GIT_COMMIT:-latest}
|
2020-05-08 23:58:16 +03:00
|
|
|
image: mozmeao/bedrock:${GIT_COMMIT:-latest}
|
2021-09-07 18:25:20 +03:00
|
|
|
platform: linux/amd64
|
2020-04-28 18:04:21 +03:00
|
|
|
|
|
|
|
release-local:
|
2020-05-08 23:58:16 +03:00
|
|
|
image: mozmeao/bedrock:${GIT_COMMIT:-latest}
|
2020-04-27 17:38:07 +03:00
|
|
|
env_file: .env
|
2021-09-10 18:48:53 +03:00
|
|
|
environment:
|
|
|
|
RUN_SUPERVISOR: "true"
|
2020-04-27 17:38:07 +03:00
|
|
|
ports:
|
|
|
|
- "8000:8000"
|
|
|
|
volumes:
|
|
|
|
- ./bedrock/:/app/bedrock:delegated
|
|
|
|
- ./bin/:/app/bin:delegated
|
|
|
|
- ./docker/:/app/docker:delegated
|
|
|
|
- ./etc/:/app/etc:delegated
|
|
|
|
- ./lib/:/app/lib:delegated
|
|
|
|
- ./root_files/:/app/root_files:delegated
|
|
|
|
- ./scripts/:/app/scripts:delegated
|
|
|
|
- ./wsgi/:/app/wsgi:delegated
|
|
|
|
- ./locale/:/app/locale:delegated
|
|
|
|
- ./l10n/:/app/l10n:delegated
|
2018-06-07 18:52:53 +03:00
|
|
|
|
2021-09-10 18:48:53 +03:00
|
|
|
docs:
|
|
|
|
image: mozmeao/bedrock_test:${GIT_COMMIT:-latest}
|
|
|
|
platform: linux/amd64
|
|
|
|
command: sphinx-autobuild "docs" "docs/_build/html" --host 0.0.0.0 --port 8100
|
|
|
|
ports:
|
|
|
|
- "8100:8100"
|
|
|
|
volumes:
|
|
|
|
- ./docs/:/app/docs:delegated
|
|
|
|
|
2018-06-07 18:52:53 +03:00
|
|
|
builder:
|
|
|
|
build:
|
|
|
|
context: .
|
|
|
|
target: python-builder
|
2020-05-20 12:47:29 +03:00
|
|
|
image: mozmeao/bedrock_build:${GIT_COMMIT:-latest}
|
2021-09-07 18:25:20 +03:00
|
|
|
platform: linux/amd64
|
2018-06-07 18:52:53 +03:00
|
|
|
|
|
|
|
app-base:
|
|
|
|
build:
|
|
|
|
context: .
|
|
|
|
target: app-base
|
2020-05-20 12:47:29 +03:00
|
|
|
image: mozmeao/bedrock_code:${GIT_COMMIT:-latest}
|
2021-09-07 18:25:20 +03:00
|
|
|
platform: linux/amd64
|