19 Commits

Author SHA1 Message Date
Phil Sphicas
428cda6e33 [ceph-client] Consolidate mon_host discovery
This change updates the ceph.conf update job as follows:
* renames it to "ceph-ns-client-ceph-config"
* consolidates some Roles and RoleBindings

This change also moves the logic of figuring out the mon_host addresses
from the kubernetes endpoint object to a snippet, which is used by the
various bash scripts that need it.

In particular, this logic is added to the rbd-pool job, so that it does
not depend on the ceph-ns-client-ceph-config job.

Note that the ceph.conf update job has a race with several other jobs
and pods that mount ceph.conf from the ceph-client-etc configmap while
it is being modified. Depending on the restartPolicy, pods (such as the
one created for the ceph-rbd-pool job) may linger in StartError state.
This is not addressed here.

Change-Id: Id4fdbfa9cdfb448eb7bc6b71ac4c67010f34fc2c
2021-10-28 19:47:59 -07:00
Sean Eagan
b1a247e7f5 Helm 3 - Fix Job labels
If labels are not specified on a Job, kubernetes defaults them
to include the labels of their underlying Pod template. Helm 3
injects metadata into all resources [0] including a
`app.kubernetes.io/managed-by: Helm` label. Thus when kubernetes
sees a Job's labels they are no longer empty and thus do not get
defaulted to the underlying Pod template's labels. This is a
problem since Job labels are depended on by
- Armada pre-upgrade delete hooks
- Armada wait logic configurations
- kubernetes-entrypoint dependencies

Thus for each Job template this adds labels matching the
underlying Pod template to retain the same labels that were
present with Helm 2.

[0]: https://github.com/helm/helm/pull/7649

Change-Id: I3b6b25fcc6a1af4d56f3e2b335615074e2f04b6d
2021-09-30 16:01:31 -05:00
Parsons, Cliff (cp769u)
f20eff164f Allow Ceph RBD pool job to leave failed pods
This patchset will add the capability to configure the
Ceph RBD pool job to leave failed pods behind for debugging
purposes, if it is desired. Default is to not leave them
behind, which is the current behavior.

Change-Id: Ife63b73f89996d59b75ec617129818068b060d1c
2021-03-29 19:38:55 +00:00
Brian Wickersham
714cfdad84 Revert "[ceph-client] enhance logic to enable the autoscaler for Octopus"
This reverts commit 910ed906d0df247f826ad527211bc86382e16eaa.

Reason for revert: May be causing upstream multinode gates to fail. 

Change-Id: I1ea7349f5821b549d7c9ea88ef0089821eff3ddf
2021-02-25 17:04:37 +00:00
bw6938
910ed906d0 [ceph-client] enhance logic to enable the autoscaler for Octopus
Change-Id: I90d4d279a96cd298eba03e9c0b05a8f2a752e746
2021-02-19 21:03:45 +00:00
Andrii Ostapenko
824f168efc Undo octal-values restriction together with corresponding code
Unrestrict octal values rule since benefits of file modes readability
exceed possible issues with yaml 1.2 adoption in future k8s versions.
These issues will be addressed when/if they occur.

Also ensure osh-infra is a required project for lint job, that matters
when running job against another project.

Change-Id: Ic5e327cf40c4b09c90738baff56419a6cef132da
Signed-off-by: Andrii Ostapenko <andrii.ostapenko@att.com>
2020-07-07 15:42:53 +00:00
Zuul
0a35fd827e Merge "Enable key-duplicates and octal-values yamllint checks" 2020-06-18 04:49:03 +00:00
Stephen Taylor
59b825ae48 [ceph-osd, ceph-client] Weight OSDs as they are added
Currently OSDs are added by the ceph-osd chart with zero weight
and they get reweighted to proper weights in the ceph-client chart
after all OSDs have been deployed. This causes a problem when a
deployment is partially completed and additional OSDs are added
later. In this case the ceph-client chart has already run and the
new OSDs don't ever get weighted correctly. This change weights
OSDs properly as they are deployed instead. As noted in the
script, the noin flag may be set during the deployment to prevent
rebalancing as OSDs are added if necessary.

Added the ability to set and unset Ceph cluster flags in the
ceph-client chart.

Change-Id: Ic9a3d8d5625af49b093976a855dd66e5705d2c29
2020-06-17 21:49:39 +00:00
Andrii Ostapenko
83e27e600c Enable key-duplicates and octal-values yamllint checks
With corresponding code changes.

