intersystems / intersystems/git-source-control
Fix behavior on nginx
- Vorherrschende Sprache
- ObjectScript
- Sterne
- 22
- Forks
- 14
- Ø Merge
- 1 T. 9 Std.
- Gemergte PRs (30 T.)
- 5
Beschreibung
From separate internal investigation (internal ref: DP-437290):
The Git Source Control module uses a CGI variable of REQUEST_URI during URL parsing / construction.
Relevant code in webuidriver.csp:
`Set url = $Piece($Get(%request.CgiEnvs("REQUEST_URI"),$Get(%request.CgiEnvs("HTTP_URL"))),"?")`
However, traffic from the Nginx web gateway does not come with this variable and causes "Set url" to an empty string and the malformed URL mentioned in the customer's description. (i.e. this variable is good with Apache, not Nginx).
For a workaround for Nginx users, adding this line of code right after the above one fixes the issue.
`Set:(url="") url = %request.URL _ %request.CgiEnvs("PATH_INFO")`
Beitragsleitfaden
Rechercherichtung
Beginne in webuidriver.csp bei der auf REQUEST_URI basierenden URL-Zuweisung. Vergleiche die über %request.URL und PATH_INFO verfügbaren URL-Werte, wenn das Gateway Nginx ist, und überprüfe anschließend das Verhalten mit einer Nginx-Anfrage. Erledigt ist die Aufgabe, wenn die URL-Analyse für Nginx-Datenverkehr keine leere oder fehlerhafte URL mehr erzeugt.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- git, nginx
- Bereich
- backend
- Issue-Typ
- Bug
- Schwierigkeit
- 2/5
- Geschätzter Aufwand
- 1-3 Stunden
- Aktivitätsstatus
- Veraltet
- Klarheit
- Klar beschrieben
- Anfängerfreundlichkeit
- 50/100