Closed solvaholic closed 3 years ago
- [ ] On every
push
to main or a version tag, build and push container with version:${{ github.sha }}
- [ ] When build-push-test is run manually, build and push container with version
:${{ github.sha }}
- [ ] When run for a branch, or a version tag, push corresponding image tags/versions
I tested changes for these over in:
- [ ] Clarify in doc: Using
@branchX
in a workflow will pull the Docker image named in that branch'saction.yml
- [ ] Provide instructions to modify
action.yml
when user would like to test changes, using a workflow
These two I'll skip for now, since only one user can make branches in this repo. When I come back to it I'll document how to test changes to the Action using a fork.
- [ ] When a branch is deleted, automatically remove its corresponding Docker image tags
- [ ] Automatically remove SHA-based image tags after some number of days
Currently, that I can see, GitHub's APIs do not provide the ability to programmatically delete a published container.
I guess this issue isn't solved really. I've done all I plan to do with it just now, though, so I'll close it.
What I did
What I expected to happen
octodns-sync pulled the :branchX Docker image and used that.
What happened instead
octodns-sync pulled the :latest Docker image and used that.
This happened because I did not modify
action.yml
in branchX to pull the desired image.Additional info
I'd like to:
push
to main or a version tag, build and push container with version:${{ github.sha }}
:${{ github.sha }}
@branchX
in a workflow will pull the Docker image named in that branch'saction.yml
~action.yml
when user would like to test changes, using a workflow~When everything is checked ☝️ this is considered done.
For posterity: Over in solvaholic/scaling-succotash I tried having a composite Action pull and run the Docker container (rather than use a docker Action). That way I was able to
docker run
an arbitrary tag, using version:${{ github.sha }}
.This worked, inasmuch as it ran the container's entrypoint. But I did not see a straightforward way to get the user's environment variables into the running container where
octodns-sync
could use them.https://github.com/solvaholic/scaling-succotash/blob/8a3a17433113065bf7b13cc10f40c4e51848534c/action.yml