Last active
February 14, 2023 13:31
-
-
Save mitsuhiko/94ce11f8372a5e8d1206 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
location /webhook/17cbb307-94ec-446b-a17b-ab82594c974c { | |
if ($request_method != 'POST') { | |
return 405; | |
} | |
content_by_lua 'ngx.print(io.popen("/path/to/script.sh"):read("*a"))'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
ssh -i /path/to/id_rsa -o "StrictHostKeyChecking no" $@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
cd /path/to/repository | |
export GIT_SSH=/path/to/gitssh.sh | |
git pull |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Love it!