0

I have a Webhook (https://github.com/adnanh/webhook) configured as a service. When triggered it runs a bash script with does a few commands including a Git Pull.

I have configured my Ubuntu 20.04 system with a Git SSH key and when I am connected git pull works fine. However when it is triggered via the Webhook I'm getting a permissions issue:

   staging-1 webhook[167184]: git@github.com: Permission denied (publickey).
   staging-1 webhook[167184]: fatal: Could not read from remote repository.
   staging-1 webhook[167184]: Please make sure you have the correct access rights

How can I configure an SSH key for the user the webhook is executing as?

nextgenneo
  • 233
  • 1
  • 4
  • 10

0 Answers0