The first issue was, that Jenkins didn’t run with the normal user, but it’s own Jenkins user. So I switched to this user
and created an own private/public key using
After this I tried to ssh into git
and got a welcome message:
You’ve successfully authenticated, but GitHub does not provide shell access.
After this I tried to clone the repository to the Jenkins machine and got
hudson.plugins.git.GitException: Could not apply tag …
This problem could be fixed by adding git name and email via
git config --global user.email "firstname.lastname@example.org" git config --global user.name "Jenkins"