Merge "Use patch instead of sed to update Gerrit's x/ route"
This commit is contained in:
commit
0e5aca419b
13
docker/gerrit/patches/serve-x-normally.patch
Normal file
13
docker/gerrit/patches/serve-x-normally.patch
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
diff --git a/java/com/google/gerrit/httpd/raw/StaticModule.java b/java/com/google/gerrit/httpd/raw/StaticModule.java
|
||||||
|
index 414a120194..9d59535a66 100644
|
||||||
|
--- a/java/com/google/gerrit/httpd/raw/StaticModule.java
|
||||||
|
+++ b/java/com/google/gerrit/httpd/raw/StaticModule.java
|
||||||
|
@@ -71,7 +71,7 @@ public class StaticModule extends ServletModule {
|
||||||
|
"/c/*",
|
||||||
|
"/p/*",
|
||||||
|
"/q/*",
|
||||||
|
- "/x/*",
|
||||||
|
+ //"/x/*",
|
||||||
|
"/admin/*",
|
||||||
|
"/dashboard/*",
|
||||||
|
"/groups/self",
|
@ -2,9 +2,12 @@
|
|||||||
tasks:
|
tasks:
|
||||||
- name: Patch Gerrit's webapp routes to not shadow x/
|
- name: Patch Gerrit's webapp routes to not shadow x/
|
||||||
shell: |
|
shell: |
|
||||||
cd /home/zuul/src/gerrit.googlesource.com/gerrit
|
set -ex
|
||||||
|
GERRIT_BASE=/home/zuul/src/gerrit.googlesource.com/gerrit
|
||||||
|
SYSTEM_CONFIG_BASE=/home/zuul/src/opendev.org/opendev/system-config
|
||||||
# Disable the x/ redirection since we have x/ projects
|
# Disable the x/ redirection since we have x/ projects
|
||||||
sed -i -e 's|"/x/\*"\,$|//"/x/*",|g' java/com/google/gerrit/httpd/raw/StaticModule.java
|
patch $GERRIT_BASE/java/com/google/gerrit/httpd/raw/StaticModule.java \
|
||||||
|
$SYSTEM_CONFIG_BASE/docker/gerrit/patches/serve-x-normally.patch
|
||||||
|
|
||||||
- name: Build gerrit
|
- name: Build gerrit
|
||||||
include_role:
|
include_role:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user