chore: change default restart policy for service containers always -> unless-stopped

This commit is contained in:
Pasha Sviderski
2025-08-07 18:09:35 +10:00
parent 8805178a58
commit ae9f943404
3 changed files with 4 additions and 28 deletions
+2 -2
View File
@@ -546,10 +546,10 @@ func (s *Server) CreateServiceContainer(
Memory: spec.Container.Resources.Memory,
MemoryReservation: spec.Container.Resources.MemoryReservation,
},
// Always restart service containers if they exit or a machine restarts.
// Restart service containers if they exit or a machine restarts unless they are explicitly stopped.
// For one-off containers and batch jobs we plan to use a different service type/mode.
RestartPolicy: container.RestartPolicy{
Name: container.RestartPolicyAlways,
Name: container.RestartPolicyUnlessStopped,
},
}