Change-Id: I11cde8971b3effbb6eb2b69a7d31ecf12140434e
2020-06-17 13:14:30 -05:00
Tin Lam
d95259936f Revert "[ceph-osd, ceph-client] Weight OSDs as they are added"
This patch currently breaks cinder helm test in the OSH cinder jobs
blocking the gate. Proposing to revert to unblock the jobs.

This reverts commit f59cb11932e30bb607a580c976871cdecd7a714c.

Change-Id: I73012ec6f4c3d751131f1c26eea9266f7abc1809
2020-05-25 21:09:15 +00:00
Steve Taylor
f59cb11932 [ceph-osd, ceph-client] Weight OSDs as they are added
Currently OSDs are added by the ceph-osd chart with zero weight
and they get reweighted to proper weights in the ceph-client chart
after all OSDs have been deployed. This causes a problem when a
deployment is partially completed and additional OSDs are added
later. In this case the ceph-client chart has already run and the
new OSDs don't ever get weighted correctly. This change weights
OSDs properly as they are deployed instead. As noted in the
script, the noin flag may be set during the deployment to prevent
rebalancing as OSDs are added if necessary.

Added the ability to set and unset Ceph cluster flags in the
ceph-client chart.

Change-Id: Iac50352c857d874f3956776c733d09e0034a0285
2020-05-22 09:21:44 -06:00
Gage Hugo
d14d826b26 Remove OSH Authors copyright
The current copyright refers to a non-existent group
"openstack helm authors" with often out-of-date references that
are confusing when adding a new file to the repo.

This change removes all references to this copyright by the
non-existent group and any blank lines underneath.

Change-Id: I1882738cf9757c5350a8533876fd37b5920b5235
2020-05-07 02:11:15 +00:00
Chinasubbareddy Mallavarapu
872f68ada7 [ceph-pools] Enable autoscaler by reading from values
This is to make enabling autosclaer feature optional from values since
its new feature and few deployments may not required it.

Change-Id: Ie7cbdb71f6a1bf636db2d61ae0f3a4c19af2ca34
2020-03-28 20:26:33 -05:00
diwakar thyagaraj
344c0543fa Enable runtime Apparmor default for All Ceph Components
Change-Id: Id62fe453846ffe6ab01198177d5d8046378d61bf
Signed-off-by: diwakar thyagaraj <diwakar.chitoor.thyagaraj@att.com>
2020-02-24 15:52:11 +00:00
Chinasubbareddy Mallavarapu
e7fac18ddc [ceph-client] Fix resource limit logic with rbd_pool job
This is to fix applying resource limit logic with rbd_pool job as this
job right now taking the values from ceph-mgr pod.

Change-Id: I663ba220df1569c0bd1faca1417936b804d1dc94
2020-02-21 11:19:53 -06:00
Pete Birley
f569cf0d5c Ceph-Client: Add security context to chart and read-only-fs
This PS adds the security context macros to the ceph-client chart,
and moves the default to read-only-rootfs for all containers.

Change-Id: I2fe03f31cc59e1cda2bf0396ae6e3aca5c440a16
Signed-off-by: Pete Birley <pete@port.direct>
2019-04-21 19:06:24 +00:00
Pete Birley
2abf62ff4d OSH-Infra: Add emptydirs for tmp
This PS adds emptydirs backing the /tmp directory in pods, which
is required in most cases for full operation when using a read only
filesystem backing the container.

Additionally some yaml indent issues are resolved.

Change-Id: I8b7f1614da059783254aa6efc09facf23fca3cad
Signed-off-by: Pete Birley <pete@port.direct>
2019-04-20 20:50:59 +00:00
Pete Birley
bb3ff98d53 Add release uuid to pods and rc objects
This PS adds the ability to attach a release uuid to pods and rc
objects as desired. A follow up ps will add the ability to add arbitary
annotations to the same objects.

Change-Id: Iceedba457a03387f6fc44eb763a00fd57f9d84a5
Signed-off-by: Pete Birley <pete@port.direct>
2018-09-13 05:35:35 +00:00
Steve Wilkerson
25bc83b580 Ceph: Move Ceph charts to openstack-helm-infra
This continues the work of moving infrastructure related services
out of openstack-helm, by moving the ceph charts to openstack
helm infra instead.

Change-Id: I306ccd9d494f72a7946a7850f96d5c22f36eb8a0
2018-08-28 15:03:35 -05:00