Skip to content

Commit fe78698

Browse files
authored
Merge pull request #520 from khaefeli/detach
🐛 Fix wrong service detach handling
2 parents 869748b + 57982bc commit fe78698

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/puppet/parser/functions/docker_service_flags.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,14 @@ module Puppet::Parser::Functions
1010
opts = args[0] || {}
1111
flags = []
1212

13-
if opts['detach'].to_s != 'true'
14-
flags << '--detach'
15-
end
16-
1713
if opts['service_name'] && opts['service_name'].to_s != 'undef'
1814
flags << "'#{opts['service_name']}'"
1915
end
2016

17+
if opts['detach'].to_s != 'false'
18+
flags << '--detach'
19+
end
20+
2121
if opts['env'].is_a? Array
2222
opts['env'].each do |env|
2323
flags << "--env #{env}"

0 commit comments

Comments
 (0)