-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathcharmcraft.yaml
318 lines (268 loc) · 9.96 KB
/
charmcraft.yaml
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
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
# Copyright 2025 Canonical Ltd.
# See LICENSE file for licensing details.
# This file configures Charmcraft.
# See https://juju.is/docs/sdk/charmcraft-config for guidance.
name: ceph-csi
title: Ceph CSI
summary: Subordinate charm for deploying Container Storage Interface (CSI) plugin for Ceph
description: |
This (machine) charm deploys Container Storage Interface (CSI) plugin that
enables Charmed Kubernetes (CK) to use ceph as a storage backend.
links:
contact: https://launchpad.net/~containers
issues:
- https://bugs.launchpad.net/charm-ceph-csi/+bugs
source:
- https://github.com/charmed-kubernetes/ceph-csi-operator
type: charm
subordinate: true
parts:
charm:
plugin: charm
build-packages: [git]
charm-python-packages:
- setuptools # for jinja2
prime:
- upstream/**
bases:
- build-on:
- name: "ubuntu"
channel: "20.04"
architectures: ["amd64"]
run-on:
- name: "ubuntu"
channel: "20.04"
architectures:
- amd64
- s390x
- arm64
- name: "ubuntu"
channel: "22.04"
architectures:
- amd64
- s390x
- arm64
- name: "ubuntu"
channel: "24.04"
architectures:
- amd64
- s390x
- arm64
config:
options:
default-storage:
default: ceph-xfs
description: "Default storage class to use. Allowed values: 'ceph-ext4', 'ceph-xfs', 'cephfs'"
type: string
provisioner-replicas:
default: 3
description: "Number of replicas of any csi-*plugin-provisioner deployment"
type: int
enable-host-networking:
default: false
description: "Whether or not csi-*plugin-provisioner deployments use host-networking"
type: boolean
cephfs-storage-class-name-formatter:
default: "cephfs"
description: |
Formatter for the cephfs storage class name
The formatter is a string that can contain the following placeholders:
- {app} - the name of the juju application
- {namespace} - the charm configured namespace
- {name} - the name of the filesystem
- {pool} - the name of the data-pool
- {pool-id} - the id of the data-pool
Example:
juju config ceph-csi cephfs-storage-class-name-formatter="{cluster}-{namespace}-{storageclass}"
The default is to use the storage class name
type: string
cephfs-enable:
default: false
description: |
Whether or not cephfs manifests should be installed
Only enable if ceph-fs is deployed and related to ceph-mon
type: boolean
cephfs-mounter:
default: ""
description: |
The driver can use either ceph-fuse (fuse) or ceph kernelclient (kernel).
If omitted, default volume mounter will be used - this is
determined by probing for ceph-fuse and mount.ceph
type: string
cephfs-storage-class-parameters:
default: ""
description: |
Parameters to be used when creating the cephfs storage classes.
Changes are only applied to the storage classes if they do not exist.
Declare additional/replacement parameters in key=value format, separated by spaces.
Declare removed parameters in the key- format, separated by spaces.
Optional parameters can be found in the ceph-csi documentation:
https://github.com/ceph/ceph-csi/blob/devel/examples/rbd/storageclass.yaml
type: string
cephfs-tolerations:
default: "$csi-cephfsplugin-legacy$"
description: |
Tolerations to be used when creating the cephfs pods for Daemonsets and Deployments.
Declare tolerations in key=value,operator,effect format, separating each by spaces.
Optional tolerations can be found in the kubernetes documentation:
https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/
Note: The default value "$csi-cephfsplugin-legacy$" is a special token
which applies a "=,Exists" toleration only to pods associated with
csi-cephfsplugin.
type: string
ceph-rbd-tolerations:
default: ""
description: |
Tolerations to be used when creating the rbd pods for Daemonsets and Deployments.
Declare tolerations in key=value,operator,effect format, separating each by spaces.
Optional tolerations can be found in the kubernetes documentation:
https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/
type: string
ceph-xfs-storage-class-parameters:
default: "imageFeatures=layering"
description: |
Parameters to be used when creating the ceph-xfs storage class.
Changes are only applied to the storage class if it does not exist.
Declare additional/replacement parameters in key=value format, separated by spaces.
Declare removed parameters in the key- format, separated by spaces.
Optional parameters can be found in the ceph-csi documentation:
https://github.com/ceph/ceph-csi/blob/devel/examples/rbd/storageclass.yaml
type: string
ceph-ext4-storage-class-parameters:
default: "imageFeatures=layering"
description: |
Parameters to be used when creating the the ceph-ext4 storage class.
Changes are only applied to the storage class if it does not exist.
Declare additional/replacement parameters in key=value format, separated by spaces.
Declare removed parameters in the key- format, separated by spaces.
Optional parameters can be found in the ceph-csi documentation:
https://github.com/ceph/ceph-csi/blob/devel/examples/rbd/storageclass.yaml
type: string
image-registry:
type: string
default: "rocks.canonical.com/cdk"
description: |
Image registry for all Ceph CSI container images.
This value replaces the image registry in image URLs from the release
manifests. For example, an image URL like
`quay.io/cephcsi/cephcsi:v3.8.0` becomes
`rocks.canonical.com/cdk/cephcsi/cephcsi:v3.8.0` if set to
`rocks.canonical.com/cdk`.
Example:
juju config ceph-csi image-registry="rocks.canonical.com/cdk"
metrics-port-cephfsplugin:
default: -1
description: |
Port for csi-cephfsplugin liveness-prometheus metrics
If set to -1, the metrics service will not be created
type: int
metrics-port-cephfsplugin-provisioner:
default: -1
description: |
Port for csi-cephfsplugin-provisioner liveness-prometheus metrics
If set to -1, the metrics service will not be created
type: int
metrics-port-rbdplugin:
default: -1
description: |
Port for csi-rbdplugin liveness-prometheus metrics
If set to -1, the metrics service will not be created
type: int
metrics-port-rbdplugin-provisioner:
default: -1
description: |
Port for csi-rbdplugin-provisioner liveness-prometheus metrics
If set to -1, the metrics service will not be created
type: int
namespace:
type: string
default: ""
description: |
Kubernetes namespace in which to install the rbd and cephfs
components including deployments, daemonsets, secrets, configmaps.
if unspecified, "default" is assumed
NOTE: Can only be specified on deployment since some
attributes of kubernetes resources are non-modifiable.
The admin is responsible for creating the namespace.
release:
type: string
default: "v3.9.0"
description: |
Specify the version of ceph-csi as defined by the `release`
tags of https://github.com/ceph/ceph-csi
example)
juju config ceph-csi release='v3.7.2'
A list of supported versions is available through the action:
juju run ceph-csi/leader list-versions
To reset by to the latest supported by the charm use:
juju config ceph-csi --reset release
The current release deployed is available by viewing
juju status ceph-csi
actions:
list-versions:
description: List versions supported by this charm
list-resources:
description: List Resources of configured version
params:
manifest:
type: string
default: ""
description: |
Filter list based on "cephfs, rbc, or config" manifests.
resources:
type: string
default: ""
description: |
Space separated list of kubernetes resource types to filter list result
scrub-resources:
description: Remove deployments other than the current one
params:
manifest:
type: string
default: ""
description: |
Filter list based on "cephfs, rbc, or config" manifests.
resources:
type: string
default: ""
description: |
Space separated list of kubernetes resource types to filter scrubbing
sync-resources:
description: |
Add kubernetes resources which should be created by this charm which aren't
present within the cluster.
params:
manifest:
type: string
default: ""
description: |
Filter list based on "cephfs, rbc, or config" manifests.
resources:
type: string
default: ""
description: |
Space separated list of kubernetes resource types
to use a filter during the sync. This helps limit
which missing resources are applied.
delete-storage-class:
description: |
Delete storage class which may be in conflict with the underlying cluster.
params:
name:
type: string
description: Name of a specific storage class to delete.
enum:
- cephfs
- ceph-xfs
- cephfs-ext4
required:
- name
requires:
ceph-client:
interface: ceph-client
kubernetes:
interface: juju-info
scope: container
kubernetes-info:
interface: kubernetes-info
scope: container