mirror of
https://github.com/dokku/dokku.git
synced 2025-12-29 00:25:08 +01:00
refactor: migrate DOKKU_DOCKER_STOP_TIMEOUT to ps setting
This commit is contained in:
6
docs/appendices/0.36.0-migration-guide.md
Normal file
6
docs/appendices/0.36.0-migration-guide.md
Normal file
@@ -0,0 +1,6 @@
|
||||
# 0.35.0 Migration Guide
|
||||
|
||||
## Changes
|
||||
|
||||
- Process stop timeouts are now configured via the `ps` property `stop-timeout-seconds`. Existing `DOKKU_DOCKER_STOP_TIMEOUT` environment variables will be automatically migrated to the new value.
|
||||
- Processes now default to a `30` second stop timeout.
|
||||
@@ -112,7 +112,6 @@ The following config variables have special meanings and can be set in a variety
|
||||
| `DOKKU_DISABLE_PROXY` | none | `dokku proxy:disable` <br /> `dokku proxy:enable` | Disables the proxy in front of your application, resulting in publicly routing the docker container. |
|
||||
| `DOKKU_DISABLE_ANSI_PREFIX_REMOVAL` | none | `dokku config:set` <br /> `/etc/environment` <br /> `~dokku/.dokkurc` <br /> `~dokku/.dokkurc/*` | Disables removal of the ANSI prefix during deploys. Can be used in cases where the client deployer does not understand ansi escape codes. |
|
||||
| `DOKKU_DISABLE_APP_AUTOCREATION` | none | `dokku config:set` | Disables automatic creation of a non-existent app on deploy. |
|
||||
| `DOKKU_DOCKER_STOP_TIMEOUT` | `10` | `dokku config:set` | Configurable grace period given to the `docker stop` command. If a container has not stopped by this time, a `kill -9` signal or equivalent is sent in order to force-terminate the container. Both the `ps:stop` and `apps:destroy` commands _also_ respect this value. If not specified, the docker defaults for the [docker stop command](https://docs.docker.com/engine/reference/commandline/stop/) will be used.|
|
||||
| `DOKKU_DOCKERFILE_CACHE_BUILD` | none | `dokku config:set` | |
|
||||
| `DOKKU_DOCKERFILE_START_CMD` | none | `dokku config:set` | |
|
||||
| `DOKKU_PARALLEL_ARGUMENTS`. | none | `dokku config:set` | Allows passing custom arguments to parallel for `ps:*all` commands |
|
||||
|
||||
@@ -36,12 +36,15 @@ dokku checks:set node-js-app wait-to-retire 30
|
||||
|
||||
Defaults to `60`.
|
||||
|
||||
## Setting stop grace period
|
||||
|
||||
You can set the `stop-timeout` property on the `ps` plugin to change this value (default: `30`). See the [process management documentation](/docs/processes/process-management.md#changing-process-management-settings) for more information.
|
||||
|
||||
## Configuring check settings using the `config` plugin
|
||||
|
||||
There are certain settings that can be configured via environment variables:
|
||||
|
||||
- `DOKKU_DEFAULT_CHECKS_WAIT`: (default: `10`) If no user-defined checks are specified - or if the process being checked is not a `web` process - this is the period of time Dokku will wait before checking that a container is still running.
|
||||
- `DOKKU_DOCKER_STOP_TIMEOUT`: (default: `10`) Configurable grace period given to the `docker stop` command. If a container has not stopped by this time, a `kill -9` signal or equivalent is sent in order to force-terminate the container. Both the `ps:stop` and `apps:destroy` commands *also* respect this value. If not specified, the Docker defaults for the [`docker stop` command](https://docs.docker.com/engine/reference/commandline/stop/) will be used.
|
||||
|
||||
The following settings may also be specified in the `app.json` file, though are available as environment variables in order to ease application reuse.
|
||||
|
||||
|
||||
@@ -107,6 +107,39 @@ proctype: qty
|
||||
web: 1
|
||||
```
|
||||
|
||||
### Changing process management settings
|
||||
|
||||
The `ps` plugin provides a number of settings that can be used to managed deployments on a per-app basis. The following table outlines ones not covered elsewhere:
|
||||
|
||||
| Name | Description | Global Default |
|
||||
|-----------------------|---------------------------------------------------|--------------------|
|
||||
| `stop-timeout` | Configurable grace period given to the `docker stop` command. If a container has not stopped by this time, a `kill -9` signal or equivalent is sent in order to force-terminate the container. Both the `ps:stop` and `apps:destroy` commands *also* respect this value. If not specified, the Docker defaults for the [`docker stop` command](https://docs.docker.com/engine/reference/commandline/stop/) will be used. | `30` |
|
||||
|
||||
All settings can be set via the `scheduler-k3s:set` command. Using `stop-timeout` as an example:
|
||||
|
||||
```shell
|
||||
dokku scheduler-k3s:set node-js-app stop-timeout 60
|
||||
```
|
||||
|
||||
The default value may be set by passing an empty value for the option in question:
|
||||
|
||||
```shell
|
||||
dokku scheduler-k3s:set node-js-app stop-timeout
|
||||
```
|
||||
|
||||
Properties can also be set globally. If not set for an app, the global value will apply.
|
||||
|
||||
```shell
|
||||
dokku scheduler-k3s:set --global stop-timeout 60
|
||||
```
|
||||
|
||||
The global default value may be set by passing an empty value for the option.
|
||||
|
||||
```shell
|
||||
dokku scheduler-k3s:set --global stop-timeout
|
||||
```
|
||||
|
||||
|
||||
### Defining Processes
|
||||
|
||||
#### Procfile
|
||||
|
||||
Reference in New Issue
Block a user