Skip to content

Commit 2f28d4b

Browse files
committed
fixup: configured resources for all deployments
1 parent 347e4fc commit 2f28d4b

File tree

6 files changed

+115
-82
lines changed

6 files changed

+115
-82
lines changed

config/config/sc-config.yaml

+68-10
Original file line numberDiff line numberDiff line change
@@ -1243,17 +1243,75 @@ networkPolicies:
12431243

12441244
# Tekton Configuration
12451245
tekton:
1246-
components:
1247-
pipelines:
1248-
enabled: false
1249-
dashboard:
1250-
enabled: false
1251-
triggers:
1252-
enabled: false
1253-
chains:
1254-
enabled: false
1246+
enabled: false
1247+
1248+
operator:
1249+
resources:
1250+
limits:
1251+
cpu: 50m
1252+
memory: 128Mi
1253+
requests:
1254+
cpu: 25m
1255+
memory: 64Mi
1256+
1257+
webhook:
1258+
resources:
1259+
limits:
1260+
cpu: 20m
1261+
memory: 64Mi
1262+
requests:
1263+
cpu: 10m
1264+
memory: 32Mi
1265+
1266+
webhookProxy:
1267+
resources:
1268+
limits:
1269+
cpu: 20m
1270+
memory: 64Mi
1271+
requests:
1272+
cpu: 10m
1273+
memory: 32Mi
1274+
1275+
pipelines:
1276+
controller:
1277+
resources:
1278+
limits:
1279+
cpu: 50m
1280+
memory: 128Mi
1281+
requests:
1282+
cpu: 25m
1283+
memory: 64Mi
1284+
1285+
remoteResolvers:
1286+
resources:
1287+
limits:
1288+
cpu: 20m
1289+
memory: 64Mi
1290+
requests:
1291+
cpu: 10m
1292+
memory: 32Mi
1293+
1294+
webhook:
1295+
resources:
1296+
limits:
1297+
cpu: 20m
1298+
memory: 128Mi
1299+
requests:
1300+
cpu: 10m
1301+
memory: 64Mi
1302+
1303+
eventsController:
1304+
resources:
1305+
limits:
1306+
cpu: 20m
1307+
memory: 64Mi
1308+
requests:
1309+
cpu: 10m
1310+
memory: 32Mi
1311+
12551312
serviceAccount:
12561313
name: tekton-service
1257-
clusterAdmin: false
1314+
clusterAdmin: true
1315+
12581316
imagePullSecrets:
12591317
- name: pull-secret

config/config/wc-config.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -316,5 +316,5 @@ gatekeeper:
316316
tekton:
317317
serviceAccount:
318318
name: tekton-workload
319-
clusterAdmin: false
319+
clusterAdmin: true
320320
imagePullSecrets: []

helmfile.d/charts/tekton/tekton-operator/templates/deployment.yaml

-4
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,6 @@ spec:
2424
imagePullSecrets:
2525
{{- toYaml . | nindent 8 }}
2626
{{- end }}
27-
# {{- with .Values.podSecurityContext }}
28-
# securityContext:
29-
# {{- toYaml . | nindent 8 }}
30-
# {{- end }}
3127
containers:
3228
- env:
3329
- name: SYSTEM_NAMESPACE

helmfile.d/charts/tekton/tekton-operator/templates/tekton-pipeline-config.yaml

+30-7
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,33 @@ spec:
1414
spec:
1515
containers:
1616
- name: tekton-pipelines-controller
17-
resources:
18-
requests:
19-
cpu: 100m
20-
memory: 100Mi
21-
limits:
22-
cpu: 120m
23-
memory: 102Mi # TODO: make this configurable through apps config
17+
resources: {{- toYaml .Values.pipelines.controller.resources | nindent 20 }}
18+
tekton-pipelines-remote-resolvers:
19+
spec:
20+
template:
21+
spec:
22+
containers:
23+
- name: controller
24+
resources: {{- toYaml .Values.pipelines.remoteResolvers.resources | nindent 20 }}
25+
tekton-pipelines-webhook:
26+
spec:
27+
template:
28+
spec:
29+
containers:
30+
- name: webhook
31+
resources: {{- toYaml .Values.pipelines.webhook.resources | nindent 20 }}
32+
# These below are not actually part of tekton-pipelines but there was no other way of configuring resource requests/limits for them through the operator chart.
33+
tekton-events-controller:
34+
spec:
35+
template:
36+
spec:
37+
containers:
38+
- name: tekton-events-controller
39+
resources: {{- toYaml .Values.eventsController.resources | nindent 20 }}
40+
tekton-operator-proxy-webhook:
41+
spec:
42+
template:
43+
spec:
44+
containers:
45+
- name: proxy
46+
resources: {{- toYaml .Values.webhookProxy.resources | nindent 20 }}

