Commit Graph

101 Commits

Author SHA1 Message Date
Sergiy Markin eae5c6d69a Uplift nginx ingress controller to v1.8.2
Change-Id: I4223f3f859833447f4045e7acea81bf4c7a8948a
2023-10-04 20:00:33 +00:00
Sergiy Markin db3537e56b [ingress-controller] Redesigned controller parameters
This PS consolidates control over ingress class name and controller
class names at one place.

Change-Id: I394ec99e0e6177c8c8553b636e3fda90c967c15b
2023-10-02 18:10:54 +00:00
Sergiy Markin 56dd4fdb84 [ingress-controller] Fixed controller parameters
This PS fixes some ingress controller parameters.

Change-Id: Ifb96703a8322bbe75834f4b117a4230e236ee6d0
2023-09-28 03:26:45 +00:00
Anselme, Schubert 51c70e48df
Deprecating the Ingress Class Annotation
This PS replaces deprecated kubernetes.io/ingress.class annotation  with
spec.ingressClassName field that is a reference to an IngressClass
resource that contains additional Ingress configuration, including the
name of the Ingress controller.

https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/#deprecating-the-ingress-class-annotation

Change-Id: I9953d966b4f9f7b1692b39f36f434f5055317025
Co-authored-by: Sergiy Markin <smarkin@mirantis.com>
Co-authored-by: Leointii Istomin <listomin@mirantis.com>
Signed-off-by: Anselme, Schubert (sa246v) <sa246v@att.com>
2023-08-26 00:39:34 +00:00
Vladimir Kozhukalov 97ce6d7d8e Update kubernetes registry to registry.k8s.io
See this link for details
https://kubernetes.io/blog/2023/03/10/image-registry-redirect/

