-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.example.jsonc
More file actions
224 lines (224 loc) · 9.44 KB
/
config.example.jsonc
File metadata and controls
224 lines (224 loc) · 9.44 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
{
// Global configuration that applies to all sourced groups and repositories unless specifically overridden locally.
"config": {
"destination": "gitlab",
"lfs": true, // Fetch LFS (true) or not (false)
// Determines whether to fetch the repository's avatar (true) or not (false); defaults to true
"fetch_avatar": true, // Applicable only for gitlab sources
"wiki": {
// Determines whether wiki syncing is excluded (true) or included (false); defaults to false
"exclude": false
},
"releases": {
// Determines whether syncing of releases and their assets is excluded (true) or included (false); defaults to false
"exclude": false,
"assets": {
"destination": "dufs",
// If true, assets will not be downloaded but will be linked directly from the original source URL; defaults to false.
"exclude": false,
// Maximum allowed size of assets to be synced. If set to "none", all assets will be synced regardless of size.
"max_size": "1GB"
}
}
},
// Global filters that apply to all sourced groups and repositories unless specifically overridden locally.
"filter": {
"only_new": true, // Sync repositories that do not belong in destination,
"visibility": ["private", "public"], // Fetch both private and public repositories,
"archived": null, // Fetch only archived (true) or only unarchived (false)
"empty": null, // Fetch only empty (true) or non empty (false) repositories
"has_description": null, // Fetch repositories that have their description populated (true) or empty (false)
"license": null, // Filter based on specific licenses ["MIT"], empty string inside the array means it does not have a license
"topics": null, // Filter based on specific topics ["machine-learning", "typescript"]
"pages": null, // Fetch repositories that have their pages enabled (true) or disabled (false)
"discussions": null, // Fetch repositories that have their discussion enabled (true) or disabled (false)
"forked": null, // Fetch repositories that have been forked (true) or not (false)
"name": null, // Filter repositories using regex on the name
"language": null, // Filter based on the primary language of the repository ["typescript", "go"]
// Fetch repositories with a specific number of stars
"stars": {
"min": 0,
"max": null
},
// Fetch repositories with a specific number of watchers
"watchers": {
"min": 0,
"max": null
},
// Fetch repositories with a specific number of forks
"forks": {
"min": 0,
"max": null
},
// Fetch repositories with a specific number of branches
"branches": {
"min": 0,
"max": null
},
// Fetch repositories with a specific number of tags
"tags": {
"min": 0,
"max": null
},
// Fetch repositories that where created between a specific timeframe
"created": {
"min": "2000-01-01T00:00:00Z",
"max": null
},
// Fetch repositories that where updated between a specific timeframe
"updated": {
"min": "2000-01-01T00:00:00Z",
"max": null
},
// Fetch repositories with a specified size (in bytes)
"size": {
"min": 0,
"max": null
},
"issues": {
// Fetch repositories that have their issues enabled (true) or disabled (false)
"enabled": true,
// Fetch repositories with a specific number of open issues
"open": {
"min": 0,
"max": null
}
}
},
"destinations": [
// Configuration settings for the destination GitLab server where repositories will be saved.
{
"id": "gitlab",
"url": "https://gitlab.com/", // URL of the GitLab instance; defaults to "https://gitlab.com/" when empty.
"token": "" // Personal access token for GitLab user authentication.
},
// Configuration settings for the destination DUFS server where assets will be saved.
{
"id": "dufs",
"url": "https://dufs.home.lan" // URL of the DUFS instance
},
{
"id": "gitea",
"url": "https://gitea.home.lan", // URL of the Gitea instance;
"token": "", // Personal access token for Gitea user authentication.
"timeout": 7200, // Timeout for all HTTP requests in seconds, Defaults to 10 minutes
"git_timeout": 7200, // Timeout for all Git requests in seconds, Defaults to 1 hour
"ignore_tls": true // To ignore TLS certificate errors
}
],
// Defines the source platforms from which repositories will be synced.
"sources": [
{
"id": "github",
"auth": {
"token": "" // Personal access token for GitHub user authentication.
},
// Overrides global configuration for GitHub-sourced repositories, if specified.
"config": {/*...*/},
// Overrides global filters for GitHub-sourced repositories, if specified.
"filter": {/*...*/}
},
{
"id": "huggingface",
"timeout": 660, // Timeout for all HTTP requests in seconds, Defaults to 10 minutes
"auth": {
"token": "" // Personal access token for HuggingFace user authentication.
},
// Overrides global configuration for HuggingFace-sourced repositories, if specified.
"config": {/*...*/},
// Overrides global filters for HuggingFace-sourced repositories, if specified.
"filter": {/*...*/}
},
{
"id": "gitlab",
"auth": {
"token": "" // Personal access token for GitLab user authentication.
},
// Overrides global configuration for GitLab-sourced repositories, if specified.
"config": {/*...*/},
// Overrides global filters for GitLab-sourced repositories, if specified.
"filter": {/*...*/}
},
{
"id": "gitlab-custom-1", // Prefix "gitlab" + anything else (must be unique)
"base_url": "https://gitlab.example.com", // The base url of the gitlab instance
"auth": {
"token": "" // Personal access token for GitLab user authentication.
},
"config": {/*...*/},
"filter": {/*...*/}
},
{
"id": "git-proxmox",
"auth": {
// For custom authorization
"username": "", // optional
"token": "" // optional
},
"filter": {
"only_new": false
}
}
],
// Configuration for specific groups of repositories
"groups": [
{
"source": "github", // Indicates the source platform: either "github", "gitlab" or "huggingface".
"username": "opensearch-project", // Username of the group in the source platform.
"gitlab_group_id": 1227, // Parent GitLab group ID where the repositories will be saved.
"include_only": ["OpenSearch"], // If set, only specified repositories will be synced.
// Local overriding configuration specific to this group.
"config": {/*...*/},
// Local overriding filters specific to this group.
"filter": {/*...*/},
// Configuration of specific repositories. If empty, will use group's configuration.
"repositories": [
{
"name": "OpenSearch", // Name of the repository.
// Local overriding filters specific to this repository, e.x. fetch only if when stars exceed the number 10
"filter": {
"stars": {
"min": 10
}
},
// Local overriding configuration specific to this repository.,
"wiki": {
"exclude": true
},
"releases": {
"exclude": true,
"assets": {
"exclude": true,
"threshold": 5,
"max_size": "1GB"
}
}
}
// Additional repositories can be specified here...
]
},
{
"source": "huggingface",
"username": "ilsp",
"gitlab_group_id": 7107,
"exclude": [""] // If set, will exclude all mentioned repositories
},
{
"source": "huggingface",
"destination": "gitea",
"username": "ilsp",
"gitea_username": "ilsp-mirror" // Defaults to username
},
{
"source": "git-proxmox",
"username": "proxmox",
"repositories": [
{
"name": "lxc",
"url": "https://git.proxmox.com/git/lxc.git"
}
]
}
// Additional groups can be specified here...
]
}