helmfile.d/stacks/tekton.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ templates:
3232
- template: tekton
3333
name: tekton-operator
3434
chart: charts/tekton/tekton-operator
35-
installed: {{ and (.Values | get "tekton.enabled" false) (.Values | get "tekton.components.pipelines.enabled" false) }}
36-
version: 0.1.0
35+
installed: {{ .Values | get "tekton.enabled" false }}
36+
version: 0.68.0
3737
values:
3838
- values/tekton/tekton-sc.gotmpl

helmfile.d/values/tekton/tekton-sc.gotmpl

+14-58
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
11
{{- with .Values.tekton.imagePullSecrets }}
2-
## If container images are hosted in a private registry, set pull secrets.
3-
## Secrets must be manually created in the namespace.
4-
## see https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/
52
imagePullSecrets: []
63
{{- end }}
74

@@ -10,75 +7,34 @@ serviceAccount:
107
clusterAdmin: {{ .Values.tekton.serviceAccount.clusterAdmin }}
118
imagePullSecrets: {{- toYaml .Values.tekton.imagePullSecrets | nindent 4 }}
129

13-
## Override the full name of this Helm release
14-
nameOverride: ""
15-
16-
openshift:
17-
enabled: false
18-
1910
installCRDs: true
2011

2112
rbac:
2213
create: false
23-
# Annotations to add to the RBAC resources
24-
annotations: {}
25-
serviceAccount:
26-
# The name of the service account to use.
27-
# If not set and create is true, a name is generated using the fullname template
28-
name: ""
2914

3015
# Available controllers: "tektonconfig,tektonpipeline,tektontrigger,tektonhub,tektonchain,tektonresult,tektondashboard"
3116
controllers: "tektonpipeline"
3217

33-
## Configuration for the tekton-operator pod
3418
operator:
35-
# Internal name of the operator. Default value depends on the flavor (k8s/openshift).
36-
operatorName: ""
37-
image:
38-
# Container image for Tekton operator. Default value depends on the flavor (k8s/openshift).
39-
repository: ""
40-
pullPolicy: IfNotPresent
41-
# Overrides the image tag whose default is the chart appVersion.
42-
tag: ""
4319
autoInstallComponents: true
44-
# The namespace in which Tekton components should be deployed
45-
# Defaults to "tekton-pipelines" for Kubernetes and to "openshift-pipelines" for Openshift flavor.
46-
defaultTargetNamespace: ""
47-
# Log level of the operator
48-
logLevel: info
49-
# Resource requests and limits for the operator pod
50-
# see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
51-
resources: {}
52-
deployment:
53-
# Custom labels for the Deployment resource.
54-
customLabels: ""
55-
# Custom labels for the Deployment Pod Template.
56-
podTemplateCustomLabels: ""
20+
resources: {{- toYaml .Values.tekton.operator.resources | nindent 4 }}
5721

58-
## Configuration for the tekton-operator-webhook pod
5922
webhook:
60-
hostNetwork: false
61-
dnsPolicy: ""
62-
httpsWebhookPort: 8443
63-
image:
64-
# Container image for Tekton operator webhook. Default value depends on the flavor (k8s/openshift).
65-
repository: ""
66-
pullPolicy: IfNotPresent
67-
# Overrides the image tag whose default is the chart appVersion.
68-
tag: ""
69-
certSecret:
70-
name: ""
71-
useExistingSecret: ""
72-
# Log level of the webhook
73-
logLevel: info
74-
# Resource requests and limits for the operator pod
75-
# see https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/
76-
resources: {}
23+
resources: {{- toYaml .Values.tekton.operator.webhook.resources | nindent 4 }}
7724

7825
webhookProxy:
79-
image:
80-
repository: ""
81-
tag: ""
26+
resources: {{- toYaml .Values.tekton.operator.webhookProxy.resources | nindent 4 }}
27+
28+
pipelines:
29+
controller:
30+
resources: {{- toYaml .Values.tekton.pipelines.controller.resources | nindent 6 }}
31+
remoteResolvers:
32+
resources: {{- toYaml .Values.tekton.pipelines.remoteResolvers.resources | nindent 6 }}
33+
webhook:
34+
resources: {{- toYaml .Values.tekton.pipelines.webhook.resources | nindent 6 }}
35+
36+
eventsController:
37+
resources: {{- toYaml .Values.tekton.eventsController.resources | nindent 6 }}
8238

8339
service:
8440
# Enable auto-discovery by Prometheus, requires the ServiceMonitor.monitoring.coreos.com CR

0 commit comments

Comments
 (0)