Permalink
Browse files

dev mode setup

  • Loading branch information...
hoatle committed Jul 6, 2017
1 parent a2228e9 commit b0a7ac4e95898ecd12651830917a5f4db9561420
Showing with 33 additions and 0 deletions.
  1. +1 −0 .env-common
  2. +1 −0 .env-dev
  3. +26 −0 docker-compose.yml
  4. +5 −0 run-dev.sh
@@ -0,0 +1 @@
# common environtment variables for dev, prod, review modes
@@ -0,0 +1 @@
# specific environtment variables for dev mode
@@ -0,0 +1,26 @@
version: '3'
services:
dev:
image: ${DOCKER_IMAGE_DEV:-node:8.1.3-alpine}
working_dir: /opt/app
command: sh run-dev.sh
environment:
NODE_ENV: development
PORT: 3000
VIRTUAL_HOST: dev.nodejs.teracy.dev, ~^dev\.nodejs\..*\.xip\.io
VIRTUAL_PORT: 3000
HTTPS_METHOD: noredirect # support both http and https
env_file:
- .env-common
- .env-dev
ports:
- "3000"
- "5858"
volumes:
- .:/opt/app
restart: unless-stopped
# to get this work with https://github.com/jwilder/nginx-proxy
# related: https://github.com/jwilder/nginx-proxy/issues/305
network_mode: bridge
@@ -0,0 +1,5 @@
#!/bin/bash
yarn
yarn run dev

0 comments on commit b0a7ac4

Please sign in to comment.