faradayio / cage

Develop and deploy complex Docker applications
http://cage.faraday.io
Apache License 2.0
307 stars 26 forks source link

How to use `cage source mount` #95

Closed cburgmer closed 4 years ago

cburgmer commented 5 years ago

I don't fully understand how cage source mount is meant to work. Some guesses: a) Given source code and artifact (docker container) are the same, mounting the source will just replace what's in the container b) I will build my artifact and then run cage build after every change I want reflected in the container c) I have some kind of a dev mode inside the container to sidestep how the application is served in production

Examples: a) Will work for statics served via Nginx b) webpack build process or JAR artifact c) Run webpack dev mode in container?

emk commented 4 years ago

The usual modes are (a) or (c). There are some issues with running large Node.js compilations inside a running container, because Node is extremely file-system intensive, and mounted file systems are slow.