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

use default docker compose pattern for dev and production

pull/44/head
Guillaume Vincent пре 8 година
родитељ
комит
2b741f0f92
5 измењених фајлова са 20 додато и 11 уклоњено
  1. +13
    -0
      docker-compose.override.yml
  2. +4
    -0
      docker-compose.prod.yml
  3. +1
    -9
      docker-compose.yml
  4. +1
    -1
      frontend
  5. +1
    -1
      nginx

+ 13
- 0
docker-compose.override.yml Прегледај датотеку

@@ -0,0 +1,13 @@
version: '2'
services:
backend:
volumes:
- ./backend:/backend
command: python manage.py runserver 0.0.0.0:8000
frontend:
volumes:
- ./frontend:/frontend
- node_modules:/frontend/node_modules
command: npm run dev
volumes:
node_modules:

+ 4
- 0
docker-compose.prod.yml Прегледај датотеку

@@ -1,5 +1,7 @@
version: '2'
services:
db:
restart: always
backend:
restart: always
volumes:
@@ -12,6 +14,8 @@ services:
command: npm start
nginx:
restart: always
environment:
- domain=lesspass.com
volumes:
backend:
frontend:

+ 1
- 9
docker-compose.yml Прегледај датотеку

@@ -1,34 +1,26 @@
version: '2'
services:
db:
restart: always
image: postgres:9.5
volumes:
- postgresql:/var/lib/postgresql/data
backend:
build: ./backend
volumes:
- ./backend:/backend
ports:
- "8000:8000"
depends_on:
- db
command: python manage.py runserver 0.0.0.0:8000
frontend:
build: ./frontend
volumes:
- ./frontend:/frontend
- /frontend/node_modules
ports:
- "8080:8080"
command: npm run dev
nginx:
build: ./nginx
ports:
- "80:80"
- "443:443"
environment:
- domain=lesspass.com
- domain=www.lesspass.com
volumes:
- ./nginx/ssl:/certificates
volumes_from:


+ 1
- 1
frontend

@@ -1 +1 @@
Subproject commit 7f840338d707b3519f97e0cd3f9b44914e5b96fb
Subproject commit 038ad30aee69ba1f1b15804065fa79421939cbcb

+ 1
- 1
nginx

@@ -1 +1 @@
Subproject commit 14cc12d27ddd424a56d9b26eef975632c02cc3fc
Subproject commit 34c2913c10e889a68ee8e14fcd10b9a34f8f335c

Loading…
Откажи
Сачувај