Skip to content

Commit b25a4ab

Browse files
committed
Update admin/code_hosts/gitolite.schema.json schema for v
1 parent bd2dc2a commit b25a4ab

File tree

1 file changed

+102
-44
lines changed

1 file changed

+102
-44
lines changed

docs/admin/code_hosts/gitolite.mdx

Lines changed: 102 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -26,52 +26,110 @@ To connect Gitolite to Sourcegraph:
2626
### admin/code_hosts/gitolite.schema.json
2727

2828
{/* SCHEMA_SYNC_START: admin/code_hosts/gitolite.schema.json */}
29-
{/* WARNING: This section is auto-generated during releases. Do not edit manually. */}
30-
{/* Last updated: 2025-07-10T00:07:33Z via sourcegraph/[email protected] */}
3129
```json
3230
{
33-
// A list of repositories to never mirror from this Gitolite instance. Supports excluding by exact name ({"name": "foo"}).
34-
// Other example values:
35-
// - [
36-
// {
37-
// "name": "myrepo"
38-
// },
39-
// {
40-
// "pattern": ".*secret.*"
41-
// }
42-
// ]
43-
"exclude": null,
44-
45-
// SSH cipher to use when cloning via SSH. Must be a valid choice from `ssh -Q cipher`.
46-
"gitSSHCipher": null,
47-
48-
// SSH keys to use when cloning Git repo.
49-
"gitSSHCredential": null,
50-
51-
// REQUIRED:
52-
// Gitolite host that stores the repositories (e.g., [email protected], ssh://[email protected]:2222/).
53-
// Other example values:
54-
55-
// - "ssh://[email protected]:2222/"
56-
"host": null,
57-
58-
// ⚠️ DEPRECATED: DEPRECATED: the Phabricator integration with Gitolite code hosts is deprecated
59-
// This is DEPRECATED
60-
"phabricator": {
61-
"callsignCommand": null,
62-
"url": null
63-
},
64-
65-
// ⚠️ DEPRECATED: DEPRECATED: the Phabricator integration with Gitolite code hosts is deprecated
66-
// This is DEPRECATED
67-
"phabricatorMetadataCommand": null,
68-
69-
// REQUIRED:
70-
// Repository name prefix that will map to this Gitolite host. This should likely end with a trailing slash. E.g., "gitolite.example.com/".
71-
// It is important that the Sourcegraph repository name generated with this prefix be unique to this code host. If different code hosts generate repository names that collide, Sourcegraph's behavior is undefined.
72-
// Other example values:
73-
// - "gitolite.example.com/"
74-
"prefix": null
31+
"$schema": "http://json-schema.org/draft-07/schema#",
32+
"$id": "gitolite.schema.json#",
33+
"title": "GitoliteConnection",
34+
"description": "Configuration for a connection to Gitolite.",
35+
"allowComments": true,
36+
"type": "object",
37+
"additionalProperties": false,
38+
"required": ["prefix", "host"],
39+
"properties": {
40+
"prefix": {
41+
"description": "Repository name prefix that will map to this Gitolite host. This should likely end with a trailing slash. E.g., \"gitolite.example.com/\".\n\nIt is important that the Sourcegraph repository name generated with this prefix be unique to this code host. If different code hosts generate repository names that collide, Sourcegraph's behavior is undefined.",
42+
"not": {
43+
"type": "string",
44+
"pattern": "example\\.com"
45+
},
46+
"type": "string",
47+
"examples": ["gitolite.example.com/"]
48+
},
49+
"host": {
50+
"description": "Gitolite host that stores the repositories (e.g., [email protected], ssh://[email protected]:2222/).",
51+
"not": {
52+
"type": "string",
53+
"pattern": "example\\.com"
54+
},
55+
"type": "string",
56+
"examples": ["[email protected]", "ssh://[email protected]:2222/"]
57+
},
58+
"gitSSHCredential": {
59+
"description": "SSH keys to use when cloning Git repo.",
60+
"$ref": "git.schema.json#/definitions/gitSSHCredential"
61+
},
62+
"gitSSHCipher": {
63+
"description": "SSH cipher to use when cloning via SSH. Must be a valid choice from `ssh -Q cipher`.",
64+
"$ref": "git.schema.json#/definitions/gitSSHCipher"
65+
},
66+
"exclude": {
67+
"description": "A list of repositories to never mirror from this Gitolite instance. Supports excluding by exact name ({\"name\": \"foo\"}).",
68+
"type": "array",
69+
"minItems": 1,
70+
"items": {
71+
"type": "object",
72+
"title": "ExcludedGitoliteRepo",
73+
"additionalProperties": false,
74+
"anyOf": [
75+
{
76+
"required": ["name"]
77+
},
78+
{
79+
"required": ["pattern"]
80+
}
81+
],
82+
"properties": {
83+
"name": {
84+
"description": "The name of a Gitolite repo (\"my-repo\") to exclude from mirroring.",
85+
"type": "string",
86+
"minLength": 1
87+
},
88+
"pattern": {
89+
"description": "Regular expression which matches against the name of a Gitolite repo to exclude from mirroring.",
90+
"type": "string",
91+
"format": "regex"
92+
}
93+
}
94+
},
95+
"examples": [
96+
[
97+
{
98+
"name": "myrepo"
99+
},
100+
{
101+
"pattern": ".*secret.*"
102+
}
103+
]
104+
]
105+
},
106+
"phabricatorMetadataCommand": {
107+
"description": "This is DEPRECATED",
108+
"deprecationMessage": "DEPRECATED: the Phabricator integration with Gitolite code hosts is deprecated",
109+
"type": "string"
110+
},
111+
"phabricator": {
112+
"description": "This is DEPRECATED",
113+
"deprecationMessage": "DEPRECATED: the Phabricator integration with Gitolite code hosts is deprecated",
114+
"type": "object",
115+
"required": ["url", "callsignCommand"],
116+
"additionalProperties": false,
117+
"properties": {
118+
"url": {
119+
"description": "URL of the Phabricator instance that integrates with this Gitolite instance. This should be set ",
120+
"type": "string",
121+
"format": "uri",
122+
"!go": {
123+
"typeName": "NormalizedURL"
124+
}
125+
},
126+
"callsignCommand": {
127+
"description": " Bash command that prints out the Phabricator callsign for a Gitolite repository. This will be run with environment variable $REPO set to the name of the repository and used to obtain the Phabricator metadata for a Gitolite repository. (Note: this requires `bash` to be installed.)",
128+
"type": "string"
129+
}
130+
}
131+
}
132+
}
75133
}
76134
```
77135
{/* SCHEMA_SYNC_END: admin/code_hosts/gitolite.schema.json */}

0 commit comments

Comments
 (0)