{"id":14069673,"url":"https://github.com/pmorelli92/github-container-registry-build-push","last_synced_at":"2025-07-30T06:32:18.633Z","repository":{"id":39639154,"uuid":"330186599","full_name":"pmorelli92/github-container-registry-build-push","owner":"pmorelli92","description":"Github Action that builds and pushes a docker image to Github Container Registry","archived":true,"fork":false,"pushed_at":"2023-12-05T16:53:24.000Z","size":9,"stargazers_count":12,"open_issues_count":0,"forks_count":9,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-04-23T19:24:11.196Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pmorelli92.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2021-01-16T14:56:50.000Z","updated_at":"2024-06-10T14:22:16.607Z","dependencies_parsed_at":"2024-06-12T09:02:16.263Z","dependency_job_id":null,"html_url":"https://github.com/pmorelli92/github-container-registry-build-push","commit_stats":{"total_commits":9,"total_committers":4,"mean_commits":2.25,"dds":0.5555555555555556,"last_synced_commit":"fc48636de278363701ac07b6317820e4dfb514d6"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmorelli92%2Fgithub-container-registry-build-push","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmorelli92%2Fgithub-container-registry-build-push/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmorelli92%2Fgithub-container-registry-build-push/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pmorelli92%2Fgithub-container-registry-build-push/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pmorelli92","download_url":"https://codeload.github.com/pmorelli92/github-container-registry-build-push/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228102071,"owners_count":17869774,"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-08-13T07:07:07.878Z","updated_at":"2024-12-04T11:30:30.729Z","avatar_url":"https://github.com/pmorelli92.png","language":"Shell","funding_links":[],"categories":["Shell"],"sub_categories":[],"readme":"## ARCHIVED\n\nI recently started working again with Github Actions and given the fact that I needed to send build arguments and secrets to the Dockerfile I started to look at all the alternatives available as those are not supported in this repo.\n\nI found that the `docker/build-push-action` works for pushing into the GHCR as well, so what was the biggest benefit of this action is now taken care somewhere else with more features and mainteinance. Therefore I suggest that you switch over to that one, I leave below a little snippet on how I used the action:\n\n```\n- name: Set up Docker Buildx\n  uses: docker/setup-buildx-action@v3\n\n- name: Login to GHCR\n  uses: docker/login-action@v3\n  with:\n    registry: ghcr.io/my-org\n    username: ${{ github.actor }}\n    password: ${{ secrets.GITHUB_TOKEN }}\n\n- name: Build and push\n  uses: docker/build-push-action@v5\n  with:\n    push: true\n    tags: |\n      ghcr.io/my-org/my-svc:latest\n      ghcr.io/my-org/my-svc:some-tag\n    build-args: |\n      \"x=y\"\n      \"foo=bar\"\n    secrets: |\n      \"secret-id=${{secrets.SECRET_VALUE}}\"\n```\n\n# GitHub Container Registry : Build and push\n\nGithub Action that builds and pushes a docker image to Github Container Registry.\n\n## Example\n\n```yaml\njobs:\n  build-svc:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions/checkout@v2\n        name: Checkout repository\n\n      - uses: pmorelli92/github-container-registry-build-push@2.2.1\n        name: Build and Publish latest service image\n        with:\n          github-push-secret: ${{secrets.GITHUB_TOKEN}}\n          docker-image-name: my-svc\n          docker-image-tag: latest # optional\n          dockerfile-path: Dockerfile # optional\n          build-context: . # optional\n          build-only: false # optional\n          docker-build-args: FOO=BAR,OTHER=VALUE # optional\n```\n\n## Inspirations and acknowledgments\n\nI heavily inspired on [gp-docker-action](https://github.com/VaultVulp/gp-docker-action) repository made by [Pavel Alimpiev](https://github.com/VaultVulp). This mentioned repo is pushing towards the *GitHub Packages Docker Registry* instead of the new *GitHub Container Registry*.\n\n[More information on the new Github Container Registry here.](https://docs.github.com/en/packages/guides/migrating-to-github-container-registry-for-docker-images)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpmorelli92%2Fgithub-container-registry-build-push","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpmorelli92%2Fgithub-container-registry-build-push","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpmorelli92%2Fgithub-container-registry-build-push/lists"}