- TCP services in the external ingress controller
- Customize the gitlab ingress options
- Custom certifcate management
This chart configures
Ingress resources for use with the official
ingress-nginx implementation. The
nginx ingress controller is deployed as a part of this chart. If you want to
reuse an existing nginx ingress controller already available in your cluster,
this guide will help.
The gitlab-shell component requires TCP traffic to pass through on port 22 (by default; this can be changed). Ingress does not directly support TCP services, so some additonal configuration is necessary. Your nginx ingress controller may have been deployed directly (i.e. with a Kubernetes spec file) or through the official Helm chart. The configuration of the TCP pass through will differ depending on the deployment approach.
In a direct deployment, the nginx ingress controller handles configuring TCP services with a
ConfigMap (see docs here).
Assuming your Gitlab chart is deployed to the namespace
gitlab and your helm
release is named
ConfigMap should be something like this:
apiVersion: v1 kind: ConfigMap metadata: name: tcp-configmap-example data: 22: "gitlab/mygitlab-gitlab-shell:22"
After you have that
ConfigMap, you can enable it as described in the nginx
ingress controller docs
args: - /nginx-ingress-controller - --tcp-services-configmap=gitlab/tcp-configmap-example
Finally make sure that the
Service for your nginx ingress controller is exposing
port 22 in addition to 80 and 443.
If you have installed or will install the nginx ingress controller via it’s Helm chart, then you will need to add a value to the chart via the command line:
tcp: 22: "gitlab/mygitlab-gitlab-shell:22"
The format for the value is the same as describe above in the “Direct Deployment” section.
The nginx ingress controller uses an annotation to mark which ingress controller
will service a particular
Ingress (see docs).
You can configure the ingress class to use with this chart using the
global.ingress.class setting. Make sure to set this in your helm options.
While not necessarily required, if you’re using an external ingress controller, you will likely want to disable the ingress controller that is deployed by default with this chart:
The full scope of your TLS options are documented elswhere.
If you are using an external ingress controller, you may also be using an external cert-manager instance or managing your certificates in some other custom manner. The full documentation around your TLS options is here, however for the purposes of this discussion, here are the two values that would need to be set to disable the cert-manager chart and tell the gitlab component charts to NOT look for the built in certificate resources:
--set certmanager.install=false --set global.ingress.configureCertmanager=false