39 Commits

Author SHA1 Message Date
Vladimir Kozhukalov
cac1d4c44e Retire openstack-helm-infra repository
Change-Id: Ic43ab19eec26f3e7cf79e7df79d79c5ff0ac7da6
2025-04-15 12:13:22 -05:00
Ritchie, Frank (fr801x)
f28a6ce288 Set sticky bit for tmp
tmp is an emptyDir volume mount with 0777 permissions. Some versions
of Ruby require the sticky bit to be set.

Change-Id: Ib6f4daa2068e7b29c62b5858848774b7117f6808
2022-11-22 15:12:03 -05:00
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
Smith, David (ds3330)
0ecb9bf288 kafka broker hosts should be defined with a comma separated list
The broker attribute should use a comma separated list with the port
definition included

Example: kafka1:9092,kafka2:9092,kafka:9092

The kafka client will connect to the first available host this
will provide resiliency if a host is not available

Change-Id: I5f82e96f2aa274379b6d808291d4b5109709bf72
2021-06-25 14:06:26 +00:00
Lo, Chi (cl566n)
9a719e2a18 Enable TLS between Elasticsearch and Kibana
This change enables TLS between Elasticsearch and Kibana
data path. Note that TLS terminates at apache-proxy container
of the Elasticsearch-client pod, not directly to port 9200 of
elasticsearch-client container.

Since all data traffic goes through apache-proxy container,
fluentd output to Elasticsearch are configured to have TLS
enabled as well.

In additon, other Elasticsearch pods that communicate with
Elasticsearch-client endpoint are modified to provide
the cacert option with curl.

Change-Id: I3373c0c350b30c175be4a34d25a403b9caf74294
2021-04-25 09:07:33 -07:00
Steven Fitzpatrick
29489acf39 Fluentd: Add Configurable Readiness and Liveness Probes
This change updates the fluentd chart to use HTK probe templates
to allow configuration by value overrides

Change-Id: I97a3cc0832554a31146cd2b6d86deb77fd73db41
2020-11-30 18:39:07 +00:00
Steven Fitzpatrick
4e73195bc2 Fluentd: Allow for Multiple Config Files
Change-Id: I2eb6ff2a599ee7bc479f9fc4955016b18902c879
2020-08-04 20:14:09 +00:00
Steven Fitzpatrick
959417f321 Fluentd: Remove Deployment Option
This chart could deploy fluentd either as a Deployment
or a Daemonset. Both options would use the deployment-fluentd
template with various sections toggled off based on values.yaml

I'd like to know - Does anyone run this chart as a Deployment?
We can simplify the chart, and zuul gates, by changing the chart
to deploy a Daemonset specifically.

Change-Id: Ie88ceadbf5113fc60e5bb0ddef09e18fe07a192c
2020-08-04 19:06:37 +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
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
dfb32ccf60 Enable yamllint rules for templates
- braces
- brackets
- colons
- commas
- comments
- comments-indentation
- document-start
- hyphens
- indentation

With corresponding code changes.

Also idempotency fix for lint script.

Change-Id: Ibe5281cbb4ad7970e92f3d1f921abb1efc89dc3b
2020-06-17 13:13:53 -05:00
Steven Fitzpatrick
570024013a Fluentd: Attach uuid to fluentd config etc
By tying the fluent condfiguration to the release, it will be re-rendered
if the release is upgraded. This is useful in combination with [0], allowing
powerful configuration updates using helm upgrade. For example

Values:

    .Values.pod.env.fluentd.vars.OUTPUT_ENABLED: true

fluent.conf:

    ...
    {{- if .Values.pod.env.fluentd.vars.OUTPUT_ENABLED }}
    <match **>
    # Output Configuration here
    </match>
    {{- end }}

To disable this output section, issue a helm upgrade command and set the
apprpriate value to false.

    helm upgrade fluentd ./fluentd --set pod.env.fluentd.vars.OUTPUT_ENABLED=false

[0] https://review.opendev.org/#/c/726880/

Change-Id: I3dce9e5c4eaf588569e8cc3e1ea3cf3bebd0c3c5
2020-05-14 07:19:43 +00:00
Zuul
e53d28718d Merge "Remove OSH Authors copyright" 2020-05-12 20:00:38 +00:00
Steven Fitzpatrick
2039805314 Fluentd: Render Config as Template
This change updates the fluentd configmap-etc to render
.Values.conf.fluentd.template as a template, allowing for greater
flexibility in configuration.

Change-Id: I8809767c679c377e319ecc53960c55ae18e1b558
2020-05-11 10:13:44 -05: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
Steven Fitzpatrick
9d2e08f1a4 Fluentd: Switch to Native Metrics Plugin
This change updates the fluentd chart to use the native
fluent-plugin-prometheus for metric production. This plugin
provides more detailed metrics about fluentd's operations,
specifically regarding input and output statistics.

