2022-05-18 17:22:45 +02:00
|
|
|
---
|
|
|
|
apiVersion: batch/v1
|
|
|
|
kind: CronJob
|
|
|
|
metadata:
|
|
|
|
name: renovate-infrastructure
|
|
|
|
namespace: gitops
|
|
|
|
spec:
|
2022-05-20 11:13:11 +02:00
|
|
|
schedule: "@hourly"
|
2022-05-18 17:22:45 +02:00
|
|
|
concurrencyPolicy: Forbid
|
|
|
|
jobTemplate:
|
|
|
|
spec:
|
|
|
|
template:
|
|
|
|
spec:
|
|
|
|
volumes:
|
2022-05-20 11:13:11 +02:00
|
|
|
- name: config-volume
|
|
|
|
configMap:
|
|
|
|
name: renovate-config
|
|
|
|
- name: work-volume
|
|
|
|
emptyDir: {}
|
2022-05-18 17:22:45 +02:00
|
|
|
containers:
|
|
|
|
- name: renovate
|
2022-05-24 21:15:46 +02:00
|
|
|
image: renovate/renovate:32.66
|
2022-05-18 17:22:45 +02:00
|
|
|
volumeMounts:
|
|
|
|
- name: config-volume
|
|
|
|
mountPath: /opt/renovate/
|
|
|
|
- name: work-volume
|
|
|
|
mountPath: /tmp/renovate/
|
|
|
|
env:
|
|
|
|
- name: LOG_LEVEL
|
|
|
|
value: debug
|
|
|
|
- name: RENOVATE_ENDPOINT
|
2022-05-20 11:13:11 +02:00
|
|
|
value: "https://git.0x76.dev/api/v1/"
|
2022-05-18 17:22:45 +02:00
|
|
|
- name: RENOVATE_PLATFORM
|
|
|
|
value: gitea
|
|
|
|
- name: RENOVATE_AUTODISCOVER
|
2022-05-20 11:13:11 +02:00
|
|
|
value: "false"
|
2022-05-18 17:22:45 +02:00
|
|
|
- name: RENOVATE_GIT_AUTHOR
|
2022-05-20 11:13:11 +02:00
|
|
|
value: "Renovate Bot <renovate@xirion.net>"
|
2022-05-18 17:22:45 +02:00
|
|
|
- name: RENOVATE_CONFIG_FILE
|
2022-05-20 11:40:28 +02:00
|
|
|
value: "/opt/renovate/config.js"
|
2022-05-18 17:22:45 +02:00
|
|
|
- name: RENOVATE_BASE_DIR
|
2022-05-20 11:13:11 +02:00
|
|
|
value: "/tmp/renovate"
|
2022-05-18 17:22:45 +02:00
|
|
|
envFrom:
|
|
|
|
- secretRef:
|
|
|
|
name: renovate
|
|
|
|
restartPolicy: Never
|
|
|
|
---
|
|
|
|
apiVersion: v1
|
|
|
|
kind: ConfigMap
|
|
|
|
metadata:
|
|
|
|
name: renovate-config
|
2022-05-18 17:24:53 +02:00
|
|
|
namespace: gitops
|
2022-05-18 17:22:45 +02:00
|
|
|
data:
|
2022-05-20 11:40:28 +02:00
|
|
|
config.js: |-
|
|
|
|
module.exports = {
|
2022-05-18 17:22:45 +02:00
|
|
|
"repositories": ["v/infrastructure"],
|
|
|
|
"flux": {
|
2022-05-25 20:57:31 +02:00
|
|
|
"fileMatch": ["flux/.+\\.ya?ml$"]
|
2022-05-18 17:22:45 +02:00
|
|
|
},
|
2022-05-18 19:25:49 +02:00
|
|
|
"helm-values": {
|
2022-05-25 20:57:31 +02:00
|
|
|
"fileMatch": ["flux/.+\\.ya?ml$"]
|
2022-05-18 20:19:25 +02:00
|
|
|
},
|
2022-05-18 17:22:45 +02:00
|
|
|
"kubernetes": {
|
2022-05-25 20:57:31 +02:00
|
|
|
"fileMatch": ["flux/.+\\.ya?ml$"]
|
2022-05-20 10:51:15 +02:00
|
|
|
},
|
2022-05-20 11:33:54 +02:00
|
|
|
"hostRules": [
|
2022-05-20 11:30:33 +02:00
|
|
|
{
|
2022-05-20 11:33:54 +02:00
|
|
|
"hostType": "docker",
|
|
|
|
"matchHost": "ghcr.io",
|
|
|
|
"username": "NULLx76",
|
|
|
|
"password": process.env.GITHUB_COM_TOKEN
|
2022-05-20 11:30:33 +02:00
|
|
|
}
|
|
|
|
],
|
2022-05-20 10:51:15 +02:00
|
|
|
"packageRules": [
|
2022-05-20 11:13:11 +02:00
|
|
|
{
|
|
|
|
"automerge": true,
|
2022-05-24 21:06:38 +02:00
|
|
|
"automergeType": "pr",
|
2022-05-20 11:13:11 +02:00
|
|
|
"matchPackageNames": [
|
|
|
|
"renovate/renovate"
|
|
|
|
]
|
|
|
|
}
|
2022-05-25 20:57:31 +02:00
|
|
|
],
|
|
|
|
"regexManagers": [
|
|
|
|
{
|
|
|
|
"description": "Process GitRepository CRD dependencies - Chart and Github Release are the same version",
|
|
|
|
"fileMatch": ["flux/cluster/crds/.+\\.ya?ml$"],
|
|
|
|
"matchStrings": [
|
|
|
|
"registryUrl=(?<registryUrl>\\S+) chart=(?<depName>\\S+)\n.*?(?<currentValue>[^-\\s]*)\n"
|
|
|
|
],
|
|
|
|
"datasourceTemplate": "helm"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"description": "Process Kustomization CRD dependencies - Image and Github Release are the same version",
|
|
|
|
"fileMatch": ["flux/cluster/crds/.+\\.ya?ml$"],
|
|
|
|
"matchStrings": [
|
|
|
|
"datasource=(?<datasource>\\S+) image=(?<depName>\\S+)\n.*?-\\s(.*?)\/(?<currentValue>[^/]+)\/[^/]+\n"
|
|
|
|
],
|
|
|
|
"datasourceTemplate": "docker"
|
|
|
|
}
|
2022-05-20 10:51:15 +02:00
|
|
|
]
|
2022-05-20 11:40:28 +02:00
|
|
|
};
|