You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: add container stop/restart for docker volume backups
- Add ContainerStopConfig with stopContainers, stopTimeout,
restartRetries, and restartRetryDelay options
- Support global config (docker.containerStop) and per-volume override
- Add CLI flags: --stop-containers, --stop-timeout, --restart-retries
- Detect auto-restart policies and warn about potential conflicts
- Retry failed restarts with configurable attempts and delay
- Add comprehensive tests for all new functionality
- Containers with `restart: always` or `restart: unless-stopped` policies may auto-restart after being stopped. BackItUp detects this and logs a warning.
364
+
- If a container fails to restart after all retries, the backup still succeeds but a warning is logged.
365
+
- Per-volume settings override global settings, allowing fine-grained control.
|`name`| string | Yes | Volume name or Compose service name |
249
+
|`type`| string | No |`"volume"` (default) or `"compose"`|
250
+
|`composePath`| string | No\*| Path to docker-compose.yml |
251
+
|`projectName`| string | No | Compose project name (inferred from directory) |
252
+
|`containerStop`| object | No | Per-volume override of container stop settings |
231
253
232
254
\*Required when `type: compose`.
233
255
256
+
**Notes on Container Stop:**
257
+
258
+
- When `stopContainers` is enabled, BackItUp stops all containers using the volume before backup and restarts them after.
259
+
- Containers with `restart: always` or `restart: unless-stopped` policies may auto-restart after being stopped. BackItUp detects this and logs a warning.
260
+
- Per-volume `containerStop` settings override global settings.
261
+
- If a container fails to restart after all retries, the backup still succeeds but a warning is logged.
0 commit comments