Gitea Auto Authenticate
Overview
Hosting Gitea in a docker container in a Linux box, I havent managed to enable SSH authentication through. I dont have time to experiment at the moment on another box so I need another solution.
CAUTION : Only use this solution on personal computer. Using Access Token generated in Gitea to authenticate will be easily accessible in clear.
Recipe
Use a Personal API Token to Authenticate.
Log Into Gitea. Go to the user / settings / applications area. Generate a new Token. I will generate one different token per laptop / pc I will use. I only select repository access with read and write privileges. Copy the token. Open a new Terminal, replace {new token} and {mylocalgitrepo.url} and execute the following :
|
|
When replacing {new token} with your token and {mylocalgitrepo.url} with your own repository, no quotes are needed. The information updated will be stored in your .gitconfig file :
|
|