{"id":15747819,"url":"https://github.com/developer-guy/automating-multi-platform-docker-container-deployments","last_synced_at":"2026-01-11T02:37:48.825Z","repository":{"id":237421126,"uuid":"728777890","full_name":"developer-guy/automating-multi-platform-docker-container-deployments","owner":"developer-guy","description":"Automating Multi-Platform Docker Container Deployments in Kubernetes with ArgoCD presentation at Docker Istanbul Community Meetup Group","archived":false,"fork":false,"pushed_at":"2023-12-07T18:04:16.000Z","size":5,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-06T11:24:09.329Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/developer-guy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-12-07T17:11:01.000Z","updated_at":"2023-12-07T18:03:56.000Z","dependencies_parsed_at":"2024-05-01T16:39:26.426Z","dependency_job_id":null,"html_url":"https://github.com/developer-guy/automating-multi-platform-docker-container-deployments","commit_stats":null,"previous_names":["developer-guy/automating-multi-platform-docker-container-deployments"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/developer-guy%2Fautomating-multi-platform-docker-container-deployments","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/developer-guy%2Fautomating-multi-platform-docker-container-deployments/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/developer-guy%2Fautomating-multi-platform-docker-container-deployments/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/developer-guy%2Fautomating-multi-platform-docker-container-deployments/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/developer-guy","download_url":"https://codeload.github.com/developer-guy/automating-multi-platform-docker-container-deployments/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246429449,"owners_count":20775805,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-04T05:21:58.079Z","updated_at":"2026-01-11T02:37:48.819Z","avatar_url":"https://github.com/developer-guy.png","language":"Dockerfile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# automating-multi-platform-docker-container-deployments\nAutomating Multi-Platform Docker Container Deployments in Kubernetes with ArgoCD presentation at Docker Istanbul Community Meetup Group\n\n\n### How to build and push multi-arch images to GitHub Container Registrt (ghcr.io)\n\nThere is an amazing command called `docker init` that can be used to initialize a Dockerfile with a template.\n\n```bash\ndocker init\n```\n\nThen, you should do some modifications on the Dockerfile to make it multi-arch but instead of using `QEMU` to build multi-arch images, we will use Go's native cross-compilation support in which we'll be using `GOOS` and `GOARCH` variables.\n\n```bash\nFROM --platform=$BUILDPLATFORM golang:${GO_VERSION} AS build\n...\n\n\nARG TARGETOS TARGETARCH\nRUN --mount=type=cache,target=/go/pkg/mod/ \\\n    --mount=type=bind,target=. \\\n    CGO_ENABLED=0 GOOS=$TARGETOS GOARCH=$TARGETARCH go build -o /bin/server .\n...\n```\n\nthis modification will make your build process a lot faster!!! 🚀\n\nThen, you should build and push your image to GitHub Container Registry (ghcr.io) with the following command:\n\n\u003e ⚠️ You should be running your own builder instance to be able to build multi-arch images since the Docker Daemon is not supporting multi-arch builds yet.\n\u003e docker buildx create --name my-own-builder --use --bootstrap\n\n\u003e Also do not forget to replace the `developerguy` with your own GitHub username.\n\n```bash\ndocker buildx build -t developerguy/hello-go-server:latest --platform linux/amd64,linux/arm64 . --push\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveloper-guy%2Fautomating-multi-platform-docker-container-deployments","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeveloper-guy%2Fautomating-multi-platform-docker-container-deployments","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveloper-guy%2Fautomating-multi-platform-docker-container-deployments/lists"}