Automate GitHub Auth
Tags: #naas #asset #snippet #operations
This notebook enable you to access your public key to push to GitHub without typing any username or password. This can make you save a ton of time if you use GitHub to version your data projects and products. We highly recommend you to version your work, each little progress should be logged.
No input required.
Generate the public key:
!ssh-keygen -b 2048 -t rsa -f /home/ftp/.ssh/id_rsa -q -N ""
Retrieve the public key by running the cell below:
- go Github/Settings/SSH and GCP keys
- create new SSH key
- paste the public key in the key section
- name the public key and save
You just changed the way naas connects with GitHub for any repository. It means you need to choose the SSH method to clone now but you can still use Git tab to push.
This technique wil enable you to never use your Git username and password anymore.