Change-Id: Ifc8b64825751933def16a1784fae987a1d7250ad
2023-04-11 04:54:26 +03:00
Samuel Liu 6034a00bf7 Replace node-role.kubernetes.io/master with control-plane
The master label is no longer present on kubeadm control plane nodes(v1.24). For new clusters, the label 'node-role.kubernetes.io/master' will no longer be added to control plane nodes, only the label 'node-role.kubernetes.io/control-plane' will be added. For more information, refer to KEP-2067[https://github.com/kubernetes/enhancements/tree/master/keps/sig-cluster-lifecycle/kubeadm/2067-rename-master-label-taint]: Rename the kubeadm "master" label and taint.

the kubernetes pr: https://github.com/kubernetes/kubernetes/pull/107533

Change-Id: I3056b642db0a1799089998e3c020b4203c9a93ab
2023-03-20 13:38:07 +08:00
Cedric Hnyda c73f69422b [ingress] Allow setting node_port for the svc
Signed-off-by: Cedric Hnyda <ced.hnyda@gmail.com>
Change-Id: I55feb2f8ed01a81331cfcfc97ca6cc76653d9fd4
2023-01-03 17:42:07 +01:00
Anselme, Schubert (sa246v) d30bbfbfe7
Uplift nginx ingress controller to v1.5.1
Signed-off-by: Anselme, Schubert (sa246v) <sa246v@att.com>
Change-Id: I8e3eb2ebd52c0dae1d0cc0ebaa23885b8c0cf83f
2022-12-14 15:19:51 -05:00
josedev-union 4a224320d8 Fix resource name in role of ingress chart
Change-Id: I05a959b4678852699b7b5531cd8303e15662b372
2022-10-30 20:00:52 +02:00
Gage Hugo 0e913fa97a Update neutron images to xena
A couple of the ingress images are still pointing to the older
stein release of neutron. This change updates them to use the
updated xena release.

Change-Id: I95aecec5474e587d01d7e8812ec662fbf46ca634
2022-10-04 12:07:54 -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
Schubert Anselme 753a32c33d
Migrate CronJob resources to batch/v1 and PodDisruptionBudget resources to policy/v1
This change updates the following charts to migrate CronJob resources to the batch/v1 API version, available since v1.21. [0]
and to migrate PodDisruptionBudget to the policy/v1 API version, also available since v1.21. [1]

This also uplift ingress controller to 1.1.3

- ceph-client (CronJob)
- cert-rotation (CronJob)
- elasticsearch (CronJob)
- mariadb (CronJob & PodDisruptionBudget)
- postgresql (CronJob)

0: https://kubernetes.io/docs/reference/using-api/deprecation-guide/#cronjob-v125
1: https://kubernetes.io/docs/reference/using-api/deprecation-guide/#poddisruptionbudget-v125

Change-Id: Ia6189b98a86b3f7575dc4678bb3a0cce69562c93
2022-05-10 15:12:53 -04:00
Thiago Brito 0da995972d Enable taint toleration for ingress
This adds taint toleration support for openstack jobs

Signed-off-by: Lucas Cavalcante <lucasmedeiros.cavalcante@windriver.com>
Change-Id: Ibac507770edd09079e01206fd85b76a193d22915
2022-03-23 18:10:09 +00:00
Phil Sphicas 3a10c5ba95 ingress: Add option to assign VIP as externalIP
Some CNIs support the advertisement of service IPs into BGP, which may
provide an alternative to managing the VIP as an interface on the host.

This change adds an option to assign the ingress VIP as an externalIP to
the ingress service. For example:

    network:
      vip:
        manage: false
        addr: 172.18.0.1/32           # (with or without subnet mask)
        assign_as_external_ip: true

Change-Id: I1eeb07a1f94ef8efcb21f3373e0d5f86be725b33
2022-03-11 11:48:09 -08:00
Phil Sphicas f4972121bc Migrate Ingress resources to networking.k8s.io/v1
This change updates the helm-toolkit and ingress charts to migrate
Ingress resources to the networking.k8s.io/v1 API version, available
since v1.19. [0]

0: https://kubernetes.io/docs/reference/using-api/deprecation-guide/#ingress-v122

Change-Id: Ic6bd6d158b1294da26c165797c90107831dcb508
2021-10-15 04:47:00 +00: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
jinyuanliu 2e80509e0f Uplift ingress to 0.42.0
- Uplifts the image to nginx 0.42.0 to address CVEs
- Adds labels needed for nginx 0.42.0
- Updates release notes for ingress

Change-Id: I133d6d30d4a68628ee516f5896780cc8096ffd1f
2021-06-09 07:48:54 +00: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
Phil Sphicas f08d30df6b Use HostToContainer mountPropagation
For any host mounts that include /var/lib/kubelet, use HostToContainer
mountPropagation, which avoids creating extra references to mounts in
other containers.

Affects the following resources:
* ingress deployment
* openvswitch-vswitchd daemonset

Change-Id: I5964c595210af60d54158e6f7c962d5abe77fc2f
2021-01-07 20:29:24 +00:00
jh629g 67618474ce Update default Kubernetes API for use with Helm v3
Updated Kubernetes api from extensions/v1beta1 to
networking.k8s.io/v1beta1 per docs[0] for kubernetes
1.16 deprecations as helm v3 linting will fail
when it parses extensions/v1beta1 seen here[1]

[0] https://kubernetes.io/blog/2019/07/18/api-deprecations-in-1-16/
[1] https://zuul.opendev.org/t/openstack/build/82f92508fb31418aa377f91d62e0d42e

Change-Id: I0439272587a2afbccc4d7c49ef6ad053c8b305e7
2021-01-05 16:43:38 +00:00
Chris Wedgwood 82a828ce8d Update to container image repo k8s.gcr.io
gcr.io/google_containers/ no longer contains the image versions we
require, use the new location.

Change-Id: Iabb9e672e494f27d1a3691a9ce0dd2ccf10d5797
2020-12-07 19:34:09 +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
Zuul 2bfce96304 Merge "Run chart-testing on all charts" 2020-09-17 14:38:19 +00:00
KHIYANI, RAHUL (rk0850) 24a0dcdee4 Ingress: Configure ingress dhparam secret
Configuring dhparam secret to generate 2048 DH group for
nginx openstack ingress

Change-Id: I8d8add9d518cbf928f58bfcac71e2b6c74075060
2020-09-15 14:16:50 -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
Phil Sphicas 341e9b29df Ingress: Configure Default SSL Certificate
Adds configuration options for the --default-ssl-certificate feature of
NGINX Ingress Controller, which provides a default certificate for
requests that do not match any configured server names.[0]

To enable with a new certificate, specify:
  .conf.default_ssl_certificate.enabled=true
  .endpoints.ingress.host_fqdn_override.public.tls.crt="PEM cert data"
  .endpoints.ingress.host_fqdn_override.public.tls.key="PEM key data"
  .manifests.secret_ingress_tls=true

To enable using a TLS cert in an existing secret, specify:
  .conf.default_ssl_certificate.enabled=true
  .conf.default_ssl_certificate.name="name of the secret"
  .conf.default_ssl_certificate.namespace="namespace of the secret"

0: https://kubernetes.github.io/ingress-nginx/user-guide/tls/#default-ssl-certificate

Change-Id: Idd704fd880f56137923d4c38cc188b130ee3b56d
2020-08-14 05:32:51 +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
Zuul c8a5edb218 Merge "Ingress: add apparmor profile to ingress init containers" 2020-06-15 23:22:27 +00:00
KHIYANI, RAHUL (rk0850) ae278c674e Ingress: add apparmor profile to ingress init containers
concat is not available in helm 14.1, using work around
to emulate this functionality.

Change-Id: Iccbc5de567be1c899b7f5d47cf43b6e962c27e91
2020-06-12 21:02:32 +00: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
Gupta, Sangeet (sg774j) 9ff76434aa Ingress: Use latest controller image
Use nginx-ingress-controller:0.32.0 and change user to 101
intead of 33 which is suported by this image.

Change-Id: I38679e350ec352f13074055b7e08b98df1090fbf
2020-06-01 21:46:44 +00: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
KHIYANI, RAHUL (rk0850) 99a77eefda error-pages: updating the defaultbackend version to 1.4
removing the command "/tmp/ingress-error-pages.sh" script as the
1.4 version already uses "/server" exec
https://hub.docker.com/layers/siriuszg/defaultbackend/1.4/images/sha256-989154cad9fa0edab79acd8904b3ed643f3325fe827616ffa7c1181bb1e1321b?context=explore

Change-Id: I3769abeea16254fe5cc4f0f92eb8e8d89cf356a6
2020-05-26 10:42:29 -05:00
Zuul ee57e65bf0 Merge "[ingress] Support nginx-ingress-controller 0.30.0" 2020-05-18 22:28:33 +00:00
Andrii Ostapenko 82c6ceaf18 Don't try to apply k8s acl control to non existent container
Change-Id: Iff8dee23cad5e1846135456df66d52b8aa3b19a2
2020-05-18 17:52:58 +00:00
Michael Polenchuk 0e644a1fac [ingress] Support nginx-ingress-controller 0.30.0
In 0.30.0 (busybox inside) the "find" tool doesn't support
"writable" option, so use "perm" instead. Also get rid of
several system calls by means of make all by one command.

Change-Id: Ia4f7bc01fb61f4f32c21c50d8c4e870d0244c868
2020-05-17 05:39:51 +00:00
Zuul aa957ea2c4 Merge "Mariadb: Add apparmor profile to init-containers" 2020-05-14 18:10:47 +00:00
KHIYANI, RAHUL (rk0850) 845385de38 Mariadb: Add apparmor profile to init-containers
This change adds apparmor profile to mariadb init containers and
ingress init container

Change-Id: I843baf221a82d234104b14db5b02026fe87e6063
2020-05-14 09:57:21 -05:00
Tin Lam 3dd6d0e7a0 chore(images): update to stein bionic images
Some infra charts still have old ocata xenial images as default. This
should bring them up to date with the OSH charts.

Change-Id: If8454b6d0fe52387bf6327501ee4ff87f56e87b8
Signed-off-by: Tin Lam <tin@irrational.io>
2020-05-14 07:21:41 -05:00
Zuul e53d28718d Merge "Remove OSH Authors copyright" 2020-05-12 20:00:38 +00:00
KHIYANI, RAHUL (rk0850) 8617c8c1e0 Ingress: Add apparmor profile to ingress init container
Change-Id: I2217a8ab8c76b8f6a14f477c3159e4133ef186f9
2020-05-07 13:51:29 +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
KHIYANI, RAHUL (rk0850) 5bc24e78a4 Ingress: Run nginx ingress as non-root user
Running nginx ingress with www-data user

Change-Id: I769577cdedd05cc1b8b035928e67ad7ed70568db
2020-04-27 16:12:21 -05:00
diwakar thyagaraj 965e1b6079 [FIX] Fix Typo in Apparmor profile to Ingress Charts
Change-Id: I548b441d6c712fd63fdf7dacb475683533a001ca
Signed-off-by: diwakar thyagaraj <diwakar.chitoor.thyagaraj@att.com>
2020-04-19 00:13:49 +00:00
KHIYANI, RAHUL (rk0850) ae41873341 Add Docker default AppArmor profile to ingress chart
Change-Id: Id4fee2008fd7544ccbf865084949c767013ca3fa
2020-02-13 22:41:37 +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
Phil Sphicas e7b4242c3b Ingress: nginx-ingress-controller 0.26.1+ support
nginx-ingress-controller 0.26.1 introduces configurable parameters for
streamPort and profilerPort, and changes the default for statusPort.

This change allows those parameters to be configured, while maintaining
compatibility with earlier versions of nginx-ingress.controller. It also
modifies the default status port value from 18080 to 10246.

Reference: https://github.com/kubernetes/ingress-nginx/blob/master/Changelog.md#0261

Change-Id: I88a7315f2ed47c31b8c2862ce1ad47b590b32137
2020-01-01 13:34:00 -08:00
Phil Sphicas bcecbad652 Ingress: k8s and ingress version compatibility
k8s 1.14 first enabled Ingress in the networking.k8s.io/v1beta1 API
group, while still serving it in the extensions/v1beta1 API group. The
extensions/v1beta1 API endpoint is deprecated in 1.16 and scheduled for
removal in 1.20. [0]

ingress-nginx 0.25.0 actually uses the networking.k8s.io/v1beta1 API,
which requires updated RBAC rules. [1]

This change updates the ClusterRole used by the ingress service account
to grant access to Ingress resources via either the extensions/v1beta1
or networking.k8s.io/v1beta1 API, aligning with the static manifests
from the kubernetes/ingress-nginx repo [2]. It does not change the
apiVersion used when creating Ingress resources.

[0] https://kubernetes.io/blog/2019/07/18/api-deprecations-in-1-16/
[1] https://github.com/kubernetes/ingress-nginx/releases/tag/nginx-0.25.0
[2] 870be3bcd8/deploy/static/mandatory.yaml (L50-L106)

Change-Id: I67d4dbdb3834ca4ac8ce90ec51c8d6414ce80a01
2020-01-01 13:34:00 -08:00
Phil Sphicas 6ca136bae4 Ingress chart managed VIP fixes cleanup/startup
When the ingress pod (in routed mode, using a managed vip) moves from
one host to another, it is sometimes observed that: 1. the vip interface
is not removed on the original host, and 2. in some network topologies,
the switch fabric is unable to find the new pod.

This change updates the ingress deployment as follows:

Adds a 5s sleep before the shutdown of the ingress container in order to
allow the preStop action of the ingress-vip container to run completely.

Updates the start action of the ingress-vip-init container to check if
the vip is part of an existing connected subnet, and if so, sends a few
gratuitous ARP messages to let the switch fabric to build its ARP cache.

Change-Id: I784906865358566f42157dc2133569e4cb270cfa
2019-11-20 07:25:50 -08:00