mirror of
https://github.com/tiennm99/composes.git
synced 2026-10-11 03:13:16 +00:00
chore: set restart: unless-stopped on every service
Coolify injects the same value when a compose service omits one, but Dokploy runs the file as written, so in its default compose mode an omitted policy leaves the container down after a crash or a host reboot.
This commit is contained in:
1 parent
b626c5b70d
commit
c2b508c171
10 files changed
+29
-12
No files matched your search
@@ -106,13 +106,19 @@ unprompted:
|
||||
- **No `ports:`.** Coolify and Dokploy attach the container to their proxy
|
||||
network and map a domain to the internal port. Publishing a port is redundant
|
||||
and would additionally expose it on the host.
|
||||
- **No `restart:` policy.** The platform manages the container lifecycle.
|
||||
- **No `container_name:`.** Let Compose derive it from the directory.
|
||||
|
||||
More generally: these files are tuned to one person's setup and are not meant
|
||||
to be portable, standard, or turnkey. Prefer leaving a service minimal over
|
||||
adding hardening or convention that the platform already provides.
|
||||
|
||||
`restart:` is the exception that is *not* omitted. Every service sets
|
||||
`restart: unless-stopped`, on every container. Coolify injects that exact value
|
||||
when a service does not declare one, and keeps the declared value when it does;
|
||||
Dokploy does not inject anything, so in its default compose mode an omitted
|
||||
policy leaves the container down after a crash or a host reboot. Setting it is
|
||||
correct on both.
|
||||
|
||||
## Secrets
|
||||
|
||||
Every service reads secrets from a sibling `.env`. Never commit one — the root
|
||||
|
||||
Reference in new issue
Block a user