-
Notifications
You must be signed in to change notification settings - Fork 149
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds CI/CD pipeline with support for multiple platforms #15
Conversation
adds initial pipeline
So I also want it to set up docker hub, how to do that? Any links to resources is appreciated. |
The step that logins in GHCR needs to change to something like this: - name: 👤 login to docker hub
if: github.event_name != 'pull_request'
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }} And those secrets (DOCKERHUB_USERNAME and DOCKERHUB_TOKEN) need to be configured in the repo secrets (Settings > Secrets and variables > Actions). |
If I want both ghcr and dockee hub would I need two workflows or can I somehow merge them onto one? @jbonadiman |
That's an interesting question. I guess you could go on the naive way and do: login docker hub -> push docker hub and then login ghcr -> push ghcr. But why exactly would you want the image in both places? I mean, those two registries work with free-tiers, so you would be consuming both free-tiers of your account at the same time, I don't see the benefit of doing that 🤔 |
Good question 🤔. I think I did it at first because several different people wanted it on each of the platforms and I couldn't decide so I said why not do both. |
I'd say just stick with what's best/more practical for you and that's fine. Particularly, I never saw a self-hosted project deploying images to multiple registries 🤔 |
I would stick with ghcr thanks, you can undo that commit. |
Done |
Closes #13
📑 Description
I've added a simple pipeline that builds the project on code changes and pull requests and upon any code change to the main branch, also uploads the image to the GHCR.
I chose to use the GHCR because I believe it would be more simple to setup than docker hub (your docker hub account info would have to be setup in the envs of the repo). Feel free to change that, if you wish.
✅ Checks