apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
- ../base
configMapGenerator:
- name: runners-autoscaler-config
files:
- runners_config.yaml
options:
disableNameSuffixHash: true
runners_config.yaml.
namespace: bitbucket-runner-control-plane
commonLabels:
app.kubernetes.io/part-of: runners-autoscaler
images:
- name: bitbucketpipelines/runners-autoscaler
newTag: 3.9.0
patches:
- target:
version: v1
kind: Secret
name: runner-bitbucket-credentials
patch: |-
- op: add
path: /data/atlassianAccountEmail
value: "my_account_email_in_base64"
- op: add
path: /data/atlassianApiToken
value: "my_api_token_in_base64"
- target:
version: v1
kind: Deployment
labelSelector: "inject=runners-autoscaler-envs"
patch: |-
- op: replace
path: /spec/template/spec/containers/0/env
value:
- name: ATLASSIAN_ACCOUNT_EMAIL
valueFrom:
secretKeyRef:
key: atlassianAccountEmail
name: runner-bitbucket-credentials
- name: ATLASSIAN_API_TOKEN
valueFrom:
secretKeyRef:
key: atlassianApiToken
name: runner-bitbucket-credentials