I’m just getting started with github so I’m sorry if this is a stupid question.
I’m trying to set up a cron job that pushes to a github repo.
I’m doing great until the git push part.
If I’m doing a push via ssh I’ll just do git push origin master which then asks me for the password. How can I include the passphrase in the push request?
something like git push origin master -pPASSPHRASE ?
Thanks a lot!
You could set up an SSH key with no password and put it in the .ssh folder of the cron user’s home directory so that it is used automatically. Generally, no-password SSH keys are a bad idea, but if they never leave your server, maybe not so bad.