diff --git a/lib/centurion/service.rb b/lib/centurion/service.rb index 26d39eee..78b04908 100644 --- a/lib/centurion/service.rb +++ b/lib/centurion/service.rb @@ -178,7 +178,7 @@ def build_host_config(restart_policy = nil) host_config['RestartPolicy'] = {} restart_policy_name = restart_policy.name - restart_policy_name = 'on-failure' unless ["always", "on-failure", "no"].include?(restart_policy_name) + restart_policy_name = 'on-failure' unless ["always", "on-failure", "no", "unless-stopped"].include?(restart_policy_name) host_config['RestartPolicy']['Name'] = restart_policy_name host_config['RestartPolicy']['MaximumRetryCount'] = restart_policy.max_retry_count || 10 if restart_policy_name == 'on-failure'