Notebooks to upload/download marine footage, connect to a citizen science project, train machine learning models and publish marine biological observations.
As described in the PR #235 of the docker file and the CI pipeline, the following logic is applied now:
Run the pipeline in "dev", "master", and PRs to "dev", and "master"
If any of the files we related to the container has changed, then rebuild it.
On a PR, this new image gets the tag of the current branch, in a push it gets the tag of what we push to (dev or master)
To fetch the correct image for the tests: If we're in PR, and the files changed, or we're in dev and master, then fetch current branch. Otherwise, the PR target
Run the tests unconditionally
This results in that the dev or master docker image only gets updated on a push, independent on if the tests pass/fail during that push. (That they will pas should be checked first in a PR).
So this is how it is now. Things that can be optimized are:
[ ] Pull "latest" before building the container every time. Then we can re-use layers which quickens up the build. (The tag latest is already added to the image, only the pulling needs to be added and look up if this automatically re-uses layers)
Note: This has been partially implemented and there is a comment in the Github Actions workflow file which should be added once the Dockerfile has been optimized.
[ ] Build the two stages independently, and push the first one to the registry too. (With 2 stages, we mean the first part that makes the ffmpeg compatible and the second stage would be from the next 'FROM', where we start over with the runtime image to build our image.) This is more explained in Issue : Improve Docker image
As described in the PR #235 of the docker file and the CI pipeline, the following logic is applied now:
This results in that the dev or master docker image only gets updated on a push, independent on if the tests pass/fail during that push. (That they will pas should be checked first in a PR).
So this is how it is now. Things that can be optimized are: