Mirrors repositories to GitHub.
Note: Action runs on branches other than main
execute a dry run and wont update the remote repository.
- Create a fork (if on GitHub) or an empty destination repository, same name as upstream is recommended
- Generate SSH keys:
ssh-keygen -t ed25519 -C github-mirror
- Add the private key as a new secret to this project (
SSH_PRIVATE_KEY_<Repo ID>
, all uppercase) - Add the public key as writeable deployment key
github-mirror
to the destination repository
- Add the private key as a new secret to this project (
- Add configuration to
mirror.yml
- (Optional) Set default branch of the destination repository according to upstream
mirror_config:
- {
src_repo: "<Upstream Git URL>",
dest_repo: "<Destination Repo Name>",
key_id: "<Repo ID>",
}
- ...