Crontab a git pull from SSH repository with password -
this question has answer here:
- configuring git on ssh login once 13 answers
can pass password in crontab command pipe make access git repository ssh server? like
*/10 * * * cd /path/gitpath/ && git pull ssh://user:password@xxx.xx.xx.xxx/path/reporitory.git
or it's better cron bash script password?
i recommend setting ssh public/private keys, if can. way wouldn't need use password when pulling repo.
https://git-scm.com/book/en/v2/git-on-the-server-generating-your-ssh-public-key
https://help.github.com/articles/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent/
Comments
Post a Comment