renovate-config
This project contains configuration presets for renovate, a bot to update dependencies. These presets can be integrated
into the renovate.json of the respective git project using the extends attribute.
How to
regexp
Contains regular expressions to search for inline configurations of renovate. For example in .sh or Makefile files.
A regular expression is applied to extract an inline configuration. The regular expression is really complex. For this
reason, it is reproduced on regexp101.com for the purpose of standardization.
Here are further examples how to use the regexp inline configuration.
container image version
A shell script that executes a container image. The version of the container image should be maintained in the shell script.
#!/bin/bash
VERSION="3.21.1" # renovate: datasource=docker registryUrl=https://docker.io depName=library/alpine
docker run --rm --entrypoint /bin/sh docker.io/library/alpine:${VERSION} -c "echo foo bar"
github releases and tags
A PKGBUILD file for the Arch Linux User Repository (AUR) whose version is to be updated based on GitHub releases.
Note
The concrete example can be found in volker-raschek/rpm-builder-aur.
pkgname=rpm-builder
pkgver=v0.8.1 # renovate: datasource=github-releases depName=Richterrettich/rpm-builder
pkgrel=1
extract version
The version of Postfixadmin is maintained in a Makefile. As source should be used github tags, but their tags does not
follow an official standard like PEP404 or semver. They use postfixadmin-<semver>. The extractVersion pattern is
used to extract the version of the git tag.
Note
The concrete example can be found in volker-raschek/postfixadmin-docker
# POSTFIXADMIN_VERSION
POSTFIXADMIN_VERSION?=3.3.15 # renovate: datasource=github-tags depName=postfixadmin/postfixadmin extractVersion='postfixadmin-(?<version>\d+\.\d+\.\d+)$'
grafana-dashboards
Grafana supports importing of dashboards via its sidecar container in kubernetes environments. The import can be
specified via the values.yaml file of kube-prometheus stack. The revision must be updated, if the maintainer of the
dashboard has released a new revision. This can be automatically be updated via renovate. Below is an excerpt of the
values.yaml file.
Note
The datasource
custom.grafana-dashboardsis a custom implemented datasource. The renovate project does not support updating grafana dashboards by default, because the API does not provide the required minimum set of attributes.Further information can be found on the discussion Grafana Dashboard revisions.
The gnetId and revision must be extracted from Grafana.com.
Important
The defined regexp in
regexp.jsondoes not support thatdepNamecontains any spaces!
grafana:
dashboards:
default:
1860-node-exporter-full:
gnetId: 1860
revision: 31 # renovate: datasource=custom.grafana-dashboards depName='Node-Exporter-Full' packageName=1860 versioning='regex:^(?<major>\d+)$'
datasource: Prometheus
15760-kubernetes-views-pods:
gnetId: 15760
revision: 19 # renovate: datasource=custom.grafana-dashboards depName='Kubernetes-Views-Pods' packageName=15760 versioning='regex:^(?<major>\d+)$'
datasource: Prometheus