{"id":16521604,"url":"https://github.com/agherzan/git-mirror-me-action","last_synced_at":"2025-10-28T07:31:43.603Z","repository":{"id":40236938,"uuid":"462450955","full_name":"agherzan/git-mirror-me-action","owner":"agherzan","description":"GitHub action for mirroring an existing repository to another one over SSH","archived":false,"fork":false,"pushed_at":"2022-07-27T10:40:59.000Z","size":18,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-05-01T21:03:36.990Z","etag":null,"topics":["git","git-mirror","github-actions","mirror"],"latest_commit_sha":null,"homepage":"","language":"Dockerfile","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/agherzan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":"FUNDING.yml","license":"COPYING.MIT","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":["agherzan"]}},"created_at":"2022-02-22T19:47:53.000Z","updated_at":"2023-02-25T10:39:30.000Z","dependencies_parsed_at":"2022-09-10T23:11:06.419Z","dependency_job_id":null,"html_url":"https://github.com/agherzan/git-mirror-me-action","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agherzan%2Fgit-mirror-me-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agherzan%2Fgit-mirror-me-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agherzan%2Fgit-mirror-me-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agherzan%2Fgit-mirror-me-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/agherzan","download_url":"https://codeload.github.com/agherzan/git-mirror-me-action/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238614645,"owners_count":19501497,"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":["git","git-mirror","github-actions","mirror"],"created_at":"2024-10-11T16:57:06.856Z","updated_at":"2025-10-28T07:31:43.295Z","avatar_url":"https://github.com/agherzan.png","language":"Dockerfile","funding_links":["https://github.com/sponsors/agherzan"],"categories":[],"sub_categories":[],"readme":"\u003c!--\nSPDX-FileCopyrightText: Andrei Gherzan \u003candrei@gherzan.com\u003e\n\nSPDX-License-Identifier: MIT\n--\u003e\n\n# Git Mirror-Me (GMm) GitHub Action\n\n[![License](https://img.shields.io/github/license/agherzan/git-mirror-me-action?label=License)](/COPYING.MIT)\n[![REUSE status](https://api.reuse.software/badge/github.com/agherzan/git-mirror-me-action)](https://api.reuse.software/info/github.com/agherzan/git-mirror-me-action)\n\nThis GitHub action provides the ability to mirror a repository to any other git\nrepository. It wraps/uses the\n[git-mirror-me](https://github.com/agherzan/git-mirror-me) tool.\n\n## Environment variables\n\n#### `GMM_SRC_REPO`\n\n* Sets the source repository for the mirror operation.\n* Defaults to using the `GITHUB_SERVER_URL` and `GITHUB_REPOSITORY` environment\n  variables as `GITHUB_SERVER_URL/GITHUB_REPOSITORY`\n\n#### `GMM_DST_REPO`\n\n* Sets the destination repository for the mirror operation.\n\n#### `GMM_SSH_PRIVATE_KEY`\n\n* The SSH private key used for SSH authentication during git push operation.\n* Password protected SSH keys are not supported.\n* When not defined, `git` operations will be executed without authentication.\n* When defined, a host public key configuration is required.\n\n#### `GMM_SSH_KNOWN_HOSTS`\n\n* The hosts public keys used for host validation.\n* The format needs to be based on the`known_hosts` file.\n\n#### `GMM_DEBUG`\n\n* When set to '1', runs the tools in debug mode.\n\n## Sample configurations\n\n### Workflow for mirroring _this_ repository on push/delete/create\n\n```\nName: Mirror Repository\n\non: [ push, delete, create ]\n\n# We want only one mirror workflow at a time.\nconcurrency:\n  group: git-mirror-me\n\njobs:\n  git-mirror:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: agherzan/git-mirror-me-action@v1\n        env:\n          GMM_SSH_PRIVATE_KEY: ${{ secrets.GMM_SSH_PRIVATE_KEY }}\n          GMM_SSH_KNOWN_HOSTS: ${{ secrets.GMM_SSH_KNOWN_HOSTS }}\n          GMM_DST_REPO: \"git@destination.example:foo/bar.git\"\n```\n\n### Workflow for mirroring an explicit repository on push\n\n```\nName: Mirror Repository\n\non: [ push ]\n\n# We want only one mirror workflow at a time.\nconcurrency:\n  group: git-mirror-me\n\njobs:\n  git-mirror:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: agherzan/git-mirror-me-action@v1\n        env:\n          GMM_SSH_PRIVATE_KEY: ${{ secrets.GMM_SSH_PRIVATE_KEY }}\n          GMM_SSH_KNOWN_HOSTS: ${{ secrets.GMM_SSH_KNOWN_HOSTS }}\n          GMM_SRC_REPO: \"git@source.example:foo/bar.git\"\n          GMM_DST_REPO: \"git@destination.example:foo/bar.git\"\n```\n\n## Contributing\n\nContributions are more than welcome. You can send patches using [GitHub pull\nrequests](https://github.com/agherzan/git-mirror-me-action/pulls).\n\n### Developer Certificate of Origin\n\nThe Developer Certificate of Origin (DCO) is a lightweight way for contributors\nto certify that they wrote or otherwise have the right to submit the code they\nare contributing to the project. Here is the full [text of the\nDCO](https://developercertificate.org/), reformatted for readability:\n\n\u003e By making a contribution to this project, I certify that:\n\u003e\n\u003e a. The contribution was created in whole or in part by me and I have the\n\u003e right to submit it under the open source license indicated in the file; or\n\u003e\n\u003e b. The contribution is based upon previous work that, to the best of my\n\u003e knowledge, is covered under an appropriate open source license and I have the\n\u003e right under that license to submit that work with modifications, whether\n\u003e created in whole or in part by me, under the same open source license (unless\n\u003e I am permitted to submit under a different license), as indicated in the\n\u003e file; or\n\u003e\n\u003e c. The contribution was provided directly to me by some other person who\n\u003e certified (a), (b) or (c) and I have not modified it.\n\u003e\n\u003e d. I understand and agree that this project and the contribution are public\n\u003e and that a record of the contribution (including all personal information I\n\u003e submit with it, including my sign-off) is maintained indefinitely and may be\n\u003e redistributed consistent with this project or the open source license(s)\n\u003e involved.\n\nContributors _sign-off_ that they adhere to these requirements by adding a\n`Signed-off-by` line to commit messages.\n\n```\nThis is my commit message\n\nSigned-off-by: Random J Developer \u003crandom@developer.example.org\u003e\n```\n\nGit has a `-s` command line option to append this automatically to your\ncommit message based on your git configuration (name and email):\n\n```\n$ git commit -s -m 'This is my commit message'\n```\n\n## Maintainers\n\n* Andrei Gherzan `\u003candrei at gherzan.com\u003e`\n\n## LICENSE\n\nThis repository is [reuse](https://reuse.software/) compliant and it is\nreleased under the [MIT](COPYING.MIT) license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fagherzan%2Fgit-mirror-me-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fagherzan%2Fgit-mirror-me-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fagherzan%2Fgit-mirror-me-action/lists"}