Commit Graph

70 Commits

Author SHA1 Message Date
Brian Haley f31cfb2ef9 support image registries with authentication
Based on spec in openstack-helm repo,
support-OCI-image-registry-with-authentication-turned-on.rst

Each Helm chart can configure an OCI image registry and
credentials to use. A Kubernetes secret is then created with these
info. Service Accounts then specify an imagePullSecret specifying
the Secret with creds for the registry. Then any pod using one
of these ServiceAccounts may pull images from an authenticated
container registry.

Change-Id: Iebda4c7a861aa13db921328776b20c14ba346269
2022-07-20 14:28:47 -05:00
Gage Hugo 22e50a5569 Update htk requirements
This change updates the helm-toolkit path in each chart as part
of the move to helm v3. This is due to a lack of helm serve.

Change-Id: I011e282616bf0b5a5c72c1db185c70d8c721695e
2021-10-06 01:02:28 +00: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
Thiago Brito 5a0ba49d50 Prepending library/ to docker official images
This will ease mirroring capabilities for the docker official images.

Signed-off-by: Thiago Brito <thiago.brito@windriver.com>
Change-Id: I0f9177b0b83e4fad599ae0c3f3820202bf1d450d
2021-06-02 15:04:38 -03:00
astebenkova a589db04e9 Add possibility to use overrides for some charts
The deal is that all the jobs' scripts include extra arguments
when deploying helm charts, except these ones in the commit.
It would be useful to use override files in these charts.

+ Fix typo in apparmor.yaml for node-exporter
+ Amend apparmor.yaml for openstack-exporter since
those values are already by default in values.yaml

Change-Id: Ibe8b38977216e618dccba7e8443b3cc05a772de5
2021-01-27 18:45:19 +02:00
Andrii Ostapenko 0deef8370a Unpin prometheus-openstack-exporter image
This enables ability to continuously update and test an image with
osh-infra gate and periodic pipeline.

Change-Id: I34ad5f8033038216129955b049d3ed09dfc0c140
Signed-off-by: Andrii Ostapenko <andrii.ostapenko@att.com>
2020-09-30 04:20:37 +00:00
Andrii Ostapenko 1532958c80
Change helm-toolkit dependency version to ">= 0.1.0"
Since we introduced chart version check in gates, requirements are not
satisfied with strict check of 0.1.0

Change-Id: I15950b735b4f8566bc0018fe4f4ea9ba729235fc
Signed-off-by: Andrii Ostapenko <andrii.ostapenko@att.com>
2020-09-24 12:19:28 -05:00
Mohammed Naser c7a45f166f Run chart-testing on all charts
Added chart lint in zuul CI to enhance the stability for charts.
Fixed some lint errors in the current charts.

Change-Id: I9df4024c7ccf8b3510e665fc07ba0f38871fcbdb
2020-09-11 18:02:38 +03:00
Gupta, Sangeet (sg774j) 4d512f6eff feat(tls): add tls to prometheus-openstack-exporter
This patchset enables passing of tls certificate to
openstack.

Change-Id: I370d69d8747ce894684dbff87b3580b6d1e82647
2020-08-03 22:20:34 +00:00
Zuul 1a70211147 Merge "Add Apparmor for prometheus os exporter ks-user Job" 2020-07-08 14:18:26 +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
diwakar thyagaraj cc020bdfca Add Apparmor for prometheus os exporter ks-user Job
1) Updated docker image for heat to point to Stein and Bionic
 2) Enabled Apparmor Job for prometheus-openstack exporter.

Change-Id: I1ee8acb848ece3c334b087309d452d5137ea0798
Signed-off-by: diwakar thyagaraj <diwakar.chitoor.thyagaraj@att.com>
2020-07-07 00:23:18 +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
Andrii Ostapenko 8f24a74bc7 Introduces templates linting
This commit rewrites lint job to make template linting available.
Currently yamllint is run in warning mode against all templates
rendered with default values. Duplicates detected and issues will be
addressed in subsequent commits.

Also all y*ml files are added for linting and corresponding code changes
are made. For non-templates warning rules are disabled to improve
readability. Chart and requirements yamls are also modified in the name
of consistency.

Change-Id: Ife6727c5721a00c65902340d95b7edb0a9c77365
2020-06-11 23:29:42 -05:00
Andrii Ostapenko 731a6b4cfa Enable yamllint checks
- document-end
- document-start
- empty-lines
- hyphens
- indentation
- key-duplicates
- new-line-at-end-of-file
- new-lines
- octal-values

with corresponding code adjustment.

Change-Id: I92d6aa20df82aa0fe198f8ccd535cfcaf613f43a
2020-05-29 19:49:05 +00: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
diwakar thyagaraj ebfcec03e2 Enable Docker default Apparmor for all Prometheus init Containers
Change-Id: I036882f7e443d3494e3fb38b2d5ded4bfa11a9b1
Signed-off-by: diwakar thyagaraj <diwakar.chitoor.thyagaraj@att.com>
2020-05-06 17:18:16 +00:00
Steven Fitzpatrick 05d4b34715 Add Liveness Probe to Openstack Exporter Deployment
Kill the openstack exporter pod if it is not ready after 3 mintues

