commit | 8ab08cce9685c0cc8db590f5f4fab1c99dd95fe9 | [log] [tgz] |
---|---|---|
author | Luca Milanesio <luca.milanesio@gmail.com> | Wed Jun 14 22:08:21 2023 +0100 |
committer | Luca Milanesio <luca.milanesio@gmail.com> | Wed Jun 14 22:08:21 2023 +0100 |
tree | 7056fb1e1e188bf0a17aa4c7e6fc19df479e64c0 | |
parent | c26385604bc42bcb953754a822257c4c8a9b7d65 [diff] |
Fix test dependencies in BUILD Use predefined test dependencies definitions for running the plugin tests. Change-Id: I26ddc1e7f8dd33532b3474b1bc3357b85c927cfa
Gerrit lib module to split the projects' space into virtual hosts similarly of what you would do with an HTTP Server and different domain names.
Build this module as it was a Gerrit plugin:
virtualhost
directory to Gerrit /plugins/virtualhost
bazel build plugins/virtualhost
virtualhost.jar
module is generated under /bazel-genfiles/plugins/virtualhost/
Copy virtualhost.jar
library to Gerrit /lib
and add the following two extra settings to gerrit.config
:
[gerrit] installModule = com.gerritforge.gerrit.modules.virtualhost.GuiceModule [httpd] filterClass = com.gerritforge.gerrit.modules.virtualhost.VirtualHostFilter
/etc/virtualhost.config contains the definition of the virtual hosts and the set of projects included.
Each server
section defines a virtual host and contains a set of projects included. Projects are defined using Gerrit ref-matching expressions and can be repeated multiple times to include multiple matchers.
Example to include all the projects starting with team1/
and the ones starting with the username:
[server "team1.mycompany.com"] projects = team1/* projects = ${username}/*
For all the other server names that are not defined and for SSH access, there is a special default section that lists of visible projects.
Example to include all the projects by default:
[default] projects = ^.*