项目作者: neetjn

项目描述 :
Ansible playbook for setting up and provisioning a private docker registry.
高级语言:
项目地址: git://github.com/neetjn/ansible-docker-registry.git
创建时间: 2017-09-10T19:04:09Z
项目社区:https://github.com/neetjn/ansible-docker-registry

开源协议:MIT License

下载


ansible-docker-register

Ansible playbook for setting up and provisioning a private docker registry.

This ansible playbook will install docker if not done so already, and any other necessary packages or modules. This playbook also supports NGINX proxying if a host is specified in the NGINX host group.

Variables

Playbook inventory variables can be found in groupvars/all.yml.

registry_port: Port for NGINX registry to bind to.
registry_user: Registry username for http auth (for NGINX).
registry_pass: Registry password for http auth (for NGINX).

Requirements

  1. git
  2. ansible 2 - 2.3

Due to a change in version 2.4 explained here, any version of ansible above 2.3.x is not recommended.

Use

Clone the repository,

  1. git clone https://github.com/neetjn/ansible-docker-registry.git

Run the playbook,

  1. ansible-playbook playbook.yml

Optionally, if you would like to configure a remote ystem:

  • Replace the placeholder host in the hosts inventory file.
  • Uncomment the ansible-ssh-user and ansible-ssh-pass variables from your group variables.
  • Update them accordingly with login credentials for your remote machine.

Then run your playbook,

  1. ansible-playbook playbook.yml -i hosts

Additionally if you would like to setup NGINX:

  • Modify your registry_user and registry_pass variables in your group variables to reflect your desired credentials.
  • Add --extra-vars "registry_host=mydomain.com" to then end of your ansible-playbook command.

Copyright (c) 2017 John Nolette Licensed under the MIT license.