Change-Id: Id20d01052aecce19b845c610424c5375dc14cd43
2020-02-26 16:13:09 +00:00
diwakar thyagaraj 17592f54ae Enable Docker default Apparmor for all Prometheus Containers
Change-Id: I97fc39e52b36fc0be84abd049fdbce1e7026107d
Signed-off-by: diwakar thyagaraj <diwakar.chitoor.thyagaraj@att.com>
2020-02-18 14:46:09 +00:00
Steve Wilkerson cbeb7f149b Move charts off using the :latest built tags
This updates charts that consume images built from osh-images to
use tags other than the :latest tags. This will be followed up
with the definition of jobs to allow for vetting out of updated
images, as reliance on :latest tags assumes any change merged into
osh-images will result in functionally correct behavior (which has
shown to not be the case traditionally)

Change-Id: I181aa56ed187604dc7583d8081e53cc69eb27310
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-11-21 19:57:07 +00:00
Steven Fitzpatrick 1971d23da8 Make corrections to pod lifecycle upgrade values
It was observed in some charts' values.yaml that the values defining
lifecycle upgrade parameters were incorrectly placed.

This change aims to correct these instances by adding a deployment-
type subkey corresponding with the deployment types identified in
the chart's templates dir, and indenting the values appropriately.

Change-Id: Id5437b1eeaf6e71472520f1fee91028c9b6bfdd3
2019-10-31 20:34:07 +00:00
Steven Fitzpatrick 0a5a6caee6 Update openstack-exporter chart to use new image
This change updates the prometheus-openstack-exporter
chart to pull an updated image which runs on python 3.

Co-Authored By: Bharat Khare <bk552w@att.com>
Depends On: https://review.opendev.org/686252
Change-Id: I4db500ba395b1d8417491bcde82be95a039eeb4f
2019-10-21 09:22:24 -05:00
Steve Wilkerson b50fae62a4 Update kubernetes-entrypoint image reference
This updates the kubernetes-entrypoint image reference to consume
the publicly available kubernetes-entrypoint image that is built
and maintained under the airshipit namespace, as the stackanetes
image is no longer actively maintained

Change-Id: I5bfdc156ae228ab16da57569ac6b05a9a125cb6a
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-10-18 18:20:11 +00:00
Gage Hugo a6ffe2f161 Define default netpol for openstack-exporter
This change adds default network policy definitions for ingress/egress
in the prometheus-openstack-exporter chart to allow all traffic.

This also adds a netpol value override to enable network policy for
various network policy checks.

Change-Id: If1314420d5038174e8641c9809de65b23853d3f3
2019-09-26 11:33:39 -05:00
Steve Wilkerson b4b1dd9528 Add missing affinity keys to chart pod specs
This adds the affinity key to the pod spec for the grafana,
nagios, kube-state-metrics, and openstack-exporter charts as it
was previously missed

Change-Id: Ifefa88d7f33607b4d595effa5fbf72f3387e5081
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-06-13 19:15:42 +00:00
caoyuan 040edeb79a Replace git.openstack.org URLs with opendev.org URLs
Change-Id: I0e3af4a3385f5b2a7705bc19b775863b16c2e08e
2019-05-31 01:52:10 +00:00
Jean-Philippe Evrard 5f5e988fb3 Point to OSH-images images
We now have a process for OSH-images image building,
using Zuul, so we should point the images by default to those
images, instead of pointing to stale images.

Without this, the osh-images build process is completely not
in use (and completely opaque to deployers), and updating the
osh-images process or patching its code has no impact on OSH.

This should fix it.

Change-Id: Ic00bd98c151669dc2485cd88e0e8c2ab05445959
2019-05-17 08:17:32 +00:00
RAHUL KHIYANI 2cdcaa84b5 prometheus-openstack-exporter: Fix security context
This PS fixes the use of the security context macros for the
openstack-exporter chart.

Change-Id: I91e9f6810442477c167a07e2d8ffa4f01beb66d3
2019-04-22 18:35:32 +00:00
Zuul 6b03d346a2 Merge "This commit adds docker-default apparmor profile for prometheus-openstack-exporter." 2019-04-21 04:58:26 +00:00
Randeep Jalli 8ed0c1dd2b This commit adds docker-default apparmor profile for prometheus-openstack-exporter.
Change-Id: I1461246505f42c41051cebd981217c0064d39928
2019-04-21 03:17:18 +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
Zuul f0cbc80d7e Merge "prometheus-openstack-exporter: Add container security context" 2019-03-22 02:22:27 +00:00
Steve Wilkerson 84f30ec103 Add release-annotation to pod spec, add missing annotations
This adds the release-annotation to the pod spec for the charts in
openstack-helm-infra. This also adds missing configmap annotations
to charts in openstack-helm-infra

