Publish Docker image to allow users the ability to pull a container in Github actions #115
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In response to this StackOverflow question and #42, publishing a Docker image for users of this action will allow them to directly pull the image instead of having to build the source code each time. This reduces the time to prepare the action from ~30 seconds to ~8
To enable this change to work, you will have to create a new repository in DockerHub, and add your username and password to the Secrets configuration in GitHub
It's worth noting that you can publish an image to the GitHub repository if you wish, and the instructions for that can be found here:
https://docs.github.com/en/actions/guides/publishing-docker-images
To view an example of what this change enables, please see the changes made in this PR in conjunction with the DockerHub image, and an example use case:
Example Usage: https://github.com/TheQueenIsDead/action-caching/blob/main/.github/workflows/push.yml
Example Repo Workflow: https://github.com/TheQueenIsDead/action-caching/runs/3259818711?check_suite_focus=true
(Please be aware the example workflow failed, but after the fact, and seemingly due to the fact that my commit message includes characters that are perhaps not being handled. The
Setup Job
andPull thequeenisdead/gh-action-bump-version
steps are the most important things to look at)