repo-sync / github-sync

⤵️ A GitHub Action for syncing current repository with remote
https://github.com/marketplace/actions/github-repo-sync
MIT License
393 stars 103 forks source link

The current github-sync.sh doesn't support SSH as described in readme #35

Closed R-K-H closed 4 years ago

R-K-H commented 4 years ago

You have

If source_repo is private or with another provider, either (1) use an authenticated HTTPS repo clone url like https://${access_token}@github.com/owner/repository.git or (2) set a SSH_PRIVATE_KEY secret environment variable and use the SSH clone url (emphasis added)

https://github.com/repo-sync/github-sync/blob/3832fe8e2be32372e1b3970bbae8e7079edeec88/github-sync.sh#L32

Still sets the remote url to https which prevents the use of SSH key secrets.

Please advise if there is something else which I might be missing in configuring this to work and I've just overlooked?

R-K-H commented 4 years ago

Closing as I'm not sure I'm correct.

R-K-H commented 4 years ago

Got it working by adding https://${{access_token}}@github.com/owner/repository.git as the full source_repo

helloint commented 2 years ago

Got it working by adding https://${{access_token}}@github.com/owner/repository.git as the full source_repo

Hi @R-K-H have you resolved the issue? looks like this is still HTTPS not SSH Even HTTPS, how to set ${{access_token}}?

Thanks.