Skip to content

Instantly share code, notes, and snippets.

@hernandev
Created August 18, 2016 19:30
Show Gist options
  • Save hernandev/14b31358338a5bbe01eb023fd922656c to your computer and use it in GitHub Desktop.
Save hernandev/14b31358338a5bbe01eb023fd922656c to your computer and use it in GitHub Desktop.
Vue Docker Compose
version: '2'
services:
# Web server - For live reload and development
# This environment can be used to run npm and node
# commands as well
dev:
image: ambientum/node:6
command: node build/dev-server.js
volumes:
- .:/var/www/app
ports:
- 8080:8080
# Testing dist on a "real" webserver
production-server:
image: nginx:stable-alpine
volumes:
- ./dist:/usr/share/nginx/html
ports:
- 9090:80
@gustavocardoso
Copy link

HI!

I've tried this approach on my local machine. But, I was able to run the "build" only (on port 9090). I couldn't run the dev on port 8080!
Does it work for you!?!

Thanx!

@gustavocardoso
Copy link

Hey...

I just found a solution here: webpack/webpack-dev-server#547 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment