This commit is contained in:
cupcakearmy 2019-05-23 09:42:46 +02:00
parent 0b0177d089
commit 5a26a17c33
2 changed files with 40 additions and 25 deletions

View File

@ -22,27 +22,27 @@ steps:
- npm i --only=prod - npm i --only=prod
# - name: deploy - name: deploy
# image: cupcakearmy/drone-deploy image: cupcakearmy/drone-deploy
# pull: always pull: always
# environment: environment:
# PLUGIN_KEY: PLUGIN_KEY:
# from_secret: ssh_key from_secret: ssh_key
# settings: settings:
# host: nicco.io host: nicco.io
# user: root user: root
# port: 1312 port: 1312
# target: /srv/web/obolus target: /srv/web/obolus
# sources: sources:
# - ./api/dist - ./api/dist
# - ./api/node_modules - ./api/node_modules
# - ./www/.next - ./www/.next
# - ./www/server.js - ./www/server.js
# - ./www/node_modules - ./www/node_modules
# - ./docker-compose.prod.yml - ./docker-compose.prod.yml
# commands: commands:
# - docker-compose -f docker-compose.prod.yml down # - docker-compose -f docker-compose.prod.yml down
# - docker-compose -f docker-compose.prod.yml up -d # - docker-compose -f docker-compose.prod.yml up -d
# when: when:
# event: push event: push
# branch: master branch: master

View File

@ -5,6 +5,12 @@ x-defaults: &default
restart: always restart: always
working_dir: /app working_dir: /app
command: npm run prod command: npm run prod
ports:
- 80
networks:
traefik:
external: true
services: services:
api: api:
@ -16,3 +22,12 @@ services:
<<: *default <<: *default
volumes: volumes:
- ./www:/app - ./www:/app
networks:
- default
- traefik
labels:
- traefik.enable=true
- traefik.port=80
- traefik.docker.network=traefik
- traefik.backend=obolus
- traefik.frontend.rule=Host:obolus.nicco.io