mirror of
https://github.com/dokku/dokku.git
synced 2026-07-11 04:51:57 +02:00
The `dokku.com/cron-id` label could exceed Kubernetes' 63-byte cap because the cron ID is `base36(appName === command === schedule)`, which expands roughly 1.5x per byte. The label is now keyed `dokku.com/cron-hash` and holds the `sha1` hex digest of the cron-id, a fixed 40-character value that always fits the cap. The same hex digest is mirrored into the `dokku.com/cron-hash` annotation, and the original base36 cron-id stays in the `dokku.com/cron-id` annotation that `cron:list` reads when surfacing user-facing IDs. Per-task lookups stay server-side via label selectors, so `cron:set --maintenance` and the forbid/replace concurrency checks on `dokku run --cron-id` keep working without any in-memory filtering.
30 lines
607 B
JSON
30 lines
607 B
JSON
{
|
|
"cron": [
|
|
{
|
|
"command": "python3 task.py some cron task",
|
|
"schedule": "5 5 5 5 5"
|
|
}
|
|
],
|
|
"healthchecks": {
|
|
"web": [
|
|
{
|
|
"attempts": 2,
|
|
"content": "python/http.server",
|
|
"name": "check-1",
|
|
"path": "/",
|
|
"timeout": 5,
|
|
"type": "startup",
|
|
"wait": 2
|
|
}
|
|
]
|
|
},
|
|
"scripts": {
|
|
"dokku": {
|
|
// this is a comment for the postdeploy script
|
|
"postdeploy": "touch /workspace/postdeploy.test",
|
|
// this is a comment for the predeploy script
|
|
"predeploy": "touch /workspace/predeploy.test"
|
|
}
|
|
}
|
|
}
|