You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
schema: add new json-schema based schema files to the tree
Add two schema files, one in yaml and one in json, to the tree.
The YAML file is the file to be edited, but in cases where yaml
is an extra dependency we also provide a conversion to raw json.
These yaml files help describe the configuration and may be later
used with validation tools or documentation generators.
Signed-off-by: John Mulligan <[email protected]>
"description": "The configuration for the sambacc tool. sambacc configures Samba and the container\nenvironment to fit Samba's unique needs. This configuration can hold configuration\nfor more than one server \"instance\". The \"configs\" section contains one or more\nconfiguration with a name that can be selected at runtime. Share definitions\nand samba global configuration blocks can be mixed and matched.\n",
6
+
"type": "object",
7
+
"$defs": {
8
+
"section_choices": {
9
+
"description": "Selects sub-sections from elsewhere in the configuration.\n",
10
+
"type": "array",
11
+
"items": {
12
+
"type": "string"
13
+
}
14
+
},
15
+
"feature_flags": {
16
+
"description": "Feature flags are used to enable specific, wide-ranging, features of\nsambacc. For example, it is used to enable clustered mode with ctdb.\n",
17
+
"type": "array",
18
+
"items": {
19
+
"enum": [
20
+
"addc",
21
+
"ctdb"
22
+
]
23
+
}
24
+
},
25
+
"samba_options": {
26
+
"description": "A mapping of values that will be passed into the smb.conf (or equivalent)\nto directly configure Samba.\n",
27
+
"type": "object",
28
+
"additionalProperties": {
29
+
"type": "string"
30
+
}
31
+
},
32
+
"permissions_config": {
33
+
"description": "Settings that enable and manage sambacc's permissions management support.\n",
34
+
"type": "object",
35
+
"properties": {
36
+
"method": {
37
+
"description": "Backend method for controlling permissions on shares",
38
+
"type": "string"
39
+
},
40
+
"status_xattr": {
41
+
"description": "xattr name used to store permissions state",
42
+
"type": "string"
43
+
}
44
+
},
45
+
"additionalProperties": {
46
+
"type": "string"
47
+
}
48
+
},
49
+
"user_entry": {
50
+
"description": "A user that will be instantiated in the local contianer environment to\nin order to provide access to smb shares.\n",
51
+
"type": "object",
52
+
"properties": {
53
+
"name": {
54
+
"description": "The user's name",
55
+
"type": "string"
56
+
},
57
+
"uid": {
58
+
"description": "The Unix UID the user should have",
59
+
"type": "integer"
60
+
},
61
+
"gid": {
62
+
"description": "The Unix GID the user should have",
63
+
"type": "integer"
64
+
},
65
+
"nt_hash": {
66
+
"description": "An NT-Hashed password",
67
+
"type": "string"
68
+
},
69
+
"password": {
70
+
"description": "A plain-text password",
71
+
"type": "string"
72
+
}
73
+
},
74
+
"required": [
75
+
"name"
76
+
],
77
+
"additionalProperties": false
78
+
},
79
+
"group_entry": {
80
+
"description": "A group that will be instantiated in the local contianer environment to\nin order to provide access to smb shares.\n",
81
+
"type": "object",
82
+
"properties": {
83
+
"name": {
84
+
"description": "The group name",
85
+
"type": "string"
86
+
},
87
+
"gid": {
88
+
"description": "The Unix GID the group should have",
89
+
"type": "integer"
90
+
}
91
+
},
92
+
"required": [
93
+
"name"
94
+
],
95
+
"additionalProperties": false
96
+
},
97
+
"domain_user_entry": {
98
+
"description": "A user that will be created in the specified AD domain. These\nusers are populated in the directory after the domain is provisioned.\n",
99
+
"type": "object",
100
+
"properties": {
101
+
"name": {
102
+
"description": "The user's name",
103
+
"type": "string"
104
+
},
105
+
"surname": {
106
+
"description": "A surname for the user",
107
+
"type": "string"
108
+
},
109
+
"given_name": {
110
+
"description": "A given name for the user",
111
+
"type": "string"
112
+
},
113
+
"uid": {
114
+
"type": "integer"
115
+
},
116
+
"gid": {
117
+
"type": "integer"
118
+
},
119
+
"nt_hash": {
120
+
"type": "string"
121
+
},
122
+
"password": {
123
+
"description": "A plain-text password",
124
+
"type": "string"
125
+
},
126
+
"member_of": {
127
+
"description": "A list of group names that the user should belong to",
128
+
"type": "array",
129
+
"items": {
130
+
"type": "string"
131
+
}
132
+
}
133
+
},
134
+
"required": [
135
+
"name"
136
+
],
137
+
"additionalProperties": false
138
+
},
139
+
"domain_group_entry": {
140
+
"description": "A group that will be created in the specified AD domain. These\ngroups are populated in the directory after the domain is provisioned.\n",
141
+
"type": "object",
142
+
"properties": {
143
+
"name": {
144
+
"description": "The group name",
145
+
"type": "string"
146
+
},
147
+
"gid": {
148
+
"type": "integer"
149
+
}
150
+
},
151
+
"required": [
152
+
"name"
153
+
],
154
+
"additionalProperties": false
155
+
}
156
+
},
157
+
"properties": {
158
+
"samba-container-config": {
159
+
"type": "string",
160
+
"title": "Cofiguration Format Version",
161
+
"description": "A short version string that assists in allowing the configuration\nformat to (some day) support incompatible version changes.\n(It is unique to the configuration and is not the version of sambacc)\n"
162
+
},
163
+
"configs": {
164
+
"title": "Container Configurations",
165
+
"description": "A mapping of named configurations (instances) to top-level configuration\nblocks. A useable configuration file must have at least one configuration,\nbut more than one is supported.\n",
166
+
"type": "object",
167
+
"additionalProperties": {
168
+
"type": "object",
169
+
"properties": {
170
+
"shares": {
171
+
"$ref": "#/$defs/section_choices"
172
+
},
173
+
"globals": {
174
+
"$ref": "#/$defs/section_choices"
175
+
},
176
+
"instance_features": {
177
+
"$ref": "#/$defs/feature_flags"
178
+
},
179
+
"permissions": {
180
+
"$ref": "#/$defs/permissions_config"
181
+
},
182
+
"instance_name": {
183
+
"description": "A name that will be set for the server instance.\n",
184
+
"type": "string"
185
+
},
186
+
"domain_settings": {
187
+
"description": "The name of the domain settings. Only used with 'ADDC' feature flag.\n",
188
+
"type": "string"
189
+
}
190
+
},
191
+
"additionalProperties": false
192
+
}
193
+
},
194
+
"shares": {
195
+
"description": "A mapping of share name to share specific configuration. A share can\nhave \"options\" that are passed to Samba. Shares can have an optional\n\"permissions\" section for managing permissions/acls in sambacc.\n",
196
+
"type": "object",
197
+
"additionalProperties": {
198
+
"type": "object",
199
+
"properties": {
200
+
"options": {
201
+
"$ref": "#/$defs/samba_options"
202
+
},
203
+
"permissions": {
204
+
"$ref": "#/$defs/permissions_config"
205
+
}
206
+
},
207
+
"additionalProperties": false
208
+
}
209
+
},
210
+
"globals": {
211
+
"description": "A mapping of samba global configuation blocks. The global section names\nare not passed to Samba. All sections selected by a configuration are\nmerged together before passing to Samba.\n",
212
+
"type": "object",
213
+
"additionalProperties": {
214
+
"type": "object",
215
+
"properties": {
216
+
"options": {
217
+
"$ref": "#/$defs/samba_options"
218
+
}
219
+
},
220
+
"additionalProperties": false
221
+
}
222
+
},
223
+
"domain_settings": {
224
+
"description": "A mapping of AD DC domain configuration keys to domain configurations.\nThese parameters are used when provisioning an AD DC instance.\n",
225
+
"type": "object",
226
+
"additionalProperties": {
227
+
"type": "object",
228
+
"properties": {
229
+
"realm": {
230
+
"type": "string"
231
+
},
232
+
"short_domain": {
233
+
"type": "string"
234
+
},
235
+
"admin_password": {
236
+
"type": "string"
237
+
}
238
+
},
239
+
"required": [
240
+
"realm"
241
+
],
242
+
"additionalProperties": false
243
+
}
244
+
},
245
+
"users": {
246
+
"description": "Users to add to the container environment in order to provide\nShare access-control wihout becoming a domain member server.\n",
247
+
"type": "object",
248
+
"properties": {
249
+
"all_entries": {
250
+
"type": "array",
251
+
"items": {
252
+
"$ref": "#/$defs/user_entry"
253
+
}
254
+
}
255
+
}
256
+
},
257
+
"groups": {
258
+
"description": "Groups to add to the container environment in order to provide\nShare access-control wihout becoming a domain member server.\n",
259
+
"type": "object",
260
+
"properties": {
261
+
"all_entries": {
262
+
"type": "array",
263
+
"items": {
264
+
"$ref": "#/$defs/group_entry"
265
+
}
266
+
}
267
+
}
268
+
},
269
+
"domain_users": {
270
+
"description": "The domain_users section defines initial users that will be automatically\nadded to a newly provisioned domain. This section is a mapping of the\ndomain settings name to a list of domain user entries.\n",
271
+
"type": "object",
272
+
"additionalProperties": {
273
+
"type": "array",
274
+
"items": {
275
+
"$ref": "#/$defs/domain_user_entry"
276
+
}
277
+
}
278
+
},
279
+
"domain_groups": {
280
+
"description": "The domain_groups section defines initial groups that will be\nautomatically added to a newly provisioned domain. This section is\na mapping of the domain settings name to a list of domain group entries.\n",
0 commit comments