-
-
Notifications
You must be signed in to change notification settings - Fork 306
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
Add gitea push hook #1227
Add gitea push hook #1227
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR works for me, but it would be nice if push_gitea
removed the .git suffix from the repo URL, because I haven’t included them in my gitea flake inputs
Co-authored-by: Charlotte <[email protected]>
Hello, is this a work in progress? I wanted to use this feature on my Gitea instance and if needed, test it. |
This PR is done and deployed in production. |
On Fri, Aug 12, 2022 at 05:33:24PM -0700, Victor Freire wrote:
Hello, is this a work in progress? I wanted to use this feature on my Gitea instance and if needed, test it.
I think it is done. I have successfully been using these changes for over a month
…
--
Reply to this email directly or view it on GitHub:
#1227 (comment)
You are receiving this because you commented.
Message ID: ***@***.***>
--
Charlotte
https://darkkirb.de • GPG Key EF5F 367A 95E0 BFA6 • https://keybase.io/darkkirb
|
Can confirm that this PR works in my deployment as well 👍 |
is there a update when this will be upstreamed? Or will this PR be a patch user need to always apply? |
I had to modify it to strip the |
@icewind1991 can you make a suggestion with that change? Then i'll add it. @Ericson2314 could you review/merge this? |
|
||
my $in = $c->request->{data}; | ||
my $url = $in->{repository}->{clone_url} or die; | ||
$url =~ s/.git$//; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$url =~ s/.git$//; | |
$url =~ s/.git$//; | |
$url =~ s/^https?:\/\///; |
Disclaimer: this is probably the 10th or so line of perl I've ever written 🙈
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can follow-up for this part.
The gitea webhook payload is slightly different and not compatible with the github endpoint. This PR adds a new api endpoint
/api/push-gitea
which understands the gitea webhook to trigger jobsets evaluation.