fix: treat empty ps restart-policy as an unset

`dokku ps:set <app> restart-policy` with no value erroneously returned `Invalid restart-policy specified` instead of unsetting the property like every other ps property. The restart policy is now managed as a normal app and global property surfaced through the `--ps-restart-policy`, `--ps-global-restart-policy`, and `--ps-computed-restart-policy` report flags, with the effective value applied at deploy time and existing values migrated on install. Because it is no longer stored as a Docker option it no longer appears in `docker-options:report`, and `--ps-restart-policy` now reports the raw value with the `on-failure:10` default available via `--ps-computed-restart-policy`.
This commit is contained in:
Jose Diaz-Gonzalez
2026-05-27 23:33:03 -04:00
parent 44dd5e9eea
commit fec872711a
9 changed files with 182 additions and 29 deletions

View File

@@ -25,6 +25,7 @@ var (
// GlobalProperties is a map of all valid global ps properties
GlobalProperties = map[string]bool{
"procfile-path": true,
"restart-policy": true,
"skip-deploy": true,
"stop-timeout-seconds": true,
}