-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not able to push to git repository using ssh-auth #2638
Comments
Are you able to provide the TaskRun yaml after it has run? I'd like to see the complete object including any Status fields. $ kubectl get -o yaml taskrun <completed taskrun name> I'd also be curious to find out:
Also, it would be great to know what the structure of
|
/kind bug |
I think this issue is similar to #1271 |
@divyansh42 is the SSH key you're using a Github Deploy Key? Did you definitely check the "Allow write access" checkbox when you saved the public key in github? (You can double check this by going to the Deploy Keys page in your repo and you should see something like "Read/Write" on the key description). I just ran through a test with a private repo and I was able to successfully push to master using a Github Deploy Key with Write Access. |
Also, if it still doesnt work try making the first command in your Script this: ln -s /tekton/home/.ssh /root/.ssh |
It is working by adding this command in the script. Thanks! 👍 |
I'm going to close this issue now but have created PR #2663 to document this extra step when using vanilla git commands. |
Expected Behavior
Able to push to the git repo by providing the ssh-auth.
Actual Behavior
Getting the following error while trying to push while I am successfully able to clone the private repo as well.
Steps to Reproduce the Problem
ssh-privatekey
,known hosts
and github repo to clone. This task is modification from the https://github.com/tektoncd/pipeline/blob/v0.11.3/examples/v1beta1/taskruns/git-ssh-creds.yamltkn tr logs -f
Additional Info
Kubernetes version:
Output of
kubectl version
:Tekton Pipeline version:
Output of
tkn version
orkubectl get pods -n tekton-pipelines -l app=tekton-pipelines-controller -o=jsonpath='{.items[0].metadata.labels.version}'
The text was updated successfully, but these errors were encountered: