Skip to content

Commit

Permalink
(maint)updating readme for github issue puppetlabs#68 (puppetlabs#79)
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkW authored and scotty-c committed Dec 14, 2017
1 parent fc37f5c commit d0e65f9
Showing 1 changed file with 22 additions and 1 deletion.
23 changes: 22 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -582,13 +582,14 @@ To remove the service from a swarm, include the `ensure => absent` parameter and

If a server is not specified, images are pushed and pulled from [index.docker.io](https://index.docker.io). To qualify your image name, create a private repository without authentication.

To configure authentication for a private registry, add the following code to the manifest file:
To configure authentication for a private registry, add the following code to the manifest file , depending on what version of Docker you are running. If you are using Docker V1.10 or earlier add the following code to the manifest file ensuring that you specify the docker version:

```puppet
docker::registry { 'example.docker.io:5000':
username => 'user',
password => 'secret',
email => 'user@example.com',
version => '<docker_version>'
}
```

Expand All @@ -600,9 +601,29 @@ docker::registry_auth::registries:
username: 'user1'
password: 'secret'
email: 'user1@example.io'
version: '<docker_version>'
}
```

If using Docker V1.11 or later the docker login e-mail flag has been deprecated [docker_change_log](https://docs.docker.com/release-notes/docker-engine/#1110-2016-04-13). Add the following code to the manifest file:

'''puppet
docker::registry { 'example.docker.io:5000'}
username => 'user',
password => 'secret',
}
''

If using hiera, configure the 'docker::registry_auth' class:

'''yaml
docker::registry_auth::registries:
'example.docker.io:5000':
username: 'user1'
password: 'secret'
}
'''
To log out of a registry, add the following code to the manifest file:
```puppet
Expand Down

0 comments on commit d0e65f9

Please sign in to comment.