feat: use smaller image + cache dir #5

Merged
cyrnel merged 1 commits from cache-dir into main 2025-10-05 00:13:53 +00:00
3 changed files with 41 additions and 3 deletions

View File

@ -30,3 +30,27 @@ This recipe runs Renovate as a cronjob every hour (configurable via `CRON_SCHEDU
You can configure how Renovate behaves with a `renovate.json` file in each target repo. Renovate will not run on a repo unless this file exists. By default, Renovate will attempt to "[onboard](https://docs.renovatebot.com/self-hosted-configuration/#onboarding)" any new repo by creating a pull request to create the `renovate.json` file.
For more information please refer to the [Renovate documentation](https://docs.renovatebot.com/).
## Using Renovate for coop-cloud recipes
If you store your recipe .env files in git, you can use Renovate to automatically bump recipe versions. To do this, add the following to the end of your `renovate.json` (courtesy of p4u1):
```json
{
"customManagers": [
{
"customType": "regex",
"managerFilePatterns": [
"/^servers\\/.*\\/.*\\.env$/"
],
"matchStrings": [
"(RECIPE|TYPE)=(?<depName>.*?):(?<currentValue>.*.*?)"
],
"datasourceTemplate": "gitea-tags",
"depNameTemplate": "coop-cloud/{{depName}}",
"registryUrlTemplate": "https://git.coopcloud.tech/"
}
]
}
```

View File

@ -1,7 +1,7 @@
services:
app:
# Use "full" since the non-full version installs tools at runtime
image: "renovate/renovate:41-full"
# Docs recommend using the non-full image and use a volume for caching downloaded binaries
image: "renovate/renovate:41"
healthcheck:
disable: true
deploy:
@ -10,11 +10,15 @@ services:
labels:
- "swarm.cronjob.enable=true"
- "swarm.cronjob.schedule=${CRON_SCHEDULE}"
- "coop-cloud.${STACK_NAME}.version=1.0.1+41-full"
- "coop-cloud.${STACK_NAME}.version=1.0.1+41"
decentral1se marked this conversation as resolved
Review

Do we need to bump the 1.0.1 part also?

Do we need to bump the `1.0.1` part also?
Review

I planned to do a sync on main (I probably should have just not changed the line at all)

I planned to do a `sync` on main (I probably should have just not changed the line at all)
restart_policy:
condition: none
environment:
- RENOVATE_TOKEN_FILE=/run/secrets/renovate_token
# This is already the default, we're just being explicit since they've moved it before
- RENOVATE_BASE_DIR=/tmp/renovate
volumes:
- renovate-data:/tmp/renovate
secrets:
- renovate_token
configs:
@ -33,3 +37,6 @@ configs:
name: ${STACK_NAME}_app_entrypoint_${APP_ENTRYPOINT_VERSION}
file: entrypoint.sh.tmpl
template_driver: golang
volumes:
renovate-data:

7
release/next Normal file
View File

@ -0,0 +1,7 @@
The previous release used the "-full" renovate image which is 6 gigabytes
but doesn't install tools at runtime. Apparently the docs discourage this, so
this release moves to using the "non-full" image.
When renovate detects e.g. a golang dependency, it will now download a golang toolchain
and store it in a persistent volume. This means the total disk usage of the tool should
be much lower for most users.