-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.libsonnet_example
54 lines (51 loc) · 1.02 KB
/
config.libsonnet_example
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
{
fqdn: "image-registry.hu",
appname: "image-registry",
ns: "image-registry",
dbpw: 'bddsbdf',
nfsvol: "/image_registry",
nfsserver: "server.reg",
storagecapacity: "1Ti",
PV(name, ns=self.ns, cap='1G', path='/srv/vols', server=self.nfsserver): {
apiVersion: 'v1',
kind: 'PersistentVolume',
metadata: {
name: name,
},
spec: {
capacity: {
storage: cap,
},
volumeMode: 'Filesystem',
accessModes: [
'ReadWriteMany',
],
persistentVolumeReclaimPolicy: 'Retain',
nfs: {
path: path,
server: server,
},
},
},
PVC(name, pvname, ns=self.ns, cap='1G'): {
apiVersion: 'v1',
kind: 'PersistentVolumeClaim',
metadata: {
name: name,
namespace: ns,
},
spec: {
accessModes: [
'ReadWriteMany',
],
volumeMode: 'Filesystem',
resources: {
requests: {
storage: cap,
},
},
storageClassName: '',
volumeName: pvname,
},
},
}