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

Require Docker images for Arm64 #246

Open
odidev opened this issue Jul 12, 2023 · 13 comments
Open

Require Docker images for Arm64 #246

odidev opened this issue Jul 12, 2023 · 13 comments

Comments

@odidev
Copy link
Contributor

odidev commented Jul 12, 2023

Hi @SimonEismann 

I have tried to deploy DescartesResearch/Tea-Store microservices on the Arm64 platform by using the Docker-compose Method

Command: docker-compose -f ./examples/docker/docker-compose_default.yaml up -d 

The above command fails due to the unavailability of Arm64 Docker images. 

I have tried building all those images on the Arm64 platform and all are getting built successfully. 

Do you have any plans for supporting the Arm64 platform? It will be helpful if Arm64 Docker images are released. Please share your thoughts on the same.

@SimonEismann
Copy link
Contributor

Hi @odidev, great to hear that building the images manually worked!

Adding support for ARM would be great, would you maybe be interested in providing a PR that adds ARM images?

@odidev
Copy link
Contributor Author

odidev commented Jul 17, 2023

@SimonEismann

I have changed the build_docker.sh file for the release of Arm64 Docker images.

Commit Link: Add ARM64 support to Docker images · odidev/TeaStore@b5f52bd (github.com)

I have used Buildx for building Multi-arch Docker images.

PR Link: Add ARM64 support to Docker images by odidev · Pull Request #248 · DescartesResearch/TeaStore (github.com)

It seems that you are using the development branch for the release of Docker images with the tags development and version tag through the development.yml and prepareRelease.yml files on GitHub. I am happy to contribute if required.

@odidev
Copy link
Contributor Author

odidev commented Jul 27, 2023

@SimonEismann
Thanks for Merging the PR. I couldn't see the Arm64 Docker images on DockerHub. Please let us know the ETA.

@mahmud2011
Copy link

There is still no arm64 image on DockerHub.

@SimonEismann
Copy link
Contributor

Sorry for the late reply.

I've merged the changes back into development to trigger a new version and it ran into some issues with the tests.

Further, it did upload a newer version , see here, but it is not ARM.

Looks like it'll take additional work to get the ARM builds working. I'll take a look at it, but it might take a while until I get around to it.

@odidev
Copy link
Contributor Author

odidev commented Aug 8, 2023

Hi @SimonEismann ,

I have gone through the logs of running tests on GitHub actions.

For the Build and publish Docker images of TeaStore job, I have added the Buildx to build and push multi-arch images. Please find the commit link below: -

Commit Link:- odidev@356ec92

For the rest of the failed Test jobs, we have to login to Dockerhub before using Buildx to build a multi-arch image. Docker Buildx doesn’t support --load flag for multi-platform, so I have added --push flag. This is the reason why tests are failing.

Please check this if it looks good, then I can raise PR for the same.

@SimonEismann
Copy link
Contributor

SimonEismann commented Aug 9, 2023

This looks good. Can you open up a PR against the development branch? We can iterate on that branch to get the images to compile for both platforms and then release a new teastore version.

EDIT: Upon a second look, we would probably need to apply the changes to the release pipeline as well first.

@odidev
Copy link
Contributor Author

odidev commented Aug 10, 2023

Hi @SimonEismann

I have created a fresh PR for the release of multi-arch Docker images in the development branch.

Kindly review this PR and suggest if anything needs to be altered.

PR LINK:- Add ARM64 support to TeaStore Docker images

@odidev
Copy link
Contributor Author

odidev commented Aug 14, 2023

Hi @SimonEismann

Thanks for merging the PR, Docker images with tag development have been released and I have checked the images on the Arm64 platform, they are working fine.

I have gone through the logs of failed tests. In the file build_docker.sh, at line 3, the registry variable is empty. Docker Buildx by default uses library as a registry. See here in the logs.

To release Docker images with the latest and git-version tags, we must give the registry name at line 3 of the build_docker.sh file, we can’t leave it blank.

@SimonEismann
Copy link
Contributor

SimonEismann commented Aug 14, 2023

It is awesome to see that we now have both ARM and x86 images available:
image

I think the registry was left blank for these tests on purpose because we don't want the tests to push the images to docker hub. I'll take a look at how we can stop these tests from pushing the images. However, I've paged out how the maven/docker build interaction works, so it might take a few days until I find the time to look into this.

EDIT: Looking through the thread again, maybe we need to use the --load flag instead of the --push flag for these tests, and only use --push for the step that uploads the images?

@odidev
Copy link
Contributor Author

odidev commented Aug 16, 2023

EDIT: Looking through the thread again, maybe we need to use the --load flag instead of the --push flag for these tests, and only use --push for the step that uploads the images?

Docker-Buildx doesn’t support --load flag if --platform flag has multiple values, like in our case.

For publishing the Multi-arch Docker image, Teastore uses prepareRelease.yml and development.yml workflow files for git-version and development tags respectively. We have already added Buildx support there.

One question, for the latest tag Docker images, Are you publishing them through the build_docker.sh script or is there some other workflow to do so?

@SimonEismann SimonEismann added this to the Minor Release 1.4.3 milestone Aug 21, 2023
@SimonEismann
Copy link
Contributor

I've fixed the tests and'll kick off a new release which should push out a new latest version.

@SimonEismann
Copy link
Contributor

SimonEismann commented Aug 21, 2023

Hm, looks like something isn't quite right in the release pipeline yet. I'll circle back to this later.

@SimonEismann SimonEismann reopened this Aug 21, 2023
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