Change-Id: Ie23f0c16a7a21d3929e98928db2bbcef69ae6490
2019-03-21 09:10:48 -05:00
Rahul Khiyani 518794cabe prometheus-openstack-exporter: Add container security context
This adds the container security context to set
readOnlyRootFilesystem to true and allowPrivilegeEscalation to false

Change-Id: I7b2f78b51b6ff219c371893f975a30fd89f1719b
2019-03-20 04:16:01 +00:00
Zuul c4f6453511 Merge "Add default AppArmor profile to prometheus-openstack-exporter" 2019-03-15 17:53:30 +00:00
Zuul d6996b8004 Merge "Add ingress network policy to kube-state-metrics and openstack-exporter" 2019-03-10 21:13:55 +00:00
dt241s f97f56fae5 Add default AppArmor profile to prometheus-openstack-exporter
Change-Id: I94e95e1f7d785a1d274e1ee3d9f90ffb00e23ea1
2019-03-08 14:51:41 -06:00
Meg Heisler 2d36d5f7ce Add ingress network policy to kube-state-metrics and openstack-exporter
This adds ingress network policies to kube-state-metrics and
openstack-exporter using the helm-toolikit template. It also
add openstack-exporter to the network policy jobs.

Change-Id: I3bfc2f1e8a35c09e577a046ebd52346de95e5745
2019-03-07 14:12:14 -06:00
Rahul Khiyani 5b513d333f readOnlyRootFilesystem: true for Prometheus exporters charts
Fix for adding readOnlyRootFilesystem flag at pod
level

Change-Id: I3d81f9dca7e1bce0134a39a96b96ef7712d28d84
2019-03-07 17:10:39 +00:00
Steve Wilkerson 236d686a6d Openstack exporter: Add security context for pod/container
This adds a security context to the openstack exporter, which
changes the pod's user from root to the nobody user instead

This also adds the container security context to explicitly set
allowPrivilegeEscalation to false

Change-Id: Ie3f105ee8b489f7641b5b7256a2023ae35257343
2019-01-03 16:16:43 -06:00
Steve Wilkerson c7cbb9f4dd Charts: Update heat image used for jobs and helm tests
This changes the image used for various jobs and helm tests in the
osh-infra charts. This replaces the kolla heat image with the loci
based heat image used for jobs and helm tests in openstack-helm in
order to drive consistency

Change-Id: Ie9deedadb7507282fe62723ec4641dd508040364
2018-10-11 14:47:58 -05: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
Jean-Philippe Evrard bf069b2311 Revert "Update OSH Author copyrights to OSF"
This reverts commit 178aa271a4.

Change-Id: I38a52d866527dfff2689b618e055f439bc248c13
2018-08-28 17:25:54 +00:00
Matt McEuen 178aa271a4 Update OSH Author copyrights to OSF
This PS updates the "Openstack-Helm Authors" copyright attribution
to be the "OpenStack Foundation", as decided in the 2018-03-20
team meeting:
http://eavesdrop.openstack.org/meetings/openstack_helm/2018/openstack_helm.2018-03-20-15.00.log.html

No other copyright attributions were changed.

Change-Id: I1137dee2ae5728771835f4b33fcaff60fcc22ca9
2018-08-26 17:17:06 -05:00
Pete Birley 89be3269d6 Keystone: Update endpoints to point to current defaults
This PS updates the keysteone endpoints section used in the
webhook authenticator and the prometheus exporter.

Depends-On: https://review.openstack.org/#/c/588651
Change-Id: Ia2df0ec1b783705f7e2ac164a8729d61962e2bc8
Signed-off-by: Pete Birley <pete@port.direct>
2018-08-04 08:08:51 -05:00
Zuul a65dd0269c Merge "Revert "Openstack Exporter: Use service domain for service user"" 2018-08-03 01:08:05 +00:00
Seungkyu Ahn a430533e6a Quoting node_select_value in Ingress Controller
In most cases, the ingress controller's nodeSelector key and value
are "node-role.kubernetes.io/ingress" and "true".
Using quote to treat the nodeSelector value as a string.

Change-Id: Ie1745629b90795e4d888d85f35565e6d6350e09b
2018-08-01 02:39:05 +00:00
Steve Wilkerson 838b6599de Revert "Openstack Exporter: Use service domain for service user"
This reverts commit cc9944f74a.

Change-Id: Ie21beb43d3ac3d5eb6ae6a06d2b665e017ae470a
2018-07-31 21:29:45 +00:00
Zuul 9c7169e40e Merge "Resources: Fix erroneous resource definitions" 2018-07-30 18:29:10 +00:00
Steve Wilkerson 397eebf995 Resources: Fix erroneous resource definitions
This fixes the resource trees for the fluent-logging and
openstack-exporter charts to match the other charts. This
also fixes the elasticsearch master template to use the
correct indentation level for the resource template

Change-Id: Ic6ec270a880216daff10d1f22128c6377ebf9933
2018-07-27 16:35:37 -05:00