i’m using docker for a few things at the moment, and want to improve the workflow.
Basically, I have a project folder, and in this folder I have different programs and scripts etc.
project/
- script.py
- program.sh
- Dockerfile
- subfolder/
- more_files
- Dockerfile
I want a Dockerfile that I can put in this folder (as above), or in a subfolder (as above) that will install the programs themselves. For instance, in the above, I want to run the dockerfile in the subfolder, and have it install and run script.py.
The installing and running is fine, but currently I am doing this:
- Zip all of the project directory
- Store it somewhere static on my computer
- Change the dockerfile to ADD this zip file to my docker build
- Unzip on the built machine
This is time consuming, and I need to remember to update the zip file every time I want to test a change. It would be much easier if the script said “Get the parent directory and put all of those contents into the build”. I don’t know how to do this. Is there a way to do this?