Skip to content

OliveiraCleidson/poc-ansible

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 

Repository files navigation

README

Description

  1. Run docker-compose to start the control, node1 and node2
make up
  1. Enter in the control container
make control
  1. Copy the ssh key to the nodes, the password is Password123
ssh-copy-id root@node1
ssh-copy-id root@node2
  1. Execute ping to the nodes to check if the connection is working
ansible -i inventory/docker_nodes all -m ping

Ansible commands in the control container

  • Install requirements
ansible-galaxy install -r requirements.yml
  • Run playbooks
ansible-playbook -i inventory/docker_nodes playbooks/playbook_name.yaml

About

Testing Ansible in local environment with docker

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published