https://github.com/fluent/fluent-plugin-prometheus

Using the plugin, each fluentd pod produces metrics, so
scape annotations have been added to the pod spec. The
zuul check on metric producers has been updated to account
for this.

Depends-On: https://review.opendev.org/714167
Change-Id: I809356d92b0cff1e31cb2062102bbedefd4843fd
2020-03-30 00:44:58 -05:00
diwakar thyagaraj
c0bec2c744 Enable Apparmor to fluentd
Change-Id: I21640c263cbf7871319d2710160e37a9dddf0eb2
Signed-off-by: diwakar thyagaraj <diwakar.chitoor.thyagaraj@att.com>
2020-03-25 21:50:53 +00:00
Steve Wilkerson
d898a65a2d Revert "Enable Apparmor for fluentd"
This reverts commit a3110abd66727e8fab881a044110d01d2f405019.

Change-Id: I90180d5caa6cd7873220fcc91570c92ae7a234e5
2020-03-24 19:46:19 +00:00
dt241s@att.com
a3110abd66 Enable Apparmor for fluentd
Change-Id: I6b759beff9fd3166a9868a4d71319836f272bc25
2020-03-18 21:26:48 +00:00
Zuul
5695d40dfa Merge "Get osh-infra netpol gate passing" 2020-01-09 14:41:42 +00:00
Tin Lam
c199addf3c Update apiVersion
This patch set updates and tests the apiVersion for rbac.authorization.k8s.io
from v1beta1 to v1 in preparation for its removal in k8s 1.20.

Change-Id: I4e68db1f75ff72eee55ecec93bd59c68c179c627
Signed-off-by: Tin Lam <tin@irrational.io>
2020-01-09 08:59:48 +00:00
Gage Hugo
f9713b0051 Get osh-infra netpol gate passing
This change adds in missing network policy overrides for
fluent-daemonset and prometheus-exporter, as well as removes
existing mariadb network policies overrides that were causing
the network policy check job to fail.

Change-Id: Ib7a33f3d14617f9a9fda264f32cde7729a923193
2020-01-09 04:38:25 +00:00
Steve Wilkerson
005ece16d4 Fluentd: Add support for arbitrary secret env variables
This adds a helm-toolkit util for consuming arbitrary secret env
variables via pod env variables. It also updates the Fluentd chart
to add a release secret that is used to house the secret env
variables defined in the chart's values.yaml. This can be used as
an example to expand to other charts where this functionality is
desired

Change-Id: I9ef606840af92e54b2204e637c58442085e2c748
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-12-09 14:15:40 -06:00
Steven Fitzpatrick
e8f3d84ccc Create Chart to Deploy Apache Kafka
This proposes adding a kafka chart to osh-infra that aligns
with the design patterns laid out by the other charts in osh-infra
and osh.

danielqsj's kafka-exporter image is leveraged to deploy a prometheus
exporter for kafka alongside the main application if enabled in
values.yaml

Change-Id: I5997b0994fc3aef9bd1b222c373cc3a013112566
Co-Authored-By: Meghan Heisler <mh783g@att.com>
2019-12-03 11:37:54 -06:00
Steve Wilkerson
c9acad238c Update Kubernetes version to 1.16.2
This updates the kubeadm and minikube Kubernetes deployments to
deploy version 1.16.2

Change-Id: I324f9665a24c9383c59376fb77cdb853facd0f18
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-10-16 21:54:53 +00:00
Zuul
010fc1fc65 Merge "Fluentd: Add support for arbitrary environment vars" 2019-09-05 18:29:04 +00:00
Steve Wilkerson
6c3cd0a8ce Fluentd: Add support for daemonset update strategy
This adds support for configuring fluentd's update strategy when
deployed as a daemonset, as this was previously missed when
the changes to support both daemonsets and deployments were made

Change-Id: I5ac4fbfc0e64caaf207de42cd71c893f8d0f6ff1
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-09-04 13:28:12 -05:00
Steve Wilkerson
5b14b6c162 Fluentd: Add support for arbitrary environment vars
This updates the Fluentd deployment template to use the helm
toolkit util for generating environment variables through the
chart's values.yaml. This adds flexibility in defining fluentd
outputs, as arbitrary environment variables can be injected and
consumed in fluentd's filters and outputs

Change-Id: I72a2c476378cc555bde1387781b4a06f13b51bc6
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-09-04 10:26:36 -05:00
Steve Wilkerson
4610dc0194 Fluentd: Add support for Kafka outputs
This updates the fluentd chart to add support for leveraging a
Kafka output. This required adding a kafka endpoint entry to the
chart's values.yaml, as well as the required template updates to
the fluentd deployment template and the addition of a secret for
kafka credentials

