Files
cours-ISEN-MD/ISEN/Cloud Computing/CIPA4/TP 1 Ansible.md

560 B

#CIPA4 #CloudComputing #DP #Ansible #TP

TP 1

ssh root@135.125.246.84

mdp : moutarde42

Installation

Install ansible on localhost

apt install ansible

Ad-hoc ping

Q: What happened behing the scene? It ping the localhost.

Ad-hoc shell

Q: what command can you use to get the IP of your machine?

ansible localhost -m shell -a "ip a"

Ad-hoc setup

Q: using this module, what other command can you use to retrieve the ip of your host?

ansible localhost -m setup -a "filter=ansible_default_ipv4"