Skip to content
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

Update Docker build process #511

Closed
Acconut opened this issue Oct 13, 2021 · 8 comments
Closed

Update Docker build process #511

Acconut opened this issue Oct 13, 2021 · 8 comments
Assignees

Comments

@Acconut
Copy link
Member

Acconut commented Oct 13, 2021

Previously we used the Docker Build service to build the Docker images by Docker hub themselves. Since they changed their pricing, this feature is no longer available and the Docker images there are outdated: https://hub.docker.com/repository/docker/tusproject/tusd/tags?page=1&ordering=last_updated

Either we try to get a free subscription as an open-source project or build the Docker images on our own and push them to the registry.

@Acconut Acconut self-assigned this Oct 13, 2021
@omBratteng
Copy link
Contributor

Let me know if you need any help with this @Acconut.

@salimkanoun
Copy link

@Acconut
Copy link
Member Author

Acconut commented Oct 15, 2021

Let me know if you need any help with this @Acconut.

Thank you very much for your offering, @omBratteng! That would be very helpful. I don't use Docker on a daily basis, so my knowledge regarding Docker is a bit rusty :)

If I understand our current CI setup correctly, we already build the Docker image on GHA and push it to the registry using the last commit as the tag:

- uses: azure/docker-login@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push docker image
run: |
docker build -t tusproject/tusd:$GITHUB_SHA .
docker push tusproject/tusd:$GITHUB_SHA

This part seems to work fine, as I can see those tags, e.g. https://hub.docker.com/layers/tusproject/tusd/dd44267c082c98e99f08ca88ad85eb0b7fe93ef6/images/sha256-bf372cfa53e6c0314104cc9dcf66b28f7b6957a4276259a527239cfc507366ea?context=explore

In that case, the only thing we need to do, is make the same image available under the latest tag and the corresponding version tag, e.g. v1.7.1. Is that correct? Do you what the commands for that would be?

what about gitub registery ?

The GitHub registry is a possible improvement in the future. But as the Docker registry is the default for many developers, I would like to see an updated image on Docker Hub first :)

@omBratteng
Copy link
Contributor

@Acconut cool, I’ll try to have a PR ready tomorrow.

@Acconut
Copy link
Member Author

Acconut commented Oct 15, 2021

@omBratteng Wow, that would be grand!

Acconut added a commit that referenced this issue Oct 18, 2021
@Acconut
Copy link
Member Author

Acconut commented Oct 18, 2021

Should be working now again

image

@Acconut Acconut closed this as completed Oct 18, 2021
@omBratteng
Copy link
Contributor

Nice, I'll still probably come with a PR later that does multi-arch building, and better metadata on the image itself.

@omBratteng
Copy link
Contributor

omBratteng commented Oct 18, 2021

@Acconut take a look at #515, reach out to me if you want to discuss it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants