-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
fix(#19314, #15700): allow ssh
/altssh
subdomains in repo URLs to match webhook payload
#21227
Open
mtbennett-godaddy
wants to merge
9
commits into
argoproj:master
Choose a base branch
from
mtbennett-godaddy:fix-19314
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+123
−59
Conversation
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
Signed-off-by: Matthew Bennett <[email protected]>
🔴 Preview Environment stopped on BunnyshellSee: Environment Details | Pipeline Logs Available commands (reply to this comment):
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #21227 +/- ##
==========================================
- Coverage 55.23% 55.20% -0.03%
==========================================
Files 337 337
Lines 57055 57059 +4
==========================================
- Hits 31515 31502 -13
- Misses 22847 22864 +17
Partials 2693 2693 ☔ View full report in Codecov by Sentry. |
Signed-off-by: Matthew Bennett <[email protected]>
Signed-off-by: Matthew Bennett <[email protected]>
… fix-19314 Signed-off-by: Matthew Bennett <[email protected]>
Signed-off-by: Matthew Bennett <[email protected]>
Signed-off-by: Matthew Bennett <[email protected]>
Signed-off-by: Matthew Bennett <[email protected]>
9 tasks
Signed-off-by: Matthew Bennett <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #19314. Fixes #15700 (cc: @robinlieb). Possibly fixes #16854 (cc: @aki-ks).
util/webhook
’sgetWebUrlRegex
into separateGetWebUrlRegex
andGetApiUrlRegex
.GetWebUrlRegex
allows for optionalaltssh
orssh
subdomain. (Addresses Webhooks not compatible with alternative SSH addressing schemes #19314.)GetWebUrlRegex
andGetApiUrlRegex
both allow for username inhttps?
URLs. (Addresses 2.9.0-RC1: Azure Devops git webhooks do not match with http[s] schemas #15700.)util/webhook
andapplicationset/webhook
to use the two new methods for consistent matching between the two.Justification:
ssh
subdomain over443
: https://docs.github.com/en/authentication/troubleshooting-ssh/using-ssh-over-the-https-portaltssh
subdomain over443
: https://about.gitlab.com/blog/2016/02/18/gitlab-dot-com-now-supports-an-alternate-git-plus-ssh-port/#how-to-use-the-alternate-ssh-connection-on-gitlab.comaltssh
subdomain over443
: https://confluence.atlassian.com/bbkb/port-22-is-blocked-on-local-network-1168865232.htmlHowever, when using these patterns, webhook payload URLs will not include the subdomain, which causes the current regex matching to fail.
Signed-off-by: Matthew Bennett [email protected]
Checklist:
I've updated both the CLI and UI to expose my feature, or I plan to submit a second PR with them.Does this PR require documentation updates?I've updated documentation as required by this PR.My new feature complies with the feature status guidelines.Optional. My organization is added to USERS.md.