Deploy Renovate cronjob
This commit is contained in:
parent
b07e1b089a
commit
3dcf257fcd
118
manifests/raw-resources-infra/renovate/cronjob.yaml
Normal file
118
manifests/raw-resources-infra/renovate/cronjob.yaml
Normal file
@ -0,0 +1,118 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: renovate-config
|
||||||
|
namespace: infra
|
||||||
|
data:
|
||||||
|
config.js: |
|
||||||
|
module.exports = {
|
||||||
|
platform: "gitea",
|
||||||
|
endpoint: "https://git.dvirlabs.com/api/v1/",
|
||||||
|
gitAuthor: "Renovate Bot <renovate@dvirlabs.com>",
|
||||||
|
|
||||||
|
repositories: [
|
||||||
|
"dvirlabs/dev-tools"
|
||||||
|
],
|
||||||
|
|
||||||
|
onboarding: false,
|
||||||
|
requireConfig: "required",
|
||||||
|
|
||||||
|
dependencyDashboard: true,
|
||||||
|
|
||||||
|
prHourlyLimit: 2,
|
||||||
|
prConcurrentLimit: 5,
|
||||||
|
|
||||||
|
automerge: false,
|
||||||
|
|
||||||
|
labels: ["renovate"],
|
||||||
|
|
||||||
|
enabledManagers: [
|
||||||
|
"dockerfile",
|
||||||
|
"docker-compose",
|
||||||
|
"helmv3",
|
||||||
|
"helm-values",
|
||||||
|
"kubernetes",
|
||||||
|
"npm",
|
||||||
|
"pip_requirements"
|
||||||
|
],
|
||||||
|
|
||||||
|
kubernetes: {
|
||||||
|
managerFilePatterns: [
|
||||||
|
"/(^|/)manifests/.+\\.ya?ml$/",
|
||||||
|
"/(^|/)k8s/.+\\.ya?ml$/",
|
||||||
|
"/(^|/)apps/.+\\.ya?ml$/",
|
||||||
|
"/(^|/)charts/.+\\.ya?ml$/"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
|
||||||
|
packageRules: [
|
||||||
|
{
|
||||||
|
matchDatasources: ["docker"],
|
||||||
|
addLabels: ["docker-image"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
matchManagers: ["helmv3", "helm-values"],
|
||||||
|
addLabels: ["helm"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
matchManagers: ["kubernetes"],
|
||||||
|
addLabels: ["kubernetes"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
matchUpdateTypes: ["major"],
|
||||||
|
addLabels: ["major-update"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
matchUpdateTypes: ["minor"],
|
||||||
|
addLabels: ["minor-update"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
matchUpdateTypes: ["patch"],
|
||||||
|
addLabels: ["patch-update"]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: batch/v1
|
||||||
|
kind: CronJob
|
||||||
|
metadata:
|
||||||
|
name: renovate
|
||||||
|
namespace: infra
|
||||||
|
spec:
|
||||||
|
schedule: "0 3 * * *"
|
||||||
|
concurrencyPolicy: Forbid
|
||||||
|
successfulJobsHistoryLimit: 3
|
||||||
|
failedJobsHistoryLimit: 3
|
||||||
|
jobTemplate:
|
||||||
|
spec:
|
||||||
|
backoffLimit: 1
|
||||||
|
template:
|
||||||
|
spec:
|
||||||
|
restartPolicy: Never
|
||||||
|
containers:
|
||||||
|
- name: renovate
|
||||||
|
image: renovate/renovate:latest
|
||||||
|
imagePullPolicy: IfNotPresent
|
||||||
|
env:
|
||||||
|
- name: RENOVATE_CONFIG_FILE
|
||||||
|
value: /usr/src/app/config.js
|
||||||
|
|
||||||
|
- name: RENOVATE_TOKEN
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: renovate-secret
|
||||||
|
key: RENOVATE_TOKEN
|
||||||
|
|
||||||
|
- name: LOG_LEVEL
|
||||||
|
value: info
|
||||||
|
|
||||||
|
volumeMounts:
|
||||||
|
- name: config
|
||||||
|
mountPath: /usr/src/app/config.js
|
||||||
|
subPath: config.js
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
- name: config
|
||||||
|
configMap:
|
||||||
|
name: renovate-config
|
||||||
Loading…
x
Reference in New Issue
Block a user