Sharing folders on Beanstalk Docker
It is very easy to setup volume sharing in docker. You ideally want the following folders to be shared when a new docker is initialized for you:
/var/logso that you can keep track of logsnginxspecific folders because you will have two instances ofnginxrunning - one ondockerand another onEC2. This allows you to share logs- Also read this post for related info
- your personal workspace or anything that you’d like to share
Here’s how you’d do it. The keyword is VOLUME… in your Dockerfile
VOLUME [ \
"/var/shared/", \
"/etc/nginx/sites-enabled", \
"/var/log/nginx", \
"/ws/" \
]