@@ -277,11 +277,14 @@ This is equivalent to running the `docker run -d base /bin/sh -c "while true; d
277
277
``` puppet
278
278
docker::run { 'helloworld':
279
279
image => 'base',
280
+ detach => true,
281
+ service_prefix => 'docker-',
280
282
command => '/bin/sh -c "while true; do echo hello world; sleep 1; done"',
281
283
ports => ['4444', '4555'],
282
284
expose => ['4666', '4777'],
283
285
links => ['mysql:db'],
284
286
net => 'my-user-def-net',
287
+ disable_network => false,
285
288
volumes => ['/var/lib/couchdb', '/var/log'],
286
289
volumes_from => '6446ea52fbc9',
287
290
memory_limit => '10m', # (format: '<number><unit>', where unit = b, k, m or g)
@@ -290,6 +293,7 @@ docker::run { 'helloworld':
290
293
hostname => 'example.com',
291
294
env => ['FOO=BAR', 'FOO2=BAR2'],
292
295
env_file => ['/etc/foo', '/etc/bar'],
296
+ labels => ['com.example.foo="true"', 'com.example.bar="false"'],
293
297
dns => ['8.8.8.8', '8.8.4.4'],
294
298
restart_service => true,
295
299
privileged => false,
@@ -298,6 +302,7 @@ docker::run { 'helloworld':
298
302
before_start => 'echo "Run this on the host before starting the Docker container"',
299
303
after => [ 'container_b', 'mysql' ],
300
304
depends => [ 'container_a', 'postgres' ],
305
+ stop_wait_time => 0,
301
306
extra_parameters => [ '--restart=always' ],
302
307
}
303
308
```
0 commit comments