Depends-On: https://review.opendev.org/#/c/679297/

Change-Id: I80a487a0538f0b3704fb598da38c07feedaccb0e
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-09-03 19:16:53 +00:00
Zuul
fd0952df1a Merge "Fluentd: Fix whitespace chomps for volumes and volume mounts" 2019-06-26 08:42:19 +00:00
Steve Wilkerson
29fc716cf3 Fluentd: Update Clusterrole verbs
This updates the Fluentd clusterrole to allow for getting
namespaces, as this is required for the fluentd kubernetes
plugin to function correctly

Change-Id: Id9d735310c53a922a62c6a82121edd332e7df724
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-06-25 23:31:19 +00:00
Steve Wilkerson
9e33cc2c19 Fluentd: Fix whitespace chomps for volumes and volume mounts
This fixes the whitespace chomps for adding extra volumes and
volume mounts via values.yaml for the Fluentd chart, as currently
too much whitespace is removed and the extra volumes and mounts
are not added correctly

Change-Id: I9cf67c3321339078ac795a7290f441b16cc41d41
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-06-25 23:31:09 +00:00
Zuul
73bc44bc32 Merge "Fluentd: Remove readOnly flag from /var/log mount" 2019-06-25 19:57:58 +00:00
Steve Wilkerson
6321a01c1e Fluentd: Add deployment conditional for probes
This adds a conditional check on the deployment type of the
Fluentd chart to determine whether to enable the current liveness
and readiness probes or not.  The current probes are designed
around using fluentd as an aggregator and do not function properly
when fluentd is deployed as a daemonset.  When run as a daemonset
and configured to tail files via the tail input plugin, fluentd
will prioritize reading the entirety of those files before
processing other input types, including opening the forward source
socket required for the current probes to function correctly. This
results in scenarios where the current probes will fail when in
fact fluentd is functioning correctly.

Daemonset focused probes to come as a follow on once a proper path
forward has been determined

Change-Id: I8a164bd47ce1950e0bd6c5043713f4cde9f85d79
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-06-25 06:32:25 -05:00
Steve Wilkerson
1df9cee5c1 Fluentd: Remove readOnly flag from /var/log mount
This removes the readOnly flag from the /var/log mount for the
fluentd pod to allow for using the file buffer mechanism when
desired

Change-Id: I23f0f03824eec5b142d3f2e8e42e8d07cddfe618
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-06-24 11:11:52 -05:00
Steve Wilkerson
aee9708b06 Fluentd: Update configuration defaults and overrides
This updates the default fluentd configuration to include
recommended settings for preventing the elasticsearch plugin from
reloading the connection after 10000 requests (default for the
ruby gem). This also updates the configuration overrides for the
fluentd-daemonset deployment to provide input parity with the
default fluentbit configuration by adding inputs for the docker
and kubelet systemd units, inputs for ceph, libvirt, kernel logs,
and auth logs on the host.  Finally, this updates the fluentd
template to include environment variables for the host name and
the fluentd pod name so they can be added to logged events through
fluentd filter plugins

Change-Id: I21f7a89a325c44f8b058ff01a20191bea1a210b4
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-06-03 16:00:44 +00:00
Steve Wilkerson
277b54fc65 Fluentd: Use fqdn hostname for Elasticsearch service
This moves Fluentd to use the helm-toolkit endpoint lookup for
using the fqdn for the Elasticsearch hostname instead of the
standard short host name

Change-Id: Ibe640979002331693f0a9b6155c9014572294664
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-05-31 14:42:09 -05:00
Steve Wilkerson
bdaf866a4e Fluentd: Support Daemonset deployment
This adds required changes to the Fluentd chart to allow for
deploying Fluentd as either a deployment or a daemonset. This
follows the pattern laid out by the ingress chart. This also
updates the single and multinode jobs to deploy fluentd as both
a daemonset and a deployment for validation

Change-Id: I84353a2daa2ce56ff59882a8d33203286ed27e06
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-05-28 08:23:44 -05:00
Steve Wilkerson
abb5e0f713 Separate fluentbit and fluentd charts
This begins to split the fluent-logging chart into two separate
charts, one for fluentbit and one for fluentd. This is to help
isolate each chart and its dependencies better, and to treat each
service as its own entity.

This also moves the job for creating Elasticsearch templates to
the Elasticsearch chart, as the elasticsearch chart should have
ownership of creating the templates for its indices.

This also performs some general cleanup of values keys that are
not currently used

Change-Id: I827277d5faa62b8b59c5960330703d23c297ca47
Signed-off-by: Steve Wilkerson <sw5822@att.com>
2019-05-24 06:31:09 -05:00