0% found this document useful (0 votes)
188 views

Mobaxterm Personal Edition V22.0 - : (SSH Client, X Server and Network Tools)

The document describes a SSH session log into a server at 146.59.156.114 using MobaXterm. It then summarizes installing and configuring Nginx and copying an index.html file to two servers using Ansible. The Ansible playbook triggers a handler to restart Nginx after copying the new index.html file.

Uploaded by

Ahmadou Dia AW
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
188 views

Mobaxterm Personal Edition V22.0 - : (SSH Client, X Server and Network Tools)

The document describes a SSH session log into a server at 146.59.156.114 using MobaXterm. It then summarizes installing and configuring Nginx and copying an index.html file to two servers using Ansible. The Ansible playbook triggers a handler to restart Nginx after copying the new index.html file.

Uploaded by

Ahmadou Dia AW
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as RTF, PDF, TXT or read online on Scribd
You are on page 1/ 694

[email protected].

114's password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

Last login: Mon Oct    3 08:26:57 2022 from 176.160.191.208


ofi03@svl200:~$

Network error: Software caused connection abort


~
────────────────────────────────────────────────────────────────────────────────
~
Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
"handler.yaml" [New File]                                                           
0,0-1                  All
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)


* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Mon Oct    3 13:13:55 2022 from 176.160.191.208
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ vim handler.yaml
ansadmin@svl200:~$ sudo vim handler.yaml
ansadmin@svl200:~$ sudo vim index.html
ansadmin@svl200:~$ ansible-playbook handler.yaml

PLAY [configure webserver with nginx]


************************************************

TASK [Gathering Facts]


***************************************************************
ok: [146.59.158.16]

TASK [install    nginx]


****************************************************************
ok: [146.59.158.16]

TASK [copy index.html]


***************************************************************
changed: [146.59.158.16]

RUNNING HANDLER [restart_nginx]


******************************************************
changed: [146.59.158.16]

PLAY RECAP
***************************************************************************
146.59.158.16                            : ok=4      changed=2      unreachable=0 
failed=0        skipped                                                             
=0        rescued=0        ignored=0

ansadmin@svl200:~$ 146.59.158.16 ^C
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$ sudo vim handler.yaml
ansadmin@svl200:~$ ansible-playbook handler.yaml
[WARNING]: Could not match supplied host pattern, ignoring: cible{1
[WARNING]: Could not match supplied host pattern, ignoring: 2}

PLAY [configure webserver with nginx]


************************************************
skipping: no hosts matched

PLAY RECAP
***************************************************************************

ansadmin@svl200:~$ sudo vim handler.yaml


ansadmin@svl200:~$ ansible-playbook handler.yaml

PLAY [configure webserver with nginx]


************************************************

TASK [Gathering Facts]


***************************************************************
ok: [141.95.160.133]
ok: [146.59.158.16]

TASK [install    nginx]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [copy index.html]


***************************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

RUNNING HANDLER [restart_nginx]


******************************************************
changed: [141.95.160.133]

PLAY RECAP
***************************************************************************
141.95.160.133                          : ok=4      changed=2      unreachable=0   
failed=0        skipped                                                             
=0        rescued=0        ignored=0
146.59.158.16                            : ok=3      changed=0        unreachable=0 
failed=0        skipped                                                             
=0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim handler.yaml


ansadmin@svl200:~$ ansible-playbook handler.yaml

PLAY [configure webserver with nginx]


************************************************

TASK [Gathering Facts]


***************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install    nginx]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [copy index.html]


***************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
***************************************************************************
141.95.160.133                          : ok=3      changed=0        unreachable=0 
failed=0        skipped                                                             
=0        rescued=0        ignored=0
146.59.158.16                            : ok=3      changed=0        unreachable=0 
failed=0        skipped                                                             
=0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim handler.yaml


ansadmin@svl200:~$ sudo vim index.html
ansadmin@svl200:~$ ansible-playbook handler.yaml

PLAY [configure webserver with nginx]


************************************************

TASK [Gathering Facts]


***************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install    nginx]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [copy index.html]


***************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

RUNNING HANDLER [restart_nginx]


******************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
***************************************************************************
141.95.160.133                          : ok=4      changed=2      unreachable=0   
failed=0        skipped                                                             
=0        rescued=0        ignored=0
146.59.158.16                            : ok=4      changed=2      unreachable=0 
failed=0        skipped                                                             
=0        rescued=0        ignored=0

ansadmin@svl200:~$ vim /etc/ansible/hosts


ansadmin@svl200:~$ vim /etc/ssh/sshd_config
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible cible1 -m setup
146.59.158.16 | SUCCESS => {
        "ansible_facts": {
                "ansible_all_ipv4_addresses": [
                        "146.59.158.16"
                ],
                "ansible_all_ipv6_addresses": [
                        "2001:41d0:304:200::951d",
                        "fe80::f816:3eff:fee6:102e"
                ],
                "ansible_apparmor": {
                        "status": "enabled"
                },
                "ansible_architecture": "x86_64",
                "ansible_bios_date": "04/01/2014",
                "ansible_bios_version": "2:1.10.2-58953eb7",
                "ansible_cmdline": {
                        "BOOT_IMAGE": "/boot/vmlinuz-5.4.0-122-generic",
                        "console": "ttyS0",
                        "ro": true,
                        "root": "LABEL=cloudimg-rootfs"
                },
                "ansible_date_time": {
                        "date": "2022-10-03",
                        "day": "03",
                        "epoch": "1664805080",
                        "hour": "13",
                        "iso8601": "2022-10-03T13:51:20Z",
                        "iso8601_basic": "20221003T135120753276",
                        "iso8601_basic_short": "20221003T135120",
                        "iso8601_micro": "2022-10-03T13:51:20.753373Z",
                        "minute": "51",
                        "month": "10",
                        "second": "20",
                        "time": "13:51:20",
                        "tz": "UTC",
                        "tz_offset": "+0000",
                        "weekday": "Monday",
                        "weekday_number": "1",
                        "weeknumber": "40",
                        "year": "2022"
                },
                "ansible_default_ipv4": {
                        "address": "146.59.158.16",
                        "alias": "ens3",
                        "broadcast": "global",
                        "gateway": "146.59.156.1",
                        "interface": "ens3",
                        "macaddress": "fa:16:3e:e6:10:2e",
                        "mtu": 1500,
                        "netmask": "255.255.255.255",
                        "network": "146.59.158.16",
                        "type": "ether"
                },
                "ansible_default_ipv6": {
                        "address": "2001:41d0:304:200::951d",
                        "gateway": "2001:41d0:304:200::1",
                        "interface": "ens3",
                        "macaddress": "fa:16:3e:e6:10:2e",
                        "mtu": 1500,
                        "prefix": "56",
                        "scope": "global",
                        "type": "ether"
                },
                "ansible_device_links": {
                        "ids": {
                                "sda": [
                                        "scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0"
                                ],
                                "sda1": [
                                        "scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-
part1"
                                ],
                                "sda14": [
                                        "scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-
part14"
                                ],
                                "sda15": [
                                        "scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-
part15"
                                ]
                        },
                        "labels": {
                                "sda1": [
                                        "cloudimg-rootfs"
                                ],
                                "sda15": [
                                        "UEFI"
                                ]
                        },
                        "masters": {},
                        "uuids": {
                                "sda1": [
                                        "f209b90d-e073-4df4-950a-9c8620c2292b"
                                ],
                                "sda15": [
                                        "C957-9CB6"
                                ]
                        }
                },
                "ansible_devices": {
                        "loop0": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "126888",
                                "sectorsize": "512",
                                "size": "61.96 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop1": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "96176",
                                "sectorsize": "512",
                                "size": "46.96 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop10": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "98272",
                                "sectorsize": "512",
                                "size": "47.98 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop11": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "0",
                                "sectorsize": "512",
                                "size": "0.00 Bytes",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop2": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "138880",
                                "sectorsize": "512",
                                "size": "67.81 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop3": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "126888",
                                "sectorsize": "512",
                                "size": "61.96 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop4": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "233448",
                                "sectorsize": "512",
                                "size": "113.99 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop5": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "8688",
                                "sectorsize": "512",
                                "size": "4.24 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop6": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "129480",
                                "sectorsize": "512",
                                "size": "63.22 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop7": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "98288",
                                "sectorsize": "512",
                                "size": "47.99 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop8": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "235368",
                                "sectorsize": "512",
                                "size": "114.93 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop9": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "235496",
                                "sectorsize": "512",
                                "size": "114.99 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "sda": {
                                "holders": [],
                                "host": "SCSI storage controller: Red Hat, Inc.
Virtio SCSI",
                                "links": {
                                        "ids": [
                                                "scsi-0QEMU_QEMU_HARDDISK_drive-
scsi0-0-0-0"
                                        ],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": "QEMU HARDDISK",
                                "partitions": {
                                        "sda1": {
                                                "holders": [],
                                                "links": {
                                                        "ids": [
                                                                "scsi-
0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-part1"
                                                        ],
                                                        "labels": [
                                                                "cloudimg-rootfs"
                                                        ],
                                                        "masters": [],
                                                        "uuids": [
                                                                "f209b90d-e073-4df4-
950a-9c8620c2292b"
                                                        ]
                                                },
                                                "sectors": "83658719",
                                                "sectorsize": 512,
                                                "size": "39.89 GB",
                                                "start": "227328",
                                                "uuid": "f209b90d-e073-4df4-950a-
9c8620c2292b"
                                        },
                                        "sda14": {
                                                "holders": [],
                                                "links": {
                                                        "ids": [
                                                                "scsi-
0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-part14"
                                                        ],
                                                        "labels": [],
                                                        "masters": [],
                                                        "uuids": []
                                                },
                                                "sectors": "8192",
                                                "sectorsize": 512,
                                                "size": "4.00 MB",
                                                "start": "2048",
                                                "uuid": null
                                        },
                                        "sda15": {
                                                "holders": [],
                                                "links": {
                                                        "ids": [
                                                                "scsi-
0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-part15"
                                                        ],
                                                        "labels": [
                                                                "UEFI"
                                                        ],
                                                        "masters": [],
                                                        "uuids": [
                                                                "C957-9CB6"
                                                        ]
                                                },
                                                "sectors": "217088",
                                                "sectorsize": 512,
                                                "size": "106.00 MB",
                                                "start": "10240",
                                                "uuid": "C957-9CB6"
                                        }
                                },
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "83886080",
                                "sectorsize": "512",
                                "size": "40.00 GB",
                                "support_discard": "4096",
                                "vendor": "QEMU",
                                "virtual": 1
                        }
                },
                "ansible_distribution": "Ubuntu",
                "ansible_distribution_file_parsed": true,
                "ansible_distribution_file_path": "/etc/os-release",
                "ansible_distribution_file_variety": "Debian",
                "ansible_distribution_major_version": "20",
                "ansible_distribution_release": "focal",
                "ansible_distribution_version": "20.04",
                "ansible_dns": {
                        "nameservers": [
                                "127.0.0.53"
                        ],
                        "options": {
                                "edns0": true,
                                "trust-ad": true
                        },
                        "search": [
                                "openstacklocal"
                        ]
                },
                "ansible_domain": "vps.ovh.net",
                "ansible_effective_group_id": 1006,
                "ansible_effective_user_id": 1006,
                "ansible_ens3": {
                        "active": true,
                        "device": "ens3",
                        "features": {
                                "esp_hw_offload": "off [fixed]",
                                "esp_tx_csum_hw_offload": "off [fixed]",
                                "fcoe_mtu": "off [fixed]",
                                "generic_receive_offload": "on",
                                "generic_segmentation_offload": "on",
                                "highdma": "on [fixed]",
                                "hw_tc_offload": "off [fixed]",
                                "l2_fwd_offload": "off [fixed]",
                                "large_receive_offload": "off [fixed]",
                                "loopback": "off [fixed]",
                                "netns_local": "off [fixed]",
                                "ntuple_filters": "off [fixed]",
                                "receive_hashing": "off [fixed]",
                                "rx_all": "off [fixed]",
                                "rx_checksumming": "on [fixed]",
                                "rx_fcs": "off [fixed]",
                                "rx_gro_hw": "on",
                                "rx_udp_tunnel_port_offload": "off [fixed]",
                                "rx_vlan_filter": "on [fixed]",
                                "rx_vlan_offload": "off [fixed]",
                                "rx_vlan_stag_filter": "off [fixed]",
                                "rx_vlan_stag_hw_parse": "off [fixed]",
                                "scatter_gather": "on",
                                "tcp_segmentation_offload": "on",
                                "tls_hw_record": "off [fixed]",
                                "tls_hw_rx_offload": "off [fixed]",
                                "tls_hw_tx_offload": "off [fixed]",
                                "tx_checksum_fcoe_crc": "off [fixed]",
                                "tx_checksum_ip_generic": "on",
                                "tx_checksum_ipv4": "off [fixed]",
                                "tx_checksum_ipv6": "off [fixed]",
                                "tx_checksum_sctp": "off [fixed]",
                                "tx_checksumming": "on",
                                "tx_esp_segmentation": "off [fixed]",
                                "tx_fcoe_segmentation": "off [fixed]",
                                "tx_gre_csum_segmentation": "off [fixed]",
                                "tx_gre_segmentation": "off [fixed]",
                                "tx_gso_partial": "off [fixed]",
                                "tx_gso_robust": "on [fixed]",
                                "tx_ipxip4_segmentation": "off [fixed]",
                                "tx_ipxip6_segmentation": "off [fixed]",
                                "tx_lockless": "off [fixed]",
                                "tx_nocache_copy": "off",
                                "tx_scatter_gather": "on",
                                "tx_scatter_gather_fraglist": "off [fixed]",
                                "tx_sctp_segmentation": "off [fixed]",
                                "tx_tcp6_segmentation": "on",
                                "tx_tcp_ecn_segmentation": "on",
                                "tx_tcp_mangleid_segmentation": "off",
                                "tx_tcp_segmentation": "on",
                                "tx_udp_segmentation": "off [fixed]",
                                "tx_udp_tnl_csum_segmentation": "off [fixed]",
                                "tx_udp_tnl_segmentation": "off [fixed]",
                                "tx_vlan_offload": "off [fixed]",
                                "tx_vlan_stag_hw_insert": "off [fixed]",
                                "vlan_challenged": "off [fixed]"
                        },
                        "hw_timestamp_filters": [],
                        "ipv4": {
                                "address": "146.59.158.16",
                                "broadcast": "global",
                                "netmask": "255.255.255.255",
                                "network": "146.59.158.16"
                        },
                        "ipv6": [
                                {
                                        "address": "2001:41d0:304:200::951d",
                                        "prefix": "56",
                                        "scope": "global"
                                },
                                {
                                        "address": "fe80::f816:3eff:fee6:102e",
                                        "prefix": "64",
                                        "scope": "link"
                                }
                        ],
                        "macaddress": "fa:16:3e:e6:10:2e",
                        "module": "virtio_net",
                        "mtu": 1500,
                        "pciid": "virtio0",
                        "promisc": false,
                        "speed": -1,
                        "timestamping": [
                                "tx_software",
                                "rx_software",
                                "software"
                        ],
                        "type": "ether"
                },
                "ansible_env": {
                        "DBUS_SESSION_BUS_ADDRESS": "unix:path=/run/user/1006/bus",
                        "HOME": "/home/ansadmin",
                        "LANG": "C.UTF-8",
                        "LOGNAME": "ansadmin",
                        "MOTD_SHOWN": "pam",
                        "PATH":
"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:           
/usr/local/games:/snap/bin",
                        "PWD": "/home/ansadmin",
                        "SHELL": "/bin/bash",
                        "SHLVL": "0",
                        "SSH_CLIENT": "146.59.156.114 35036 55600",
                        "SSH_CONNECTION": "146.59.156.114 35036 146.59.158.16 55600",
                        "SSH_TTY": "/dev/pts/2",
                        "TERM": "xterm",
                        "USER": "ansadmin",
                        "XDG_RUNTIME_DIR": "/run/user/1006",
                        "XDG_SESSION_CLASS": "user",
                        "XDG_SESSION_ID": "468",
                        "XDG_SESSION_TYPE": "tty",
                        "_": "/bin/sh"
                },
                "ansible_fibre_channel_wwn": [],
                "ansible_fips": false,
                "ansible_form_factor": "Other",
                "ansible_fqdn": "vps-698c29b2.vps.ovh.net",
                "ansible_hostname": "master-wildfly",
                "ansible_hostnqn": "",
                "ansible_interfaces": [
                        "lo",
                        "ens3"
                ],
                "ansible_is_chroot": false,
                "ansible_iscsi_iqn": "",
                "ansible_kernel": "5.4.0-122-generic",
                "ansible_kernel_version": "#138-Ubuntu SMP Wed Jun 22 15:00:31 UTC
2022",
                "ansible_lo": {
                        "active": true,
                        "device": "lo",
                        "features": {
                                "esp_hw_offload": "off [fixed]",
                                "esp_tx_csum_hw_offload": "off [fixed]",
                                "fcoe_mtu": "off [fixed]",
                                "generic_receive_offload": "on",
                                "generic_segmentation_offload": "on",
                                "highdma": "on [fixed]",
                                "hw_tc_offload": "off [fixed]",
                                "l2_fwd_offload": "off [fixed]",
                                "large_receive_offload": "off [fixed]",
                                "loopback": "on [fixed]",
                                "netns_local": "on [fixed]",
                                "ntuple_filters": "off [fixed]",
                                "receive_hashing": "off [fixed]",
                                "rx_all": "off [fixed]",
                                "rx_checksumming": "on [fixed]",
                                "rx_fcs": "off [fixed]",
                                "rx_gro_hw": "off [fixed]",
                                "rx_udp_tunnel_port_offload": "off [fixed]",
                                "rx_vlan_filter": "off [fixed]",
                                "rx_vlan_offload": "off [fixed]",
                                "rx_vlan_stag_filter": "off [fixed]",
                                "rx_vlan_stag_hw_parse": "off [fixed]",
                                "scatter_gather": "on",
                                "tcp_segmentation_offload": "on",
                                "tls_hw_record": "off [fixed]",
                                "tls_hw_rx_offload": "off [fixed]",
                                "tls_hw_tx_offload": "off [fixed]",
                                "tx_checksum_fcoe_crc": "off [fixed]",
                                "tx_checksum_ip_generic": "on [fixed]",
                                "tx_checksum_ipv4": "off [fixed]",
                                "tx_checksum_ipv6": "off [fixed]",
                                "tx_checksum_sctp": "on [fixed]",
                                "tx_checksumming": "on",
                                "tx_esp_segmentation": "off [fixed]",
                                "tx_fcoe_segmentation": "off [fixed]",
                                "tx_gre_csum_segmentation": "off [fixed]",
                                "tx_gre_segmentation": "off [fixed]",
                                "tx_gso_partial": "off [fixed]",
                                "tx_gso_robust": "off [fixed]",
                                "tx_ipxip4_segmentation": "off [fixed]",
                                "tx_ipxip6_segmentation": "off [fixed]",
                                "tx_lockless": "on [fixed]",
                                "tx_nocache_copy": "off [fixed]",
                                "tx_scatter_gather": "on [fixed]",
                                "tx_scatter_gather_fraglist": "on [fixed]",
                                "tx_sctp_segmentation": "on",
                                "tx_tcp6_segmentation": "on",
                                "tx_tcp_ecn_segmentation": "on",
                                "tx_tcp_mangleid_segmentation": "on",
                                "tx_tcp_segmentation": "on",
                                "tx_udp_segmentation": "off [fixed]",
                                "tx_udp_tnl_csum_segmentation": "off [fixed]",
                                "tx_udp_tnl_segmentation": "off [fixed]",
                                "tx_vlan_offload": "off [fixed]",
                                "tx_vlan_stag_hw_insert": "off [fixed]",
                                "vlan_challenged": "on [fixed]"
                        },
                        "hw_timestamp_filters": [],
                        "ipv4": {
                                "address": "127.0.0.1",
                                "broadcast": "host",
                                "netmask": "255.0.0.0",
                                "network": "127.0.0.0"
                        },
                        "ipv6": [
                                {
                                        "address": "::1",
                                        "prefix": "128",
                                        "scope": "host"
                                }
                        ],
                        "mtu": 65536,
                        "promisc": false,
                        "timestamping": [
                                "tx_software",
                                "rx_software",
                                "software"
                        ],
                        "type": "loopback"
                },
                "ansible_local": {},
                "ansible_lsb": {
                        "codename": "focal",
                        "description": "Ubuntu 20.04.5 LTS",
                        "id": "Ubuntu",
                        "major_release": "20",
                        "release": "20.04"
                },
                "ansible_machine": "x86_64",
                "ansible_machine_id": "adc4dbb14d4447ada17154213d422c09",
                "ansible_memfree_mb": 222,
                "ansible_memory_mb": {
                        "nocache": {
                                "free": 1278,
                                "used": 657
                        },
                        "real": {
                                "free": 222,
                                "total": 1935,
                                "used": 1713
                        },
                        "swap": {
                                "cached": 0,
                                "free": 0,
                                "total": 0,
                                "used": 0
                        }
                },
                "ansible_memtotal_mb": 1935,
                "ansible_mounts": [
                        {
                                "block_available": 8921537,
                                "block_size": 4096,
                                "block_total": 10114671,
                                "block_used": 1193134,
                                "device": "/dev/sda1",
                                "fstype": "ext4",
                                "inode_available": 5046647,
                                "inode_total": 5160960,
                                "inode_used": 114313,
                                "mount": "/",
                                "options": "rw,relatime",
                                "size_available": 36542615552,
                                "size_total": 41429692416,
                                "uuid": "f209b90d-e073-4df4-950a-9c8620c2292b"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 543,
                                "block_used": 543,
                                "device": "/dev/loop2",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 802,
                                "inode_used": 802,
                                "mount": "/snap/lxd/22753",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 71172096,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 203074,
                                "block_size": 512,
                                "block_total": 213716,
                                "block_used": 10642,
                                "device": "/dev/sda15",
                                "fstype": "vfat",
                                "inode_available": 0,
                                "inode_total": 0,
                                "inode_used": 0,
                                "mount": "/boot/efi",
                                "options":
"rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=iso8859-                   
1,shortname=mixed,errors=remount-ro",
                                "size_available": 103973888,
                                "size_total": 109422592,
                                "uuid": "C957-9CB6"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 496,
                                "block_used": 496,
                                "device": "/dev/loop3",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 11796,
                                "inode_used": 11796,
                                "mount": "/snap/core20/1611",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 65011712,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 34,
                                "block_used": 34,
                                "device": "/dev/loop5",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 690,
                                "inode_used": 690,
                                "mount": "/snap/tree/18",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 4456448,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 506,
                                "block_used": 506,
                                "device": "/dev/loop6",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 11882,
                                "inode_used": 11882,
                                "mount": "/snap/core20/1623",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 66322432,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 384,
                                "block_used": 384,
                                "device": "/dev/loop7",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 486,
                                "inode_used": 486,
                                "mount": "/snap/snapd/16778",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 50331648,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 920,
                                "block_used": 920,
                                "device": "/dev/loop8",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 12845,
                                "inode_used": 12845,
                                "mount": "/snap/core/13741",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 120586240,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 920,
                                "block_used": 920,
                                "device": "/dev/loop9",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 12845,
                                "inode_used": 12845,
                                "mount": "/snap/core/13886",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 120586240,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 384,
                                "block_used": 384,
                                "device": "/dev/loop10",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 486,
                                "inode_used": 486,
                                "mount": "/snap/snapd/17029",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 50331648,
                                "uuid": "N/A"
                        }
                ],
                "ansible_nodename": "master-wildfly",
                "ansible_os_family": "Debian",
                "ansible_pkg_mgr": "apt",
                "ansible_proc_cmdline": {
                        "BOOT_IMAGE": "/boot/vmlinuz-5.4.0-122-generic",
                        "console": [
                                "tty1",
                                "ttyS0"
                        ],
                        "ro": true,
                        "root": "LABEL=cloudimg-rootfs"
                },
                "ansible_processor": [
                        "0",
                        "GenuineIntel",
                        "Intel Core Processor (Haswell, no TSX)"
                ],
                "ansible_processor_cores": 1,
                "ansible_processor_count": 1,
                "ansible_processor_threads_per_core": 1,
                "ansible_processor_vcpus": 1,
                "ansible_product_name": "OpenStack Nova",
                "ansible_product_serial": "NA",
                "ansible_product_uuid": "NA",
                "ansible_product_version": "19.0.4",
                "ansible_python": {
                        "executable": "/usr/bin/python3",
                        "has_sslcontext": true,
                        "type": "cpython",
                        "version": {
                                "major": 3,
                                "micro": 10,
                                "minor": 8,
                                "releaselevel": "final",
                                "serial": 0
                        },
                        "version_info": [
                                3,
                                8,
                                10,
                                "final",
                                0
                        ]
                },
                "ansible_python_version": "3.8.10",
                "ansible_real_group_id": 1006,
                "ansible_real_user_id": 1006,
                "ansible_selinux": {
                        "status": "Missing selinux Python library"
                },
                "ansible_selinux_python_present": false,
                "ansible_service_mgr": "systemd",
                "ansible_ssh_host_key_dsa_public":
"AAAAB3NzaC1kc3MAAACBAP6HcF8z3pABr7Ha4Z/hiKaYFifKH                                   
BMqCxMrB4joQeAx3e/OA93XudbdbwRmW2GtjdJf9mvVOjbvHZr44KAITI65I+MzAWn/
Bhx0cMyljGJJDyXFSQqzuwmzLg                                                           
XHbHnPAhw93kp1Ct1NOgEBTnwbhVzaQhEDQ6pmHCj/NIRyCFwLAAAAFQCPsGFnGGnYxsX59fhj2Aymc7tsfwA
AAIB7qfB                                                                             
O5uJoTj2nu3mbAVI8BuVRpGS4hBUctkR1pmvTkNbKJzAxrFDynG9fMx2LKsgIqjCgNFk0YahxigpGRJuLOe3L
6b0ymXGj                                                                             
QzJ2dvyB7ghpTLbRxgJa+MiZJuJlrztCrtrIjvxF1H9y2J7dLlwF9F6GsZAFCpm7uQKcLOpgDgAAAIEAoD+6L
4p4aFw7I                                                                             
ev0y+ehe3JCxLLC5NvblMLDGvqkA098r1EUCWSowH24IeFRHJ+cdWtcArJNclJDaNA8oePwjuQKtubQyr4W8O
1VYTYw3z                                                                             
P3W6qFDeFl5yLKA9EHUmxWc8ymXDGBcmwuVH2W1ZbteSSpKS1Ycp8OxzXqEalRrYc=",
                "ansible_ssh_host_key_ecdsa_public":
"AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTY                                     
AAABBBOn8ceAE4EDAWwmXkogeKexuv0b82zK+3VenUUR8P2cicoaQSsQ83fldYHzqhVSP5x98ZhqkHaHMgBkS
MZY8rBQ=                                                                             
",
                "ansible_ssh_host_key_ed25519_public":
"AAAAC3NzaC1lZDI1NTE5AAAAIM0bpK+LEEg6bH+uMeDKA                                       
HlvcQHBfj37qCeWUF+pS2uQ",
                "ansible_ssh_host_key_rsa_public":
"AAAAB3NzaC1yc2EAAAADAQABAAABgQDByfqYTpZnEJQpKILW/                                   
ELvPYKwSedP1hbHtGGEEymgw0dWhkKahKqNITSTPBF/0pALPm+3/IKONDAUr53cZQLngFrV+qu8rnKdaRo3OX
DZzJrWeR                                                                             
ZVmlyQTmF+uA8L3e+IJitvPPm+7Aj7SrbwfBqCPLNdEfN1ausTQZK/hIPCgOfAV2Yswr93nqtOSiiybhZ6lQx
e2KsDbh1                                                                             
XRjFUb4tgIUkt1Hbb3x22uqL4BAZ0htJ3EsDkwUv1VwTOc/CVs0IZryQZH1nEXJakk3z8Ibte2f75jIe1A1Vt
rYw6zQLp                                                                             
8HxkGs9S4YWxQJpeJ6k9bYRJ+SF+UPS3gchon+A2rOuaOSYMUCh9RH2g8DoIDawP7BPX38HTsgu6RPciz5nb2
oDJ0iCWF                                                                             
t8Zfj4rwGoigcYBWQ5NkBWHK1GpGs0wdt0VbiUlF2SzEDgJmESOn2bhyiXhoT/2OaX5lViPyjzr3NGVOO6z7V
j3HBEBqX                                                                             
F4+y/c4b08NiiucMDDp3CjQ5JtClE=",
                "ansible_swapfree_mb": 0,
                "ansible_swaptotal_mb": 0,
                "ansible_system": "Linux",
                "ansible_system_capabilities": [
                        ""
                ],
                "ansible_system_capabilities_enforced": "True",
                "ansible_system_vendor": "OpenStack Foundation",
                "ansible_uptime_seconds": 3303036,
                "ansible_user_dir": "/home/ansadmin",
                "ansible_user_gecos": ",,,",
                "ansible_user_gid": 1006,
                "ansible_user_id": "ansadmin",
                "ansible_user_shell": "/bin/bash",
                "ansible_user_uid": 1006,
                "ansible_userspace_architecture": "x86_64",
                "ansible_userspace_bits": "64",
                "ansible_virtualization_role": "guest",
                "ansible_virtualization_type": "openstack",
                "discovered_interpreter_python": "/usr/bin/python3",
                "gather_subset": [
                        "all"
                ],
                "module_setup": true
        },
        "changed": false
}
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible cible1 -m setup -a "filter=*family*"
146.59.158.16 | SUCCESS => {
        "ansible_facts": {
                "ansible_os_family": "Debian",
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false
}
ansadmin@svl200:~$ ansible cible2 -m setup -a "filter=*family*"
141.95.160.133 | SUCCESS => {
        "ansible_facts": {
                "ansible_os_family": "Debian",
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible cible2 -m setup -a "filter=*ip*"
141.95.160.133 | SUCCESS => {
        "ansible_facts": {
                "ansible_all_ipv4_addresses": [
                        "141.95.160.133"
                ],
                "ansible_all_ipv6_addresses": [
                        "2001:41d0:304:200::82a1",
                        "fe80::f816:3eff:fef2:cdf9"
                ],
                "ansible_default_ipv4": {
                        "address": "141.95.160.133",
                        "alias": "ens3",
                        "broadcast": "global",
                        "gateway": "141.95.160.1",
                        "interface": "ens3",
                        "macaddress": "fa:16:3e:f2:cd:f9",
                        "mtu": 1500,
                        "netmask": "255.255.255.255",
                        "network": "141.95.160.133",
                        "type": "ether"
                },
                "ansible_default_ipv6": {
                        "address": "2001:41d0:304:200::82a1",
                        "gateway": "2001:41d0:304:200::1",
                        "interface": "ens3",
                        "macaddress": "fa:16:3e:f2:cd:f9",
                        "mtu": 1500,
                        "prefix": "56",
                        "scope": "global",
                        "type": "ether"
                },
                "ansible_fips": false,
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false
}
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim fact.yaml
ansadmin@svl200:~$ cat fact.yaml
---
- name: facts
    hosts: all
    become: true
    vars:
        - var1: Hello DevOps1
        - var2: Good Morning DevOps2

    tasks:
        - name: echo text
            shell: echo "{{var1}} is var1, but var2 is {{var2}} >
/home/ansadmin/{{ansible_os_family}}.txt
ansadmin@svl200:~$ sudo vim fact.yaml
ansadmin@svl200:~$ ansible-playbook fact.yaml

PLAY [facts]
*************************************************************************************
****

TASK [Gathering Facts]


*******************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [echo text]
*************************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
*************************************************************************************
******
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=0        rescued=0                                           
ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=0        rescued=0                                           
ignored=0

ansadmin@svl200:~$ ansible all -a "ls -lrt"


146.59.158.16 | CHANGED | rc=0 >>
total 8
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
141.95.160.133 | CHANGED | rc=0 >>
total 8
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
ansadmin@svl200:~$ ansible all -a "cat Redhat.txt"
146.59.158.16 | FAILED | rc=1 >>
cat: Redhat.txt: No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=1 >>
cat: Redhat.txt: No such file or directorynon-zero return code
ansadmin@svl200:~$ ansible all -a "cat RedHat.txt"
146.59.158.16 | FAILED | rc=1 >>
cat: RedHat.txt: No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=1 >>
cat: RedHat.txt: No such file or directorynon-zero return code
ansadmin@svl200:~$ ansible all -a "cat Debian.txt"
146.59.158.16 | CHANGED | rc=0 >>
Hello DevOps1 is var1, but var2 is Good Morning DevOps2
141.95.160.133 | CHANGED | rc=0 >>
Hello DevOps1 is var1, but var2 is Good Morning DevOps2
ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$ cp fact.yaml fact1.yaml
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim fact.yaml
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim fact.yaml
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim ip.txt
ansadmin@svl200:~$ ansible-playbook fact1.yaml

PLAY [facts]
*************************************************************************************
****
TASK [Gathering Facts]
*******************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo text]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. Th                                                               
e error was: 'ip' is undefined\n\nThe error appears to be in
'/home/ansadmin/fact1.yaml': line 9, colu                                           
mn 7, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe
offending line a                                                                     
ppears to be:\n\n    tasks:\n        - name: echo text\n            ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefined variable. T                                                               
he error was: 'ip' is undefined\n\nThe error appears to be in
'/home/ansadmin/fact1.yaml': line 9, col                                             
umn 7, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\
nThe offending line                                                                  
appears to be:\n\n    tasks:\n        - name: echo text\n            ^ here\n"}

PLAY RECAP
*************************************************************************************
******
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0                                           
ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0                                           
ignored=0

ansadmin@svl200:~$ sudo vim fact1.yaml


ansadmin@svl200:~$ ansible-playbook fact1.yaml

PLAY [facts]
*************************************************************************************
****

TASK [Gathering Facts]


*******************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo text]


*************************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
*************************************************************************************
******
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=0        rescued=0                                           
ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=0        rescued=0                                           
ignored=0

ansadmin@svl200:~$ sudo vim fact1.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook fact1.yaml

PLAY [facts]
*************************************************************************************
****

TASK [Gathering Facts]


*******************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo text]


*************************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
*************************************************************************************
******
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=0        rescued=0                                           
ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=0        rescued=0                                           
ignored=0

ansadmin@svl200:~$ sudo vim ip.txt


ansadmin@svl200:~$ cat ip.txt
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ ansible all -a "cat ip.txt"
146.59.158.16 | CHANGED | rc=0 >>
['146.59.158.16']
141.95.160.133 | CHANGED | rc=0 >>
['141.95.160.133']
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim debug.yaml
ansadmin@svl200:~$ cat debug.yaml
---
-name: debug
hosts: cible1
become: true
vars:
      - var1: Hello Devops

tasks:
      - name: echo test
          command: echo -e "{{var1}} is var1 it works"
          register: results

      - name: show results


          debug: msg={{results}}

ansadmin@svl200:~$ ansible-playbook debug.yaml


ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/debug.yaml': line 3, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

-name: debug
hosts: cible1
            ^ here
ansadmin@svl200:~$ sudo vim debug.yaml
ansadmin@svl200:~$ ansible-playbook debug.yaml

PLAY [debug]
**********************************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]

TASK [echo test]


******************************************************************************
changed: [146.59.158.16]

TASK [show results]


***************************************************************************
ok: [146.59.158.16] => {
        "msg": {
                "changed": true,
                "cmd": [
                        "echo",
                        "-e",
                        "Hello Devops is var1 it works"
                ],
                "delta": "0:00:00.003328",
                "end": "2022-10-03 15:01:22.526831",
                "failed": false,
                "rc": 0,
                "start": "2022-10-03 15:01:22.523503",
                "stderr": "",
                "stderr_lines": [],
                "stdout": "Hello Devops is var1 it works",
                "stdout_lines": [
                        "Hello Devops is var1 it works"
                ]
        }
}

PLAY RECAP
************************************************************************************
146.59.158.16                            : ok=3      changed=1      unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim debug.yaml


ansadmin@svl200:~$ ansible-playbook debug.yaml

PLAY [debug]
**********************************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]

TASK [echo test]


******************************************************************************
changed: [146.59.158.16]

TASK [show results]


***************************************************************************
ok: [146.59.158.16] => {
        "msg": [
                "Hello Devops is var1 it works"
        ]
}

PLAY RECAP
************************************************************************************
146.59.158.16                            : ok=3      changed=1      unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ cp debug.yaml debug1.yaml
ansadmin@svl200:~$ sudo vim debug1.yaml
ansadmin@svl200:~$ ansible-playbook debug1.yaml

PLAY [debug]
**********************************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]

TASK [show results]


***************************************************************************
ok: [146.59.158.16] => {
        "msg": "Le serveur Apache utilise par defaut le port 80 sur ma machine
Debian"
}
PLAY RECAP
************************************************************************************
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


****************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time": 1                                                               
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg::Op                                                                         
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                    
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd' h                                                                           
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation candi                                                                   
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informa                                                                       
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    ng                                                                   
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04.                                                                     
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs 1                                                           
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-http                                                               
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                            
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-lig                                                                           
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                      
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubuntu                                                                       
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserver                                                                   
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time":                                                                
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg::O                                                                           
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                     
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd'                                                                              
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation cand                                                                   
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inform                                                                         
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    n                                                                   
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04                                                                       
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs                                                              
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-htt                                                               
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                           
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-li                                                                             
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                       
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubunt                                                                       
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserve                                                                   
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when.yaml
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


****************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time": 1                                                               
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg::Op                                                                         
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                    
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd' h                                                                           
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation candi                                                                   
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informa                                                                       
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    ng                                                                   
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04.                                                                     
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs 1                                                           
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-http                                                               
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                            
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-lig                                                                           
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                      
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubuntu                                                                       
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserver                                                                   
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time":                                                                
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg::O                                                                           
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                     
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd'                                                                              
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation cand                                                                   
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inform                                                                         
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    n                                                                   
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04                                                                       
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs                                                              
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-htt                                                               
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                           
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-li                                                                             
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                       
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubunt                                                                       
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserve                                                                   
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [apt get install httpd on centos]


********************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time": 1                                                               
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg::Op                                                                         
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                    
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd' h                                                                           
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation candi                                                                   
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informa                                                                       
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    ng                                                                   
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04.                                                                     
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs 1                                                           
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-http                                                               
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                            
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-lig                                                                           
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                      
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubuntu                                                                       
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserver                                                                   
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time":                                                                
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg::O                                                                           
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                     
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd'                                                                              
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation cand                                                                   
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inform                                                                         
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    n                                                                   
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04                                                                       
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs                                                              
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-htt                                                               
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                           
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-li                                                                             
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                       
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubunt                                                                       
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserve                                                                   
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when.yaml
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [apt-get install httpd on centos]
********************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time": 1                                                               
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg::Op                                                                         
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                    
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd' h                                                                           
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation candi                                                                   
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informa                                                                       
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    ng                                                                   
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04.                                                                     
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs 1                                                           
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-http                                                               
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                            
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-lig                                                                           
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                      
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubuntu                                                                       
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserver                                                                   
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time":                                                                
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg::O                                                                           
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                     
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd'                                                                              
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation cand                                                                   
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inform                                                                         
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    n                                                                   
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04                                                                       
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs                                                              
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-htt                                                               
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                           
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-li                                                                             
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                       
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubunt                                                                       
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserve                                                                   
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when.yaml
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


****************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time": 1                                                               
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg::Op                                                                         
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                    
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd' h                                                                           
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation candi                                                                   
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informa                                                                       
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    ng                                                                   
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04.                                                                     
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs 1                                                           
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-http                                                               
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                            
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-lig                                                                           
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                      
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubuntu                                                                       
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserver                                                                   
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time":                                                                
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg::O                                                                           
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                     
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd'                                                                              
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation cand                                                                   
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inform                                                                         
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    n                                                                   
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04                                                                       
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs                                                              
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-htt                                                               
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                           
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-li                                                                             
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                       
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubunt                                                                       
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserve                                                                   
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


****************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time": 1                                                               
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg::Op                                                                         
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                    
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd' h                                                                           
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation candi                                                                   
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informa                                                                       
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    ng                                                                   
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04.                                                                     
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs 1                                                           
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-http                                                               
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                            
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-lig                                                                           
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                      
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubuntu                                                                       
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserver                                                                   
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
...ignoring
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time":                                                                
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg::O                                                                           
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                     
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd'                                                                              
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation cand                                                                   
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inform                                                                         
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    n                                                                   
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04                                                                       
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs                                                              
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-htt                                                               
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                           
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-li                                                                             
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                       
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubunt                                                                       
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserve                                                                   
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
...ignoring

TASK [install apache2 on ubuntu]


**************************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=3      changed=1      unreachable=0   
failed=0        skipped=0        res                                                 
cued=0        ignored=1
146.59.158.16                            : ok=3      changed=0        unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=1

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$ -
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
──────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Mon Oct    3 13:16:15 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$ sudo vim when.yml
ansadmin@svl200:~$ history
        1    ssh-keygen -t rsa
        2    ssh
        3    ssh-copy-id [email protected] [email protected]
        4    sudo vim /etc/ssh/sshd_config
        5    ls -l .ssh/
        6    ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub [email protected] -p
55600
        7    ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub [email protected] -p
55600
        8    sudo vim /etc/ansible/hosts
        9    ansible all -m ping
      10    sudo vim /etc/ansible/hosts
      11    ansible all -m ping
      12    ansible cible1 -m ping
      13    ansible cible2 -m ping
      14    ansible 146.59.158.16 -m ping
      15    ansible 141.95.160.133 -m ping
      16    sudo touch cible1.txt
      17    ansible cible1 -m copy -a "src=cible1.txt dest=/tmp"
      18    ansible cible1 -m ls -a "dest=/tmp"
      19    ansible cible1 -m shell -a "ls -lrt /tmp"
      20    ansible cible1 -m file -a "dest=/tmp/cible1.txt mode=777"
      21    ansible cible1 -m user -a "name=cible1 state=present"
      22    ansible cible1 -b -m user -a "name=cible1 state=present"
      23    ansible cible1 -m shell -a "cat /etc/passwd | grep cible1"
      24    ansible all -b -m apt -a "name=curl state=latest"
      25    ansible cible1 -m service -a "name=cron state=started"
      26    ansible cible1 -b -m service -a "name=cron state=started"
      27    ansible cible1 -b -m service -a "name=cron state=stopped"
      28    ansible cible1 -b -m systemd -a "name=cron state=started"
      29    ansible cible1 -b -m systemd -a "name=cron state=stopped"
      30    ansible cible1 -b -m systemd -a "name=cron state=restarted"
      31    ansible all -a 'whoami'
      32    ansible cible1 -a 'whoami'
      33    ansible cible2 -a 'whoami'
      34    ansible all -ab 'whoami'
      35    ansible all -b -a 'whoami'
      36    ansible all -ba 'whoami'
      37    sudo vim nginx.yaml
      38    ansible-playbook nginx.yml
      39    ansible-playbook nginx.yaml
      40    sudo vim nginx.yaml
      41    ansible all -m service -a "name=apache2 state=status"
      42    ansible cible1 -bm shell -a "systemctl status cron"
      43    uname -a
      44    uname -r
      45    cat /etc/os-release
      46    lsb_release
      47    ansible all -a "cat /ho
      48    sudo vim shell.yml
      49    ansible all -a "cat /home/ansadmin/resultat.txt"
      50    ansible-playbook resultat.txt
      51    sudo vim shell.yml
      52    ansible-playbook /home/ansadmin/resultat.txt
      53    sudo vim shell.yml
      54    ansible-playbook shell.yml
      55    ansible all -a "cat /home/ansadmin/resultat.txt"
      56    sudo vim shell.yml
      57    ansible-playbook shell.yml
      58    sudo vim shell.yml
      59    ansible-playbook shell.yml
      60    sudo vim shell.yml
      61    ansible-playbook shell.yml
      62    ansible-playbook -b shell.yml
      63    ansible all -a "cat /home/ansadmin/resultat.txt"
      64    sudo vim handler.yaml
      65    sudo vim handler.yaml
      66    vim handler.yaml
      67    sudo vim when.yml
      68    history
ansadmin@svl200:~$ ls
cible1.txt    debug1.yaml    fact1.yaml        index.html    nginx.yaml    when.yaml
debug.yaml    fact.yaml        handler.yaml    ip.txt            shell.yml
ansadmin@svl200:~$ sudo vim debug1.yaml
ansadmin@svl200:~$ ansible-playbook -b debug1.yaml

PLAY [debug]
**********************************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]

TASK [show results]


***************************************************************************
ok: [146.59.158.16] => {
        "msg": "Le serveur Apache utilise par defaut le port 80 sur ma machine
Debian"
}

PLAY RECAP
************************************************************************************
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


****************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time": 1                                                               
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg::Op                                                                         
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                    
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd' h                                                                           
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation candi                                                                   
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informa                                                                       
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    ng                                                                   
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04.                                                                     
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs 1                                                           
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-http                                                               
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                            
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-lig                                                                           
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                      
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubuntu                                                                       
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserver                                                                   
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
...ignoring
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time":                                                                
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg::O                                                                           
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' failed:                                                                     
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd'                                                                              
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation cand                                                                   
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inform                                                                         
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n    n                                                                   
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.04                                                                       
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webfs                                                              
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-htt                                                               
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...",                                                                           
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-li                                                                             
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3", "                                                                       
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubunt                                                                       
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenserve                                                                   
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
...ignoring

TASK [install apache2 on ubuntu]


**************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=3      changed=0        unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=1
146.59.158.16                            : ok=3      changed=0        unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=1

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when1.yaml
ansadmin@svl200:~$ sudo rm when1.yaml
rm: cannot remove 'when1.yaml': No such file or directory
ansadmin@svl200:~$ sudo rm -f when1.yaml
ansadmin@svl200:~$ ls
cible1.txt    debug1.yaml    fact1.yaml        index.html    nginx.yaml    when.yaml
debug.yaml    fact.yaml        handler.yaml    ip.txt            shell.yml
ansadmin@svl200:~$ sudo cp when.yaml when1.yaml
ansadmin@svl200:~$ sudo vim when1.yaml
ansadmin@svl200:~$ ansible-playbook when1.yaml

PLAY [exemple avec condition when]


************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


****************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [install apache2 on ubuntu]


**************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim list.yaml


ansadmin@svl200:~$ ansible-playbook list.yaml

PLAY [exemple ansible list]


*******************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install package]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ ansible-playbook items.yaml

PLAY [exemple avec items]


*********************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


*********************************************************
changed: [146.59.158.16] => (item=init1.txt)
changed: [141.95.160.133] => (item=init1.txt)
changed: [146.59.158.16] => (item=init2.txt)
changed: [141.95.160.133] => (item=init2.txt)
changed: [146.59.158.16] => (item=init3.txt)
changed: [141.95.160.133] => (item=init3.txt)
changed: [146.59.158.16] => (item=init4.txt)
changed: [141.95.160.133] => (item=init4.txt)

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ ls
cible1.txt    debug1.yaml    fact1.yaml        index.html    items.yaml    nginx.yaml
when.yaml
debug.yaml    fact.yaml        handler.yaml    ip.txt            list.yaml     
shell.yml      when1.yaml
ansadmin@svl200:~$ ansible cible1 -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$ ansible cible1 -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$ ansible cible2 -bm shell -a "ls -lrt /home/ansadmin"
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$ ansible all -bma "ls -lrt /home/ansadmin"
usage: ansible [-h] [--version] [-v] [-b] [--become-method BECOME_METHOD]
                              [--become-user BECOME_USER] [-K] [-i INVENTORY] [--
list-hosts] [-l SUBSET]
                              [-P POLL_INTERVAL] [-B SECONDS] [-o] [-t TREE] [-k]
                              [--private-key PRIVATE_KEY_FILE] [-u REMOTE_USER] [-c
CONNECTION] [-T TIMEOUT]
                              [--ssh-common-args SSH_COMMON_ARGS] [--sftp-extra-args
SFTP_EXTRA_ARGS]
                              [--scp-extra-args SCP_EXTRA_ARGS] [--ssh-extra-args
SSH_EXTRA_ARGS] [-C]
                              [--syntax-check] [-D] [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                              [--ask-vault-pass | --vault-password-file
VAULT_PASSWORD_FILES] [-f FORKS]
                              [-M MODULE_PATH] [--playbook-dir BASEDIR] [-a
MODULE_ARGS] [-m MODULE_NAME]
                              pattern
ansible: error: unrecognized arguments: ls -lrt /home/ansadmin
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$ cp items.yaml seq.yaml
ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$ ansible-playbook seq.yaml

PLAY [exemple avec items]


*********************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


*********************************************************
changed: [146.59.158.16] => (item=20)
changed: [141.95.160.133] => (item=20)
changed: [146.59.158.16] => (item=21)
changed: [141.95.160.133] => (item=21)
changed: [146.59.158.16] => (item=22)
changed: [141.95.160.133] => (item=22)
changed: [146.59.158.16] => (item=23)
changed: [141.95.160.133] => (item=23)
changed: [146.59.158.16] => (item=24)
changed: [141.95.160.133] => (item=24)
changed: [146.59.158.16] => (item=25)
changed: [141.95.160.133] => (item=25)
changed: [146.59.158.16] => (item=26)
changed: [141.95.160.133] => (item=26)
changed: [146.59.158.16] => (item=27)
changed: [141.95.160.133] => (item=27)

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin"


146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | grep Dev"
146.59.158.16 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
141.95.160.133 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
ansadmin@svl200:~$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
──────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Mon Oct    3 17:50:31 2022 from 80.119.120.22
ofi03@svl200:~$
ofi03@svl200:~$ ansible all -bm group -a "name=rennes"
The authenticity of host '[146.59.158.16]:55600 ([146.59.158.16]:55600)' can't be
established.
ECDSA key fingerprint is SHA256:aQH+1UeVJklKq8A45Soa63iOGGkNRC/op7o5MgPiJtc.
The authenticity of host '[141.95.160.133]:55600 ([141.95.160.133]:55600)' can't be
established.
ECDSA key fingerprint is SHA256:XtY+kTiWN4Ohe3xBY3YAQ9YLSSuP7bbmxZjN/R9SBcs.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
146.59.158.16 | UNREACHABLE! => {
        "changed": false,
        "msg": "Failed to connect to the host via ssh: Warning: Permanently added
'[146.59.158.16]:55600' (ECDSA) to the list of known hosts.\r\[email protected]:
Permission denied (publ                                        ickey,password).",
        "unreachable": true
}
^C [ERROR]: User interrupted execution
ofi03@svl200:~$
ofi03@svl200:~$ ansible all -bm group -a "name=rennes"
The authenticity of host '[141.95.160.133]:55600 ([141.95.160.133]:55600)' can't be
established.
ECDSA key fingerprint is SHA256:XtY+kTiWN4Ohe3xBY3YAQ9YLSSuP7bbmxZjN/R9SBcs.
Are you sure you want to continue connecting (yes/no/[fingerprint])? 146.59.158.16 |
UNREACHABLE! => {
        "changed": false,
        "msg": "Failed to connect to the host via ssh: [email protected]:
Permission denied (publickey,password).",
        "unreachable": true
}
yes
141.95.160.133 | UNREACHABLE! => {
        "changed": false,
        "msg": "Failed to connect to the host via ssh: Warning: Permanently added
'[141.95.160.133]:55600' (ECDSA) to the list of known hosts.\r\[email protected]:
Permission denied (pu                                        blickey,password).",
        "unreachable": true
}
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | grep Dev"
146.59.158.16 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
141.95.160.133 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm group -a "name=rennes"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1008,
        "name": "rennes",
        "state": "present",
        "system": false
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1004,
        "name": "rennes",
        "state": "present",
        "system": false
}
ansadmin@svl200:~$ ansible all -bm group -a "name=lille"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1009,
        "name": "lille",
        "state": "present",
        "system": false
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1005,
        "name": "lille",
        "state": "present",
        "system": false
}
ansadmin@svl200:~$ ansible all -bm group -a "name=paris"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1010,
        "name": "paris",
        "state": "present",
        "system": false
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1006,
        "name": "paris",
        "state": "present",
        "system": false
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm user -a "name=core"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "comment": "",
        "create_home": true,
        "group": 1011,
        "home": "/home/core",
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "system": false,
        "uid": 1008
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "comment": "",
        "create_home": true,
        "group": 1007,
        "home": "/home/core",
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "system": false,
        "uid": 1004
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm user -a "name=core uid=10000"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "append": false,
        "changed": true,
        "comment": "",
        "group": 1011,
        "home": "/home/core",
        "move_home": false,
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "uid": 10000
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "append": false,
        "changed": true,
        "comment": "",
        "group": 1007,
        "home": "/home/core",
        "move_home": false,
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "uid": 10000
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm user -a "name=core groups=rennes"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "append": false,
        "changed": true,
        "comment": "",
        "group": 1011,
        "groups": "rennes",
        "home": "/home/core",
        "move_home": false,
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "uid": 10000
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "append": false,
        "changed": true,
        "comment": "",
        "group": 1007,
        "groups": "rennes",
        "home": "/home/core",
        "move_home": false,
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "uid": 10000
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm apt -a "name=tree state=latest"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "cache_update_time": 1664843277,
        "cache_updated": false,
        "changed": true,
        "stderr": "",
        "stderr_lines": [],
        "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state information...\nThe following NEW packages will be installed:\n    tree\n0
upgraded, 1 newly installed,                                        0 to remove and
0 not upgraded.\nNeed to get 43.0 kB of archives.\nAfter this operation, 115 kB of
additional disk space will be used.\nGet:1 http://nova.clouds.archive.ubuntu.com/ubun
tu focal/universe amd64 tree amd64 1.8.0-1 [43.0 kB]\nFetched 43.0 kB in 0s (133
kB/s)\nSelecting previously unselected package tree.\r\n(Reading database ... \
r(Reading database ... 5%                                        \r(Reading
database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\r(Reading
database ... 25%\r(Reading database ... 30%\r(Reading database ... 35%\r(Reading
database ...                                        40%\r(Reading database ... 45%\
r(Reading database ... 50%\r(Reading database ... 55%\r(Reading database ... 60%\
r(Reading database ... 65%\r(Reading database ... 70%\r(Reading database             
... 75%\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading database ...
90%\r(Reading database ... 95%\r(Reading database ... 100%\r(Reading database ...
97568 files and d                                        irectories currently
installed.)\r\nPreparing to unpack .../tree_1.8.0-1_amd64.deb ...\r\nUnpacking tree
(1.8.0-1) ...\r\nSetting up tree (1.8.0-1) ...\r\nProcessing triggers for man-db     
(2.9.1-1) ...\r\n",
        "stdout_lines": [
                "Reading package lists...",
                "Building dependency tree...",
                "Reading state information...",
                "The following NEW packages will be installed:",
                "    tree",
                "0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.",
                "Need to get 43.0 kB of archives.",
                "After this operation, 115 kB of additional disk space will be
used.",
                "Get:1 http://nova.clouds.archive.ubuntu.com/ubuntu focal/universe
amd64 tree amd64 1.8.0-1 [43.0 kB]",
                "Fetched 43.0 kB in 0s (133 kB/s)",
                "Selecting previously unselected package tree.",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97568 files and directories currently
installed.)",
                "Preparing to unpack .../tree_1.8.0-1_amd64.deb ...",
                "Unpacking tree (1.8.0-1) ...",
                "Setting up tree (1.8.0-1) ...",
                "Processing triggers for man-db (2.9.1-1) ..."
        ]
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "cache_update_time": 1664804313,
        "cache_updated": false,
        "changed": true,
        "stderr": "",
        "stderr_lines": [],
        "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state information...\nThe following NEW packages will be installed:\n    tree\n0
upgraded, 1 newly installed,                                        0 to remove and
18 not upgraded.\nNeed to get 43.0 kB of archives.\nAfter this operation, 115 kB of
additional disk space will be used.\nGet:1 http://nova.clouds.archive.ubuntu.com/ubu 
ntu focal/universe amd64 tree amd64 1.8.0-1 [43.0 kB]\nFetched 43.0 kB in 0s (129
kB/s)\nSelecting previously unselected package tree.\r\n(Reading database ... \
r(Reading database ... 5                                        %\r(Reading
database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\r(Reading
database ... 25%\r(Reading database ... 30%\r(Reading database ... 35%\r(Reading
database ..                                        . 40%\r(Reading database ... 45%\
r(Reading database ... 50%\r(Reading database ... 55%\r(Reading database ... 60%\
r(Reading database ... 65%\r(Reading database ... 70%\r(Reading databas             
e ... 75%\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading
database ... 90%\r(Reading database ... 95%\r(Reading database ... 100%\r(Reading
database ... 97537 files and                                         directories
currently installed.)\r\nPreparing to unpack .../tree_1.8.0-1_amd64.deb ...\r\
nUnpacking tree (1.8.0-1) ...\r\nSetting up tree (1.8.0-1) ...\r\nProcessing triggers
for man-d                                        b (2.9.1-1) ...\r\n",
        "stdout_lines": [
                "Reading package lists...",
                "Building dependency tree...",
                "Reading state information...",
                "The following NEW packages will be installed:",
                "    tree",
                "0 upgraded, 1 newly installed, 0 to remove and 18 not upgraded.",
                "Need to get 43.0 kB of archives.",
                "After this operation, 115 kB of additional disk space will be
used.",
                "Get:1 http://nova.clouds.archive.ubuntu.com/ubuntu focal/universe
amd64 tree amd64 1.8.0-1 [43.0 kB]",
                "Fetched 43.0 kB in 0s (129 kB/s)",
                "Selecting previously unselected package tree.",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97537 files and directories currently
installed.)",
                "Preparing to unpack .../tree_1.8.0-1_amd64.deb ...",
                "Unpacking tree (1.8.0-1) ...",
                "Setting up tree (1.8.0-1) ...",
                "Processing triggers for man-db (2.9.1-1) ..."
        ]
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm service -a "name=cron state=stopped"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "name": "cron",
        "state": "stopped",
        "status": {
                "ActiveEnterTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ActiveEnterTimestampMonotonic": "3297087651422",
                "ActiveExitTimestamp": "Mon 2022-10-03 12:11:21 UTC",
                "ActiveExitTimestampMonotonic": "3297037132653",
                "ActiveState": "active",
                "After": "nss-user-lookup.target system.slice systemd-journald.socket
remote-fs.target sysinit.target basic.target",
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "AssertTimestampMonotonic": "3297087645970",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "no",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_fowner cap_fsetid cap_kill cap_setgid cap_setuid cap_setpcap
cap_linux_immutable cap_net_bind_servic                                        e
cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner cap_sys_module
cap_sys_rawio cap_sys_chroot cap_sys_ptrace cap_sys_pacct cap_sys_admin cap_sys_boot
cap_sys_nice                                        cap_sys_resource cap_sys_time
cap_sys_tty_config cap_mknod cap_lease cap_audit_write cap_audit_control cap_setfcap
cap_mac_override cap_mac_admin cap_syslog cap_wake_alarm cap_block_su               
spend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ConditionTimestampMonotonic": "3297087645969",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlGroup": "/system.slice/cron.service",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "Regular background program processing daemon",
                "DevicePolicy": "auto",
                "Documentation": "man:cron(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "EnvironmentFiles": "/etc/default/cron (ignore_errors=yes)",
                "ExecMainCode": "0",
                "ExecMainExitTimestampMonotonic": "0",
                "ExecMainPID": "253639",
                "ExecMainStartTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ExecMainStartTimestampMonotonic": "3297087647720",
                "ExecMainStatus": "0",
                "ExecStart": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; ignore_errors=no ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
code=(null) ; status=0/0 }",
                "ExecStartEx": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; flags= ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ; code=(null) ;
status=0/0 }",
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/cron.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "cron.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "no",
                "InactiveEnterTimestamp": "Mon 2022-10-03 12:11:21 UTC",
                "InactiveEnterTimestampMonotonic": "3297037133883",
                "InactiveExitTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "InactiveExitTimestampMonotonic": "3297087651422",
                "InvocationID": "1146685551e74a078e22588cc853b8b0",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "process",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "253639",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "2965504",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "cron.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "system.slice sysinit.target",
                "Restart": "on-failure",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "StateChangeTimestampMonotonic": "3297087651422",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "running",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "1",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "1min 30s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "1min 30s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "simple",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "name": "cron",
        "state": "stopped",
        "status": {
                "ActiveEnterTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ActiveEnterTimestampMonotonic": "15934843",
                "ActiveExitTimestampMonotonic": "0",
                "ActiveState": "active",
                "After": "nss-user-lookup.target basic.target sysinit.target systemd-
journald.socket remote-fs.target system.slice",
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "AssertTimestampMonotonic": "15930137",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "no",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_fowner cap_fsetid cap_kill cap_setgid cap_setuid cap_setpcap
cap_linux_immutable cap_net_bind_servic                                        e
cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner cap_sys_module
cap_sys_rawio cap_sys_chroot cap_sys_ptrace cap_sys_pacct cap_sys_admin cap_sys_boot
cap_sys_nice                                        cap_sys_resource cap_sys_time
cap_sys_tty_config cap_mknod cap_lease cap_audit_write cap_audit_control cap_setfcap
cap_mac_override cap_mac_admin cap_syslog cap_wake_alarm cap_block_su               
spend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ConditionTimestampMonotonic": "15930135",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlGroup": "/system.slice/cron.service",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "Regular background program processing daemon",
                "DevicePolicy": "auto",
                "Documentation": "man:cron(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "EnvironmentFiles": "/etc/default/cron (ignore_errors=yes)",
                "ExecMainCode": "0",
                "ExecMainExitTimestampMonotonic": "0",
                "ExecMainPID": "679",
                "ExecMainStartTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ExecMainStartTimestampMonotonic": "15934762",
                "ExecMainStatus": "0",
                "ExecStart": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; ignore_errors=no ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
code=(null) ; status=0/0 }",
                "ExecStartEx": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; flags= ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ; code=(null) ;
status=0/0 }",
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/cron.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "cron.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "no",
                "InactiveEnterTimestampMonotonic": "0",
                "InactiveExitTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "InactiveExitTimestampMonotonic": "15934843",
                "InvocationID": "dcee66e33a3a4a47a8ce4148d9734e2f",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "process",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "679",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "6848512",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "cron.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "sysinit.target system.slice",
                "Restart": "on-failure",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "StateChangeTimestampMonotonic": "15934843",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "running",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "1",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "1min 30s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "1min 30s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "simple",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm service -a "name=cron state=disabled"
146.59.158.16 | FAILED! => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false,
        "msg": "value of state must be one of: reloaded, restarted, started, stopped,
got: disabled"
}
141.95.160.133 | FAILED! => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false,
        "msg": "value of state must be one of: reloaded, restarted, started, stopped,
got: disabled"
}
ansadmin@svl200:~$ ansible all -bm service -a "name=cron enabled=no"
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "enabled": false,
        "name": "cron",
        "status": {
                "ActiveEnterTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ActiveEnterTimestampMonotonic": "15934843",
                "ActiveExitTimestamp": "Tue 2022-10-04 08:09:19 UTC",
                "ActiveExitTimestampMonotonic": "1719968363076",
                "ActiveState": "inactive",
                "After": "nss-user-lookup.target basic.target sysinit.target systemd-
journald.socket remote-fs.target system.slice",
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "AssertTimestampMonotonic": "15930137",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "no",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_fowner cap_fsetid cap_kill cap_setgid cap_setuid cap_setpcap
cap_linux_immutable cap_net_bind_servic                                        e
cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner cap_sys_module
cap_sys_rawio cap_sys_chroot cap_sys_ptrace cap_sys_pacct cap_sys_admin cap_sys_boot
cap_sys_nice                                        cap_sys_resource cap_sys_time
cap_sys_tty_config cap_mknod cap_lease cap_audit_write cap_audit_control cap_setfcap
cap_mac_override cap_mac_admin cap_syslog cap_wake_alarm cap_block_su               
spend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ConditionTimestampMonotonic": "15930135",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "Regular background program processing daemon",
                "DevicePolicy": "auto",
                "Documentation": "man:cron(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "EnvironmentFiles": "/etc/default/cron (ignore_errors=yes)",
                "ExecMainCode": "2",
                "ExecMainExitTimestamp": "Tue 2022-10-04 08:09:19 UTC",
                "ExecMainExitTimestampMonotonic": "1719968363869",
                "ExecMainPID": "679",
                "ExecMainStartTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ExecMainStartTimestampMonotonic": "15934762",
                "ExecMainStatus": "15",
                "ExecStart": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; ignore_errors=no ; start_time=[Wed 2022-09-14 10:23:26 UTC] ;
stop_time=[Tue 2022-10-04 08:09:19 UTC                                        ] ;
pid=679 ; code=killed ; status=15/TERM }",
                "ExecStartEx": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; flags= ; start_time=[Wed 2022-09-14 10:23:26 UTC] ; stop_time=[Tue
2022-10-04 08:09:19 UTC] ; pid=                                        679 ;
code=killed ; status=15/TERM }",
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/cron.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "cron.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "no",
                "InactiveEnterTimestamp": "Tue 2022-10-04 08:09:19 UTC",
                "InactiveEnterTimestampMonotonic": "1719968363887",
                "InactiveExitTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "InactiveExitTimestampMonotonic": "15934843",
                "InvocationID": "dcee66e33a3a4a47a8ce4148d9734e2f",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "process",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "0",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "[not set]",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "cron.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "sysinit.target system.slice",
                "Restart": "on-failure",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Tue 2022-10-04 08:09:19 UTC",
                "StateChangeTimestampMonotonic": "1719968363887",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "dead",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "[not set]",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "1min 30s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "1min 30s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "simple",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "enabled": false,
        "name": "cron",
        "status": {
                "ActiveEnterTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ActiveEnterTimestampMonotonic": "3297087651422",
                "ActiveExitTimestamp": "Tue 2022-10-04 08:09:18 UTC",
                "ActiveExitTimestampMonotonic": "3368914737265",
                "ActiveState": "inactive",
                "After": "nss-user-lookup.target system.slice systemd-journald.socket
remote-fs.target sysinit.target basic.target",
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "AssertTimestampMonotonic": "3297087645970",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "no",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_fowner cap_fsetid cap_kill cap_setgid cap_setuid cap_setpcap
cap_linux_immutable cap_net_bind_servic                                        e
cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner cap_sys_module
cap_sys_rawio cap_sys_chroot cap_sys_ptrace cap_sys_pacct cap_sys_admin cap_sys_boot
cap_sys_nice                                        cap_sys_resource cap_sys_time
cap_sys_tty_config cap_mknod cap_lease cap_audit_write cap_audit_control cap_setfcap
cap_mac_override cap_mac_admin cap_syslog cap_wake_alarm cap_block_su               
spend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ConditionTimestampMonotonic": "3297087645969",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "Regular background program processing daemon",
                "DevicePolicy": "auto",
                "Documentation": "man:cron(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "EnvironmentFiles": "/etc/default/cron (ignore_errors=yes)",
                "ExecMainCode": "2",
                "ExecMainExitTimestamp": "Tue 2022-10-04 08:09:18 UTC",
                "ExecMainExitTimestampMonotonic": "3368914738115",
                "ExecMainPID": "253639",
                "ExecMainStartTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ExecMainStartTimestampMonotonic": "3297087647720",
                "ExecMainStatus": "15",
                "ExecStart": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; ignore_errors=no ; start_time=[Mon 2022-10-03 12:12:11 UTC] ;
stop_time=[Tue 2022-10-04 08:09:18 UTC                                        ] ;
pid=253639 ; code=killed ; status=15/TERM }",
                "ExecStartEx": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; flags= ; start_time=[Mon 2022-10-03 12:12:11 UTC] ; stop_time=[Tue
2022-10-04 08:09:18 UTC] ; pid=                                        253639 ;
code=killed ; status=15/TERM }",
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/cron.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "cron.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "no",
                "InactiveEnterTimestamp": "Tue 2022-10-04 08:09:18 UTC",
                "InactiveEnterTimestampMonotonic": "3368914738600",
                "InactiveExitTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "InactiveExitTimestampMonotonic": "3297087651422",
                "InvocationID": "1146685551e74a078e22588cc853b8b0",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "process",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "0",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "[not set]",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "cron.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "system.slice sysinit.target",
                "Restart": "on-failure",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Tue 2022-10-04 08:09:18 UTC",
                "StateChangeTimestampMonotonic": "3368914738600",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "dead",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "[not set]",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "1min 30s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "1min 30s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "simple",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -m file -a "path=/tmp/test.txt state=touch mode=0644"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "dest": "/tmp/test.txt",
        "gid": 1006,
        "group": "ansadmin",
        "mode": "0644",
        "owner": "ansadmin",
        "size": 0,
        "state": "file",
        "uid": 1006
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "dest": "/tmp/test.txt",
        "gid": 1003,
        "group": "ansadmin",
        "mode": "0644",
        "owner": "ansadmin",
        "size": 0,
        "state": "file",
        "uid": 1003
}
ansadmin@svl200:~$ ansible all -m shell -a "ls -lrt /tmp/test.txt | grep test"
141.95.160.133 | CHANGED | rc=0 >>
-rw-r--r-- 1 ansadmin ansadmin 0 Oct    4 08:16 /tmp/test.txt
146.59.158.16 | CHANGED | rc=0 >>
-rw-r--r-- 1 ansadmin ansadmin 0 Oct    4 08:16 /tmp/test.txt
ansadmin@svl200:~$ ansible all -m shell -a "ls -lrt /tmp | grep test"
146.59.158.16 | CHANGED | rc=0 >>
-rw-r--r-- 1 ansadmin ansadmin        0 Oct    4 08:16 test.txt
141.95.160.133 | CHANGED | rc=0 >>
-rw-r--r-- 1 ansadmin ansadmin        0 Oct    4 08:16 test.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -m directory -a "path=/tmp/dir state= mode=755"
146.59.158.16 | FAILED! => {
        "msg": "The module directory was not found in configured module paths"
}
141.95.160.133 | FAILED! => {
        "msg": "The module directory was not found in configured module paths"
}
ansadmin@svl200:~$ ansible all -m dir -a "path=/tmp/dir state= mode=755"
141.95.160.133 | FAILED! => {
        "msg": "The module dir was not found in configured module paths"
}
146.59.158.16 | FAILED! => {
        "msg": "The module dir was not found in configured module paths"
}
ansadmin@svl200:~$ ansible all -m file -a "path=/tmp/dir state=directory    mode=755"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1006,
        "group": "ansadmin",
        "mode": "0755",
        "owner": "ansadmin",
        "path": "/tmp/dir",
        "size": 4096,
        "state": "directory",
        "uid": 1006
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1003,
        "group": "ansadmin",
        "mode": "0755",
        "owner": "ansadmin",
        "path": "/tmp/dir",
        "size": 4096,
        "state": "directory",
        "uid": 1003
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm apt -a "name=* state=latest"
146.59.158.16 | SUCCESS => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false,
        "msg": "Reading package lists...\nBuilding dependency tree...\nReading state
information...\nCalculating upgrade...\n0 upgraded, 0 newly installed, 0 to remove
and 0 not upgraded.\n                                        ",
        "stderr": "",
        "stderr_lines": [],
        "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state information...\nCalculating upgrade...\n0 upgraded, 0 newly installed, 0 to
remove and 0 not upgraded                                        .\n",
        "stdout_lines": [
                "Reading package lists...",
                "Building dependency tree...",
                "Reading state information...",
                "Calculating upgrade...",
                "0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded."
        ]
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "msg": "Reading package lists...\nBuilding dependency tree...\nReading state
information...\nCalculating upgrade...\nThe following packages will be upgraded:\n   
base-files libnetpla                                        n0 libnss-systemd libpam-
systemd libsystemd0\n    libtss2-esys0 libudev1 motd-news-config netplan.io python-
apt-common\n    python3-apt python3-distupgrade systemd systemd-sysv systemd-time   
syncd\n    ubuntu-advantage-tools ubuntu-release-upgrader-core udev\n18 upgraded, 0
newly installed, 0 to remove and 0 not upgraded.\nNeed to get 6747 kB of archives.\
nAfter this operatio                                        n, 2594 kB disk space
will be freed.\nGet:1 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main
amd64 motd-news-config all 11ubuntu5.6 [4348 B]\nGet:2 http://nova.clouds.arc       
hive.ubuntu.com/ubuntu focal-updates/main amd64 base-files amd64 11ubuntu5.6 [60.4
kB]\nGet:3 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
libnss-systemd amd64                                         245.4-4ubuntu3.18 [96.1
kB]\nGet:4 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 udev
amd64 245.4-4ubuntu3.18 [1367 kB]\nGet:5 http://nova.clouds.archive.ubuntu.         
com/ubuntu focal-updates/main amd64 libudev1 amd64 245.4-4ubuntu3.18 [76.3 kB]\nGet:6
http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 systemd-sysv
amd64 245.4-4ubu                                        ntu3.18 [10.3 kB]\nGet:7
http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 systemd-
timesyncd amd64 245.4-4ubuntu3.18 [28.1 kB]\nGet:8 http://nova.clouds.archive.ubun   
tu.com/ubuntu focal-updates/main amd64 libpam-systemd amd64 245.4-4ubuntu3.18 [186
kB]\nGet:9 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
systemd amd64 245.4-4                                        ubuntu3.18 [3808 kB]\
nGet:10 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
libsystemd0 amd64 245.4-4ubuntu3.18 [269 kB]\nGet:11
http://nova.clouds.archive.ubuntu                                        .com/ubuntu
focal-updates/main amd64 netplan.io amd64 0.104-0ubuntu2~20.04.2 [88.0 kB]\nGet:12
http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 libnetplan0
amd64 0.                                        104-0ubuntu2~20.04.2 [82.5 kB]\
nGet:13 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 python-
apt-common all 2.0.0ubuntu0.20.04.8 [17.1 kB]\nGet:14 http://nova.clo               
uds.archive.ubuntu.com/ubuntu focal-updates/main amd64 python3-apt amd64
2.0.0ubuntu0.20.04.8 [154 kB]\nGet:15 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 ubun                                        tu-advantage-
tools amd64 27.10.1~20.04.1 [146 kB]\nGet:16
http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 ubuntu-release-
upgrader-core all 1:20.04.39 [24.4 kB]\nGe                                       
t:17 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 python3-
distupgrade all 1:20.04.39 [104 kB]\nGet:18
http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates                           
/main amd64 libtss2-esys0 amd64 2.3.2-1ubuntu0.20.04.1 [226 kB]\nPreconfiguring
packages ...\nFetched 6747 kB in 1s (6785 kB/s)\n(Reading database ... \r(Reading
database ... 5%\r(Readi                                        ng database ... 10%\
r(Reading database ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\
r(Reading database ... 30%\r(Reading database ... 35%\r(Reading database ... 40%\r(R 
eading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Reading database ... 60%\r(Reading database ... 65%\r(Reading database ... 70%\
r(Reading database ... 75%                                        \r(Reading database
... 80%\r(Reading database ... 85%\r(Reading database ... 90%\r(Reading database ...
95%\r(Reading database ... 100%\r(Reading database ... 97544 files and directori     
es currently installed.)\r\nPreparing to unpack .../motd-news-
config_11ubuntu5.6_all.deb ...\r\nUnpacking motd-news-config (11ubuntu5.6) over
(11ubuntu5.5) ...\r\nPreparing to unpack ..                                       
./base-files_11ubuntu5.6_amd64.deb ...\r\nWarning: Stopping motd-news.service, but it
can still be activated by:\r\n    motd-news.timer\r\nUnpacking base-files
(11ubuntu5.6) over (11ubunt                                        u5.5) ...\r\
nSetting up base-files (11ubuntu5.6) ...\r\nInstalling new version of config file
/etc/issue ...\r\nInstalling new version of config file /etc/issue.net ...\r\
nInstalling ne                                        w version of config file
/etc/lsb-release ...\r\nmotd-news.service is a disabled or a static unit, not
starting it.\r\n(Reading database ... \r(Reading database ... 5%\r(Reading databas   
e ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\r(Reading
database ... 25%\r(Reading database ... 30%\r(Reading database ... 35%\r(Reading
database ... 40%\r(Reading dat                                        abase ... 45%\
r(Reading database ... 50%\r(Reading database ... 55%\r(Reading database ... 60%\
r(Reading database ... 65%\r(Reading database ... 70%\r(Reading database ... 75%\
r(Reading                                        database ... 80%\r(Reading database
... 85%\r(Reading database ... 90%\r(Reading database ... 95%\r(Reading database ...
100%\r(Reading database ... 97544 files and directories current                     
ly installed.)\r\nPreparing to unpack .../libnss-systemd_245.4-
4ubuntu3.18_amd64.deb ...\r\nUnpacking libnss-systemd:amd64 (245.4-4ubuntu3.18) over
(245.4-4ubuntu3.17) ...\r\nPreparing                                         to
unpack .../udev_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking udev (245.4-4ubuntu3.18)
over (245.4-4ubuntu3.17) ...\r\nPreparing to unpack .../libudev1_245.4-
4ubuntu3.18_amd64.deb ...                                        \r\nUnpacking
libudev1:amd64 (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nSetting up
libudev1:amd64 (245.4-4ubuntu3.18) ...\r\n(Reading database ... \r(Reading
database ... 5%\r(                                        Reading database ... 10%\
r(Reading database ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\
r(Reading database ... 30%\r(Reading database ... 35%\r(Reading database ... 40     
%\r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Reading database ... 60%\r(Reading database ... 65%\r(Reading database ... 70%\
r(Reading database ..                                        . 75%\r(Reading database
... 80%\r(Reading database ... 85%\r(Reading database ... 90%\r(Reading database ...
95%\r(Reading database ... 100%\r(Reading database ... 97544 files and dire         
ctories currently installed.)\r\nPreparing to unpack .../systemd-sysv_245.4-
4ubuntu3.18_amd64.deb ...\r\nUnpacking systemd-sysv (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...\r\nPrepa                                        ring to unpack
.../systemd-timesyncd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking systemd-timesyncd
(245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPreparing to unpack .../libpam-sy
stemd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking libpam-systemd:amd64 (245.4-
4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPreparing to unpack .../systemd_245.4-
4ubuntu3.18_amd64.deb .                                        ..\r\nUnpacking
systemd (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPreparing to unpack
.../libsystemd0_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking libsystemd0:amd64
(245.4-4ub                                        untu3.18) over (245.4-
4ubuntu3.17) ...\r\nSetting up libsystemd0:amd64 (245.4-4ubuntu3.18) ...\r\n(Reading
database ... \r(Reading database ... 5%\r(Reading database ... 10%\r(Reading d       
atabase ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\r(Reading
database ... 30%\r(Reading database ... 35%\r(Reading database ... 40%\r(Reading
database ... 45%\r(Readi                                        ng database ... 50%\
r(Reading database ... 55%\r(Reading database ... 60%\r(Reading database ... 65%\
r(Reading database ... 70%\r(Reading database ... 75%\r(Reading database ... 80%\r(R 
eading database ... 85%\r(Reading database ... 90%\r(Reading database ... 95%\
r(Reading database ... 100%\r(Reading database ... 97544 files and directories
currently installed.)\r\nPre                                        paring to
unpack .../0-netplan.io_0.104-0ubuntu2~20.04.2_amd64.deb ...\r\nUnpacking netplan.io
(0.104-0ubuntu2~20.04.2) over (0.104-0ubuntu2~20.04.1) ...\r\nPreparing to
unpack .../1-li                                        bnetplan0_0.104-
0ubuntu2~20.04.2_amd64.deb ...\r\nUnpacking libnetplan0:amd64 (0.104-
0ubuntu2~20.04.2) over (0.104-0ubuntu2~20.04.1) ...\r\nPreparing to unpack .../2-
python-apt-common_2                                       
.0.0ubuntu0.20.04.8_all.deb ...\r\nUnpacking python-apt-common (2.0.0ubuntu0.20.04.8)
over (2.0.0ubuntu0.20.04.7) ...\r\nPreparing to unpack .../3-python3-
apt_2.0.0ubuntu0.20.04.8_amd64                                        .deb ...\r\
nUnpacking python3-apt (2.0.0ubuntu0.20.04.8) over (2.0.0ubuntu0.20.04.7) ...\r\
nPreparing to unpack .../4-ubuntu-advantage-tools_27.10.1~20.04.1_amd64.deb ...\r\
nUnpacking u                                        buntu-advantage-tools
(27.10.1~20.04.1) over (27.9~20.04.1) ...\r\nPreparing to unpack .../5-ubuntu-
release-upgrader-core_1%3a20.04.39_all.deb ...\r\nUnpacking ubuntu-release-upgrader-c
ore (1:20.04.39) over (1:20.04.38) ...\r\nPreparing to unpack .../6-python3-
distupgrade_1%3a20.04.39_all.deb ...\r\nUnpacking python3-distupgrade (1:20.04.39)
over (1:20.04.38) ...\r\nP                                        reparing to
unpack .../7-libtss2-esys0_2.3.2-1ubuntu0.20.04.1_amd64.deb ...\r\nUnpacking libtss2-
esys0 (2.3.2-1ubuntu0.20.04.1) over (2.3.2-1) ...\r\nSetting up motd-news-config
(11ubun                                        tu5.6) ...\r\nSetting up libtss2-esys0
(2.3.2-1ubuntu0.20.04.1) ...\r\nSetting up libnetplan0:amd64 (0.104-0ubuntu2~20.04.2)
...\r\nSetting up udev (245.4-4ubuntu3.18) ...\r\nupdate-ini                         
tramfs: deferring update (trigger activated)\r\nSetting up python-apt-common
(2.0.0ubuntu0.20.04.8) ...\r\nSetting up python3-apt (2.0.0ubuntu0.20.04.8) ...\r\
nSetting up python3-distup                                        grade
(1:20.04.39) ...\r\nSetting up ubuntu-release-upgrader-core (1:20.04.39) ...\r\
nSetting up ubuntu-advantage-tools (27.10.1~20.04.1) ...\r\nSetting up systemd
(245.4-4ubuntu3.18) .                                        ..\r\nSetting up
netplan.io (0.104-0ubuntu2~20.04.2) ...\r\nSetting up systemd-timesyncd (245.4-
4ubuntu3.18) ...\r\nSetting up systemd-sysv (245.4-4ubuntu3.18) ...\r\nSetting up
libnss-                                        systemd:amd64 (245.4-4ubuntu3.18) ...\
r\nSetting up libpam-systemd:amd64 (245.4-4ubuntu3.18) ...\r\nProcessing triggers for
install-info (6.7.0.dfsg.2-5) ...\r\nProcessing triggers for                        
libc-bin (2.31-0ubuntu9.9) ...\r\nProcessing triggers for man-db (2.9.1-1) ...\r\
nProcessing triggers for plymouth-theme-ubuntu-text (0.9.4git20200323-
0ubuntu6.2) ...\r\nupdate-initramf                                        s:
deferring update (trigger activated)\r\nProcessing triggers for dbus (1.12.16-
2ubuntu2.2) ...\r\nProcessing triggers for initramfs-tools (0.136ubuntu6.7) ...\r\
nupdate-initramfs: Gen                                        erating
/boot/initrd.img-5.4.0-126-generic\r\n",
        "stderr": "",
        "stderr_lines": [],
        "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state information...\nCalculating upgrade...\nThe following packages will be
upgraded:\n    base-files libnet                                        plan0 libnss-
systemd libpam-systemd libsystemd0\n    libtss2-esys0 libudev1 motd-news-config
netplan.io python-apt-common\n    python3-apt python3-distupgrade systemd systemd-
sysv systemd-t                                        imesyncd\n    ubuntu-advantage-
tools ubuntu-release-upgrader-core udev\n18 upgraded, 0 newly installed, 0 to remove
and 0 not upgraded.\nNeed to get 6747 kB of archives.\nAfter this opera             
tion, 2594 kB disk space will be freed.\nGet:1
http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 motd-news-
config all 11ubuntu5.6 [4348 B]\nGet:2 http://nova.clouds.                           
archive.ubuntu.com/ubuntu focal-updates/main amd64 base-files amd64 11ubuntu5.6 [60.4
kB]\nGet:3 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
libnss-systemd amd                                        64 245.4-4ubuntu3.18 [96.1
kB]\nGet:4 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 udev
amd64 245.4-4ubuntu3.18 [1367 kB]\nGet:5 http://nova.clouds.archive.ubun             
tu.com/ubuntu focal-updates/main amd64 libudev1 amd64 245.4-4ubuntu3.18 [76.3 kB]\
nGet:6 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 systemd-
sysv amd64 245.4-4                                        ubuntu3.18 [10.3 kB]\nGet:7
http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 systemd-
timesyncd amd64 245.4-4ubuntu3.18 [28.1 kB]\nGet:8 http://nova.clouds.archive.u     
buntu.com/ubuntu focal-updates/main amd64 libpam-systemd amd64 245.4-4ubuntu3.18 [186
kB]\nGet:9 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
systemd amd64 245.                                        4-4ubuntu3.18 [3808 kB]\
nGet:10 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
libsystemd0 amd64 245.4-4ubuntu3.18 [269 kB]\nGet:11 http://nova.clouds.archive.ubu 
ntu.com/ubuntu focal-updates/main amd64 netplan.io amd64 0.104-0ubuntu2~20.04.2 [88.0
kB]\nGet:12 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
libnetplan0 amd64                                        0.104-0ubuntu2~20.04.2
[82.5 kB]\nGet:13 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main
amd64 python-apt-common all 2.0.0ubuntu0.20.04.8 [17.1 kB]\nGet:14 http://nova.     
clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 python3-apt amd64
2.0.0ubuntu0.20.04.8 [154 kB]\nGet:15 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 u                                        buntu-advantage-
tools amd64 27.10.1~20.04.1 [146 kB]\nGet:16
http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 ubuntu-release-
upgrader-core all 1:20.04.39 [24.4 kB]\                                       
nGet:17 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
python3-distupgrade all 1:20.04.39 [104 kB]\nGet:18
http://nova.clouds.archive.ubuntu.com/ubuntu focal-upda                             
tes/main amd64 libtss2-esys0 amd64 2.3.2-1ubuntu0.20.04.1 [226 kB]\nPreconfiguring
packages ...\nFetched 6747 kB in 1s (6785 kB/s)\n(Reading database ... \r(Reading
database ... 5%\r(Re                                        ading database ... 10%\
r(Reading database ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\
r(Reading database ... 30%\r(Reading database ... 35%\r(Reading database ... 40%\   
r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Reading database ... 60%\r(Reading database ... 65%\r(Reading database ... 70%\
r(Reading database ...                                         75%\r(Reading database
... 80%\r(Reading database ... 85%\r(Reading database ... 90%\r(Reading database ...
95%\r(Reading database ... 100%\r(Reading database ... 97544 files and direct       
ories currently installed.)\r\nPreparing to unpack .../motd-news-
config_11ubuntu5.6_all.deb ...\r\nUnpacking motd-news-config (11ubuntu5.6) over
(11ubuntu5.5) ...\r\nPreparing to unpack                                       
.../base-files_11ubuntu5.6_amd64.deb ...\r\nWarning: Stopping motd-news.service, but
it can still be activated by:\r\n    motd-news.timer\r\nUnpacking base-files
(11ubuntu5.6) over (11ub                                        untu5.5) ...\r\
nSetting up base-files (11ubuntu5.6) ...\r\nInstalling new version of config file
/etc/issue ...\r\nInstalling new version of config file /etc/issue.net ...\r\
nInstalling                                        new version of config file
/etc/lsb-release ...\r\nmotd-news.service is a disabled or a static unit, not
starting it.\r\n(Reading database ... \r(Reading database ... 5%\r(Reading data     
base ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\r(Reading database
... 25%\r(Reading database ... 30%\r(Reading database ... 35%\r(Reading database ...
40%\r(Reading                                         database ... 45%\r(Reading
database ... 50%\r(Reading database ... 55%\r(Reading database ... 60%\r(Reading
database ... 65%\r(Reading database ... 70%\r(Reading database ... 75%\r(Read       
ing database ... 80%\r(Reading database ... 85%\r(Reading database ... 90%\r(Reading
database ... 95%\r(Reading database ... 100%\r(Reading database ... 97544 files and
directories curr                                        ently installed.)\r\
nPreparing to unpack .../libnss-systemd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking
libnss-systemd:amd64 (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPrepari     
ng to unpack .../udev_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking udev (245.4-
4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPreparing to unpack .../libudev1_245.4-
4ubuntu3.18_amd64.deb                                         ...\r\nUnpacking
libudev1:amd64 (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nSetting up
libudev1:amd64 (245.4-4ubuntu3.18) ...\r\n(Reading database ... \r(Reading
database ... 5%                                        \r(Reading database ... 10%\
r(Reading database ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\
r(Reading database ... 30%\r(Reading database ... 35%\r(Reading database ...         
40%\r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Reading database ... 60%\r(Reading database ... 65%\r(Reading database ... 70%\
r(Reading database                                        ... 75%\r(Reading database
... 80%\r(Reading database ... 85%\r(Reading database ... 90%\r(Reading database ...
95%\r(Reading database ... 100%\r(Reading database ... 97544 files and d             
irectories currently installed.)\r\nPreparing to unpack .../systemd-sysv_245.4-
4ubuntu3.18_amd64.deb ...\r\nUnpacking systemd-sysv (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...\r\nPr                                        eparing to unpack
.../systemd-timesyncd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking systemd-timesyncd
(245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPreparing to unpack .../libpam   
-systemd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking libpam-systemd:amd64 (245.4-
4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPreparing to unpack .../systemd_245.4-
4ubuntu3.18_amd64.de                                        b ...\r\nUnpacking
systemd (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPreparing to unpack
.../libsystemd0_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking libsystemd0:amd64
(245.4-                                        4ubuntu3.18) over (245.4-
4ubuntu3.17) ...\r\nSetting up libsystemd0:amd64 (245.4-4ubuntu3.18) ...\r\n(Reading
database ... \r(Reading database ... 5%\r(Reading database ... 10%\r(Readin         
g database ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\r(Reading
database ... 30%\r(Reading database ... 35%\r(Reading database ... 40%\r(Reading
database ... 45%\r(Re                                        ading database ... 50%\
r(Reading database ... 55%\r(Reading database ... 60%\r(Reading database ... 65%\
r(Reading database ... 70%\r(Reading database ... 75%\r(Reading database ... 80%\   
r(Reading database ... 85%\r(Reading database ... 90%\r(Reading database ... 95%\
r(Reading database ... 100%\r(Reading database ... 97544 files and directories
currently installed.)\r\n                                        Preparing to
unpack .../0-netplan.io_0.104-0ubuntu2~20.04.2_amd64.deb ...\r\nUnpacking netplan.io
(0.104-0ubuntu2~20.04.2) over (0.104-0ubuntu2~20.04.1) ...\r\nPreparing to
unpack .../1                                        -libnetplan0_0.104-
0ubuntu2~20.04.2_amd64.deb ...\r\nUnpacking libnetplan0:amd64 (0.104-
0ubuntu2~20.04.2) over (0.104-0ubuntu2~20.04.1) ...\r\nPreparing to unpack .../2-
python-apt-commo                                       
n_2.0.0ubuntu0.20.04.8_all.deb ...\r\nUnpacking python-apt-common
(2.0.0ubuntu0.20.04.8) over (2.0.0ubuntu0.20.04.7) ...\r\nPreparing to unpack .../3-
python3-apt_2.0.0ubuntu0.20.04.8_am                                       
d64.deb ...\r\nUnpacking python3-apt (2.0.0ubuntu0.20.04.8) over
(2.0.0ubuntu0.20.04.7) ...\r\nPreparing to unpack .../4-ubuntu-advantage-
tools_27.10.1~20.04.1_amd64.deb ...\r\nUnpackin                                     
g ubuntu-advantage-tools (27.10.1~20.04.1) over (27.9~20.04.1) ...\r\nPreparing to
unpack .../5-ubuntu-release-upgrader-core_1%3a20.04.39_all.deb ...\r\nUnpacking
ubuntu-release-upgrade                                        r-core (1:20.04.39)
over (1:20.04.38) ...\r\nPreparing to unpack .../6-python3-
distupgrade_1%3a20.04.39_all.deb ...\r\nUnpacking python3-distupgrade (1:20.04.39)
over (1:20.04.38) ...\r                                        \nPreparing to
unpack .../7-libtss2-esys0_2.3.2-1ubuntu0.20.04.1_amd64.deb ...\r\nUnpacking libtss2-
esys0 (2.3.2-1ubuntu0.20.04.1) over (2.3.2-1) ...\r\nSetting up motd-news-config (11u
buntu5.6) ...\r\nSetting up libtss2-esys0 (2.3.2-1ubuntu0.20.04.1) ...\r\nSetting up
libnetplan0:amd64 (0.104-0ubuntu2~20.04.2) ...\r\nSetting up udev (245.4-4ubuntu3.18)
...\r\nupdate-                                        initramfs: deferring update
(trigger activated)\r\nSetting up python-apt-common (2.0.0ubuntu0.20.04.8) ...\r\
nSetting up python3-apt (2.0.0ubuntu0.20.04.8) ...\r\nSetting up python3-dis         
tupgrade (1:20.04.39) ...\r\nSetting up ubuntu-release-upgrader-core
(1:20.04.39) ...\r\nSetting up ubuntu-advantage-tools (27.10.1~20.04.1) ...\r\
nSetting up systemd (245.4-4ubuntu3.18                                        ) ...\
r\nSetting up netplan.io (0.104-0ubuntu2~20.04.2) ...\r\nSetting up systemd-timesyncd
(245.4-4ubuntu3.18) ...\r\nSetting up systemd-sysv (245.4-4ubuntu3.18) ...\r\nSetting
up libn                                        ss-systemd:amd64 (245.4-
4ubuntu3.18) ...\r\nSetting up libpam-systemd:amd64 (245.4-4ubuntu3.18) ...\r\
nProcessing triggers for install-info (6.7.0.dfsg.2-5) ...\r\nProcessing triggers f 
or libc-bin (2.31-0ubuntu9.9) ...\r\nProcessing triggers for man-db (2.9.1-1) ...\r\
nProcessing triggers for plymouth-theme-ubuntu-text (0.9.4git20200323-
0ubuntu6.2) ...\r\nupdate-initr                                        amfs:
deferring update (trigger activated)\r\nProcessing triggers for dbus (1.12.16-
2ubuntu2.2) ...\r\nProcessing triggers for initramfs-tools (0.136ubuntu6.7) ...\r\
nupdate-initramfs:                                         Generating
/boot/initrd.img-5.4.0-126-generic\r\n",
        "stdout_lines": [
                "Reading package lists...",
                "Building dependency tree...",
                "Reading state information...",
                "Calculating upgrade...",
                "The following packages will be upgraded:",
                "    base-files libnetplan0 libnss-systemd libpam-systemd
libsystemd0",
                "    libtss2-esys0 libudev1 motd-news-config netplan.io python-apt-
common",
                "    python3-apt python3-distupgrade systemd systemd-sysv systemd-
timesyncd",
                "    ubuntu-advantage-tools ubuntu-release-upgrader-core udev",
                "18 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.",
                "Need to get 6747 kB of archives.",
                "After this operation, 2594 kB disk space will be freed.",
                "Get:1 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 motd-news-config all 11ubuntu5.6 [4348 B]",
                "Get:2 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 base-files amd64 11ubuntu5.6 [60.4 kB]",
                "Get:3 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libnss-systemd amd64 245.4-4ubuntu3.18 [96.1 kB]",
                "Get:4 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 udev amd64 245.4-4ubuntu3.18 [1367 kB]",
                "Get:5 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libudev1 amd64 245.4-4ubuntu3.18 [76.3 kB]",
                "Get:6 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 systemd-sysv amd64 245.4-4ubuntu3.18 [10.3 kB]",
                "Get:7 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 systemd-timesyncd amd64 245.4-4ubuntu3.18 [28.1 kB]",
                "Get:8 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libpam-systemd amd64 245.4-4ubuntu3.18 [186 kB]",
                "Get:9 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 systemd amd64 245.4-4ubuntu3.18 [3808 kB]",
                "Get:10 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libsystemd0 amd64 245.4-4ubuntu3.18 [269 kB]",
                "Get:11 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 netplan.io amd64 0.104-0ubuntu2~20.04.2 [88.0 kB]",
                "Get:12 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libnetplan0 amd64 0.104-0ubuntu2~20.04.2 [82.5 kB]",
                "Get:13 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 python-apt-common all 2.0.0ubuntu0.20.04.8 [17.1 kB]",
                "Get:14 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 python3-apt amd64 2.0.0ubuntu0.20.04.8 [154 kB]",
                "Get:15 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 ubuntu-advantage-tools amd64 27.10.1~20.04.1 [146 kB]",
                "Get:16 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 ubuntu-release-upgrader-core all 1:20.04.39 [24.4 kB]",
                "Get:17 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 python3-distupgrade all 1:20.04.39 [104 kB]",
                "Get:18 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libtss2-esys0 amd64 2.3.2-1ubuntu0.20.04.1 [226 kB]",
                "Preconfiguring packages ...",
                "Fetched 6747 kB in 1s (6785 kB/s)",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97544 files and directories currently
installed.)",
                "Preparing to unpack .../motd-news-config_11ubuntu5.6_all.deb ...",
                "Unpacking motd-news-config (11ubuntu5.6) over (11ubuntu5.5) ...",
                "Preparing to unpack .../base-files_11ubuntu5.6_amd64.deb ...",
                "Warning: Stopping motd-news.service, but it can still be activated
by:",
                "    motd-news.timer",
                "Unpacking base-files (11ubuntu5.6) over (11ubuntu5.5) ...",
                "Setting up base-files (11ubuntu5.6) ...",
                "Installing new version of config file /etc/issue ...",
                "Installing new version of config file /etc/issue.net ...",
                "Installing new version of config file /etc/lsb-release ...",
                "motd-news.service is a disabled or a static unit, not starting it.",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97544 files and directories currently
installed.)",
                "Preparing to unpack .../libnss-systemd_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking libnss-systemd:amd64 (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Preparing to unpack .../udev_245.4-4ubuntu3.18_amd64.deb ...",
                "Unpacking udev (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...",
                "Preparing to unpack .../libudev1_245.4-4ubuntu3.18_amd64.deb ...",
                "Unpacking libudev1:amd64 (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Setting up libudev1:amd64 (245.4-4ubuntu3.18) ...",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97544 files and directories currently
installed.)",
                "Preparing to unpack .../systemd-sysv_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking systemd-sysv (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Preparing to unpack .../systemd-timesyncd_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking systemd-timesyncd (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Preparing to unpack .../libpam-systemd_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking libpam-systemd:amd64 (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Preparing to unpack .../systemd_245.4-4ubuntu3.18_amd64.deb ...",
                "Unpacking systemd (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...",
                "Preparing to unpack .../libsystemd0_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking libsystemd0:amd64 (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Setting up libsystemd0:amd64 (245.4-4ubuntu3.18) ...",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97544 files and directories currently
installed.)",
                "Preparing to unpack .../0-netplan.io_0.104-
0ubuntu2~20.04.2_amd64.deb ...",
                "Unpacking netplan.io (0.104-0ubuntu2~20.04.2) over (0.104-
0ubuntu2~20.04.1) ...",
                "Preparing to unpack .../1-libnetplan0_0.104-
0ubuntu2~20.04.2_amd64.deb ...",
                "Unpacking libnetplan0:amd64 (0.104-0ubuntu2~20.04.2) over (0.104-
0ubuntu2~20.04.1) ...",
                "Preparing to unpack .../2-python-apt-
common_2.0.0ubuntu0.20.04.8_all.deb ...",
                "Unpacking python-apt-common (2.0.0ubuntu0.20.04.8) over
(2.0.0ubuntu0.20.04.7) ...",
                "Preparing to unpack .../3-python3-apt_2.0.0ubuntu0.20.04.8_amd64.deb
...",
                "Unpacking python3-apt (2.0.0ubuntu0.20.04.8) over
(2.0.0ubuntu0.20.04.7) ...",
                "Preparing to unpack .../4-ubuntu-advantage-
tools_27.10.1~20.04.1_amd64.deb ...",
                "Unpacking ubuntu-advantage-tools (27.10.1~20.04.1) over
(27.9~20.04.1) ...",
                "Preparing to unpack .../5-ubuntu-release-upgrader-
core_1%3a20.04.39_all.deb ...",
                "Unpacking ubuntu-release-upgrader-core (1:20.04.39) over
(1:20.04.38) ...",
                "Preparing to unpack .../6-python3-
distupgrade_1%3a20.04.39_all.deb ...",
                "Unpacking python3-distupgrade (1:20.04.39) over (1:20.04.38) ...",
                "Preparing to unpack .../7-libtss2-esys0_2.3.2-
1ubuntu0.20.04.1_amd64.deb ...",
                "Unpacking libtss2-esys0 (2.3.2-1ubuntu0.20.04.1) over (2.3.2-
1) ...",
                "Setting up motd-news-config (11ubuntu5.6) ...",
                "Setting up libtss2-esys0 (2.3.2-1ubuntu0.20.04.1) ...",
                "Setting up libnetplan0:amd64 (0.104-0ubuntu2~20.04.2) ...",
                "Setting up udev (245.4-4ubuntu3.18) ...",
                "update-initramfs: deferring update (trigger activated)",
                "Setting up python-apt-common (2.0.0ubuntu0.20.04.8) ...",
                "Setting up python3-apt (2.0.0ubuntu0.20.04.8) ...",
                "Setting up python3-distupgrade (1:20.04.39) ...",
                "Setting up ubuntu-release-upgrader-core (1:20.04.39) ...",
                "Setting up ubuntu-advantage-tools (27.10.1~20.04.1) ...",
                "Setting up systemd (245.4-4ubuntu3.18) ...",
                "Setting up netplan.io (0.104-0ubuntu2~20.04.2) ...",
                "Setting up systemd-timesyncd (245.4-4ubuntu3.18) ...",
                "Setting up systemd-sysv (245.4-4ubuntu3.18) ...",
                "Setting up libnss-systemd:amd64 (245.4-4ubuntu3.18) ...",
                "Setting up libpam-systemd:amd64 (245.4-4ubuntu3.18) ...",
                "Processing triggers for install-info (6.7.0.dfsg.2-5) ...",
                "Processing triggers for libc-bin (2.31-0ubuntu9.9) ...",
                "Processing triggers for man-db (2.9.1-1) ...",
                "Processing triggers for plymouth-theme-ubuntu-text
(0.9.4git20200323-0ubuntu6.2) ...",
                "update-initramfs: deferring update (trigger activated)",
                "Processing triggers for dbus (1.12.16-2ubuntu2.2) ...",
                "Processing triggers for initramfs-tools (0.136ubuntu6.7) ...",
                "update-initramfs: Generating /boot/initrd.img-5.4.0-126-generic"
        ]
}
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo2.yaml
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ ansible-playbook exo3.yaml
ERROR! conflicting action statements: shell, uid

The error appears to be in '/home/ansadmin/exo3.yaml': line 7, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: utilisateur
            ^ here
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ ansible-playbook exo3.yaml
ERROR! unexpected parameter type in action: <class 'int'>

The error appears to be in '/home/ansadmin/exo3.yaml': line 7, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: adduser supervision
            ^ here
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook exo3.yaml
ERROR! A malformed block was encountered while loading tasks: {'user': [{'name':
'supervision',                                                                       
'uid': '5000', 'groups': 'rennes'}]} should be a list or None but is <class
'ansible.parsing.y                                                                   
aml.objects.AnsibleMapping'>

The error appears to be in '/home/ansadmin/exo3.yaml': line 2, column 3, but may


be elsewhere in the file depending on the exact syntax problem.
The offending line appears to be:

---
- name: creation d'utilisateur
    ^ here
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ ansible-playbook exo3.yaml

PLAY [creation d'utilisateur]


*****************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creer user]


*****************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ ansible -bm shell -a "id supervision"


usage: ansible [-h] [--version] [-v] [-b] [--become-method BECOME_METHOD]
                              [--become-user BECOME_USER] [-K] [-i INVENTORY] [--
list-hosts] [-l SUBSET]
                              [-P POLL_INTERVAL] [-B SECONDS] [-o] [-t TREE] [-k]
                              [--private-key PRIVATE_KEY_FILE] [-u REMOTE_USER] [-c
CONNECTION] [-T TIMEOUT]
                              [--ssh-common-args SSH_COMMON_ARGS] [--sftp-extra-args
SFTP_EXTRA_ARGS]
                              [--scp-extra-args SCP_EXTRA_ARGS] [--ssh-extra-args
SSH_EXTRA_ARGS] [-C]
                              [--syntax-check] [-D] [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                              [--ask-vault-pass | --vault-password-file
VAULT_PASSWORD_FILES] [-f FORKS]
                              [-M MODULE_PATH] [--playbook-dir BASEDIR] [-a
MODULE_ARGS] [-m MODULE_NAME]
                              pattern
ansible: error: the following arguments are required: pattern
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible -bm shell -a "cat /etc/passwd | grep super"
usage: ansible [-h] [--version] [-v] [-b] [--become-method BECOME_METHOD]
                              [--become-user BECOME_USER] [-K] [-i INVENTORY] [--
list-hosts] [-l SUBSET]
                              [-P POLL_INTERVAL] [-B SECONDS] [-o] [-t TREE] [-k]
                              [--private-key PRIVATE_KEY_FILE] [-u REMOTE_USER] [-c
CONNECTION] [-T TIMEOUT]
                              [--ssh-common-args SSH_COMMON_ARGS] [--sftp-extra-args
SFTP_EXTRA_ARGS]
                              [--scp-extra-args SCP_EXTRA_ARGS] [--ssh-extra-args
SSH_EXTRA_ARGS] [-C]
                              [--syntax-check] [-D] [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                              [--ask-vault-pass | --vault-password-file
VAULT_PASSWORD_FILES] [-f FORKS]
                              [-M MODULE_PATH] [--playbook-dir BASEDIR] [-a
MODULE_ARGS] [-m MODULE_NAME]
                              pattern
ansible: error: the following arguments are required: pattern
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible -b -m shell -a "cat /etc/passwd | grep super"
usage: ansible [-h] [--version] [-v] [-b] [--become-method BECOME_METHOD]
                              [--become-user BECOME_USER] [-K] [-i INVENTORY] [--
list-hosts] [-l SUBSET]
                              [-P POLL_INTERVAL] [-B SECONDS] [-o] [-t TREE] [-k]
                              [--private-key PRIVATE_KEY_FILE] [-u REMOTE_USER] [-c
CONNECTION] [-T TIMEOUT]
                              [--ssh-common-args SSH_COMMON_ARGS] [--sftp-extra-args
SFTP_EXTRA_ARGS]
                              [--scp-extra-args SCP_EXTRA_ARGS] [--ssh-extra-args
SSH_EXTRA_ARGS] [-C]
                              [--syntax-check] [-D] [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                              [--ask-vault-pass | --vault-password-file
VAULT_PASSWORD_FILES] [-f FORKS]
                              [-M MODULE_PATH] [--playbook-dir BASEDIR] [-a
MODULE_ARGS] [-m MODULE_NAME]
                              pattern
ansible: error: the following arguments are required: pattern
ansadmin@svl200:~$ ansible all -b -m shell -a "cat /etc/passwd | grep super"
146.59.158.16 | CHANGED | rc=0 >>
supervision:x:5000:5000::/home/supervision:/bin/sh
141.95.160.133 | CHANGED | rc=0 >>
supervision:x:5000:5000::/home/supervision:/bin/sh
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ cd /etc/ap
apache2/        apparmor/      apparmor.d/ apport/          apt/
ansadmin@svl200:~$
---
- name: Deployer apache
    hosts: cible1
    become: true

    tasks:
        - name: deploiement

Network error: Software caused connection abort


~
─────────────────────────────────────────────────────────────────────────────────────
──────────
~
Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
-- INSERT --                                                                         
8,7                      All

Network error: Connection timed out

─────────────────────────────────────────────────────────────────────────────────────
──────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Last login: Tue Oct    4 07:50:40 2022 from 176.160.191.208


ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ ansible-playbook exo4.yaml
ERROR! conflicting action statements: apt, state

The error appears to be in '/home/ansadmin/exo4.yaml': line 7, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: deploiement
            ^ here
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ ansible-playbook exo4.yaml

PLAY [Deployer apache]


************************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]

TASK [deploiement]
****************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "No package matching
'apache' is a                                                                       
vailable"}

PLAY RECAP
************************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ ansible-playbook exo4.yaml

PLAY [Deployer apache]


************************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [deploiement]
****************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "No package matching
'apache' is a                                                                       
vailable"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "No package matching
'apache' is                                                                          
available"}

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim exo4.yaml


ansadmin@svl200:~$ ansible-playbook exo4.yaml

PLAY [Deployer apache]


************************************************************************

TASK [Gathering Facts]


************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [deploiement]
****************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
************************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=0        res                                                 
cued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=0        res                                                 
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim exo4.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when1.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when.yaml
ansadmin@svl200:~$ sudo vim when1.yaml
ansadmin@svl200:~$ ansible-playbook when1.yaml

PLAY [exemple avec condition when]


****************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


********************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [install apache2 on ubuntu]


******************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
1      rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
1      rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim when1.yaml


ansadmin@svl200:~$ sudo vim rep.yaml
ansadmin@svl200:~$ ansible-playbook rep.yaml

PLAY [Creation de repertoire]


*********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation]
***********************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation]
***********************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=                                                             
1      rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=                                                             
1      rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim rep.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /etc"
146.59.158.16 | CHANGED | rc=0 >>
total 884
-rw-r--r-- 1 root root                887 Apr    1    2013 rpc
-rw-r--r-- 1 root root              2932 Apr    1    2013 protocols
-rw-r--r-- 1 root root                280 Jun 20    2014 fuse.conf
-rw-r--r-- 1 root root              3663 Jun 20    2016 screenrc
-rw-r--r-- 1 root root                604 Sep 15    2018 deluser.conf
-rw-r----- 1 root daemon            144 Nov 12    2018 at.deny
-rw-r--r-- 1 root root              1260 Dec 14    2018 ucf.conf
-rw-r--r-- 1 root root                533 Jan 21    2019 logrotate.conf
-rw-r--r-- 1 root root            14867 Feb    1    2019 ltrace.conf
-rw-r--r-- 1 root root              2969 Aug    3    2019 debconf.conf
-rw-r--r-- 1 root root              5060 Aug 21    2019 hdparm.conf
-rw-r--r-- 1 root root                642 Sep 24    2019 xattr.conf
-rw-r--r-- 1 root root            24546 Oct 18    2019 mime.types
-rw-r--r-- 1 root root                449 Oct 18    2019 mailcap.order
-rw-r--r-- 1 root root                581 Dec    5    2019 profile
-rw-r--r-- 1 root root                  91 Dec    5    2019 networks
-rw-r--r-- 1 root root                267 Dec    5    2019 legal
-rw-r--r-- 1 root root                  92 Dec    5    2019 host.conf
-rw-r--r-- 1 root root                  13 Dec    5    2019 debian_version
-rw-r--r-- 1 root root                552 Dec 17    2019 pam.conf
-rw-r--r-- 1 root root              1816 Dec 27    2019 ethertypes
-rw-r--r-- 1 root root                111 Jan 16    2020 magic.mime
-rw-r--r-- 1 root root                111 Jan 16    2020 magic
-rw-r--r-- 1 root root                  45 Jan 26    2020 bash_completion
-rw-r--r-- 1 root root              2584 Feb    1    2020 gai.conf
-r--r----- 1 root root                755 Feb    3    2020 sudoers
-rw-r--r-- 1 root root            10037 Feb    7    2020 nanorc
-rw-r--r-- 1 root root            10550 Feb    7    2020 login.defs
-rw-r--r-- 1 root root              1523 Feb 10    2020 usb_modeswitch.conf
-rw-r--r-- 1 root root              1382 Feb 11    2020 rsyslog.conf
-rw-r--r-- 1 root root              1042 Feb 13    2020 crontab
-rw-r--r-- 1 root root              2351 Feb 13    2020 sysctl.conf
-rw-r--r-- 1 root root                808 Feb 14    2020 mke2fs.conf
-rw-r--r-- 1 root root                685 Feb 14    2020 e2scrub.conf
-rw-r--r-- 1 root root            14464 Feb 16    2020 services
-rw-r--r-- 1 root root                191 Feb 18    2020 libaudit.conf
drwxr-xr-x 2 root root              4096 Feb 24    2020 usb_modeswitch.d
-rw-r--r-- 1 root root              1748 Feb 25    2020 inputrc
-rw-r--r-- 1 root root              2319 Feb 25    2020 bash.bashrc
-rw-r--r-- 1 root root              5215 Feb 25    2020 manpath.config
-rw-r--r-- 1 root root                  41 Apr    6    2020 multipath.conf
-rw-r--r-- 1 root root              2996 Apr 14    2020 locale.alias
-rw-r--r-- 1 root root                  34 Apr 14    2020 ld.so.conf
-rw-r--r-- 1 root root                367 Apr 14    2020 bindresvport.blacklist
drwxr-xr-x 2 root root              4096 Apr 22    2020 binfmt.d
-rw-r--r-- 1 root root              6920 Nov    2    2021 overlayroot.conf
-rw-r--r-- 1 root root              4942 Nov 12    2021 wgetrc
-rw-r--r-- 1 root root                477 Feb 10    2022 zsh_command_not_found
drwxrwxr-x 2 root landscape    4096 Feb 14    2022 landscape
lrwxrwxrwx 1 root root                  13 Mar 15    2022 rmt -> /usr/sbin/rmt
-rw-r--r-- 1 root root            10593 Mar 31    2022 sensors3.conf
drwxr-xr-x 2 root root              4096 Apr 25 14:02 update-notifier
drwxr-xr-x 2 root root              4096 Jul 24 21:38 opt
drwxr-xr-x 2 root root              4096 Jul 24 21:38 selinux
drwxr-xr-x 2 root root              4096 Jul 24 21:38 terminfo
-rw-r--r-- 1 root root              3028 Jul 24 21:38 adduser.conf
lrwxrwxrwx 1 root root                  39 Jul 24 21:38 resolv.conf ->
../run/systemd/resolve/st                                                           
ub-resolv.conf
lrwxrwxrwx 1 root root                  19 Jul 24 21:38 mtab -> ../proc/self/mounts
drwxr-xr-x 7 root root              4096 Jul 24 21:38 apt
drwxr-xr-x 3 root root              4096 Jul 24 21:38 ca-certificates
drwxr-xr-x 4 root root              4096 Jul 24 21:38 dbus-1
drwxr-xr-x 8 root root              4096 Jul 24 21:38 networkd-dispatcher
drwxr-xr-x 4 root root              4096 Jul 24 21:38 xdg
drwxr-xr-x 2 root root              4096 Jul 24 21:38 cron.hourly
drwxr-xr-x 2 root root              4096 Jul 24 21:38 cron.monthly
-rw-r--r-- 1 root root                510 Jul 24 21:38 nsswitch.conf
-rw-r--r-- 1 root root                195 Jul 24 21:38 modules
drwxr-xr-x 2 root root              4096 Jul 24 21:38 newt
drwxr-xr-x 4 root root              4096 Jul 24 21:38 iproute2
-rw-r--r-- 1 root root              5713 Jul 24 21:38 ca-certificates.conf.dpkg-old
drwxr-xr-x 2 root root              4096 Jul 24 21:38 python3
lrwxrwxrwx 1 root root                  23 Jul 24 21:38 vtrgb ->
/etc/alternatives/vtrgb
drwxr-xr-x 2 root root              4096 Jul 24 21:38 skel
drwxr-xr-x 4 root root              4096 Jul 24 21:39 dpkg
drwxr-xr-x 2 root root              4096 Jul 24 21:39 ld.so.conf.d
drwxr-xr-x 4 root root              4096 Jul 24 21:39 security
-rw-r--r-- 1 root root                106 Jul 24 21:39 environment
drwxr-xr-x 4 root root              4096 Jul 24 21:39 ssl
drwxr-xr-x 2 root root              4096 Jul 24 21:39 python3.8
drwxr-xr-x 4 root root              4096 Jul 24 21:39 dhcp
drwxr-xr-x 2 root root              4096 Jul 24 21:39 depmod.d
-rw-r--r-- 1 root root              6821 Jul 24 21:39 ca-certificates.conf
-rw-r--r-- 1 root root                110 Jul 24 21:39 kernel-img.conf
drwxr-xr-x 3 root root              4096 Jul 24 21:39 perl
drwxr-xr-x 3 root root              4096 Jul 24 21:39 gss
-rw-r--r-- 1 root root                  54 Jul 24 21:39 crypttab
drwxr-xr-x 5 root root              4096 Jul 24 21:39 kernel
drwxr-xr-x 3 root root              4096 Jul 24 21:39 dconf
drwxr-xr-x 4 root root              4096 Jul 24 21:39 network
drwxr-xr-x 4 root root              4096 Jul 24 21:39 pki
drwxr-xr-x 3 root root              4096 Jul 24 21:39 pm
drwxr-xr-x 3 root root              4096 Jul 24 21:39 libblockdev
drwxr-xr-x 4 root root              4096 Jul 24 21:39 polkit-1
drwxr-xr-x 3 root root              4096 Jul 24 21:39 ModemManager
drwxr-xr-x 3 root root              4096 Jul 24 21:39 NetworkManager
drwxr-xr-x 2 root root              4096 Jul 24 21:39 ldap
drwxr-xr-x 3 root root              4096 Jul 24 21:39 apparmor
-rw-r--r-- 1 root root                711 Jul 24 21:39 hosts.deny
-rw-r--r-- 1 root root                411 Jul 24 21:39 hosts.allow
drwxr-xr-x 2 root root              4096 Jul 24 21:39 calendar
drwxr-xr-x 2 root root              4096 Jul 24 21:39 modprobe.d
drwxr-xr-x 2 root root              4096 Jul 24 21:39 mdadm
drwxr-xr-x 2 root root              4096 Jul 24 21:39 byobu
drwxr-xr-x 2 root root              4096 Jul 24 21:39 tmpfiles.d
-rw-r--r-- 1 root root                146 Jul 24 21:39 shells
drwxr-xr-x 2 root root              4096 Jul 24 21:39 iscsi
drwxr-xr-x 2 root root              4096 Jul 24 21:40 groff
drwxr-xr-x 5 root root              4096 Jul 24 21:40 initramfs-tools
drwxr-xr-x 2 root root              4096 Jul 24 21:40 rsyslog.d
drwxr-xr-x 3 root root              4096 Jul 24 21:40 ufw
drwxr-xr-x 2 root root              4096 Jul 24 21:40 cryptsetup-initramfs
drwxr-xr-x 2 root root              4096 Jul 24 21:40 udisks2
drwxr-xr-x 3 root root              4096 Jul 24 21:40 apport
drwxr-xr-x 2 root root              4096 Jul 24 21:40 bash_completion.d
drwxr-xr-x 2 root root              4096 Jul 24 21:40 pollinate
drwxr-xr-x 3 root root              4096 Jul 24 21:40 fwupd
drwxr-xr-x 3 root root              4096 Jul 24 21:40 lvm
drwxr-xr-x 2 root root              4096 Jul 24 21:40 cron.weekly
drwxr-xr-x 2 root root              4096 Jul 24 21:40 PackageKit
-rw-r--r-- 1 root root                  33 Jul 24 21:40 ec2_version
drwxr-xr-x 2 root root              4096 Jul 24 21:40 console-setup
-rw-r--r-- 1 root root                    0 Jul 24 21:40 popularity-contest.conf
-rw-r--r-- 1 root root              9440 Jul 24 21:40 locale.gen
-rw-r--r-- 1 root root                112 Jul 24 21:40 overlayroot.local.conf
-rw-r--r-- 1 root root                  84 Jul 24 21:41 fstab
drwxr-xr-x 2 root root              4096 Jul 24 21:41 grub.d
drwxr-xr-x 2 root root              4096 Aug    1 05:31 netplan
drwxr-xr-x 3 root root              4096 Aug    1 05:32 qemu
drwxr-xr-x 4 root root              4096 Aug    1 05:32 cloud
-rw-r--r-- 1 root root                104 Aug 22 10:53 lsb-release
lrwxrwxrwx 1 root root                  21 Aug 22 10:54 os-release -> ../usr/lib/os-
release
-rw-r--r-- 1 root root                  19 Aug 22 10:54 issue.net
-rw-r--r-- 1 root root                  26 Aug 22 10:54 issue
drwx------ 2 root root              4096 Aug 26 08:20 multipath
-r--r--r-- 1 root root                  33 Aug 26 08:20 machine-id
drwxr-xr-x 4 root root              4096 Aug 27 06:07 vmware-tools
-rw-r--r-- 1 root root                    8 Sep    8 06:16 timezone
lrwxrwxrwx 1 root root                  27 Sep    8 06:16 localtime ->
/usr/share/zoneinfo/Etc/UTC
drwxr-xr-x 5 root root              4096 Sep 19 09:45 vulkan
drwxr-xr-x 7 root root              4096 Sep 19 09:46 X11
drwxr-xr-x 2 root root              4096 Sep 19 09:46 rcS.d
drwxr-xr-x 2 root root              4096 Sep 19 09:46 sensors.d
drwxr-xr-x 4 root root              4096 Sep 19 09:46 fonts
drwxr-xr-x 2 root root              4096 Sep 19 09:46 environment.d
drwxr-xr-x 5 root root              4096 Sep 19 09:46 java-11-openjdk
-rw-r--r-- 1 root root                  15 Sep 20 05:01 hostname
drwxr-xr-x 2 root root              4096 Sep 20 06:40 vim
-rw-r--r-- 1 root root              3956 Sep 20 06:40 mailcap
-rw-r--r-- 1 root root                363 Sep 21 08:44 hosts
drwxr-xr-x 8 root root              4096 Sep 22 15:42 apache2
drwxr-xr-x 2 root root              4096 Sep 22 15:42 cron.daily
drwxr-xr-x 2 root root              4096 Sep 23 09:32 wildfly
drwxr-xr-x 2 root root              4096 Sep 25 18:18 process-exporter
drwxr-xr-x 6 root root              4096 Sep 28 06:24 sos
drwxr-xr-x 2 root root              4096 Oct    2 17:35 profile.d
drwxr-xr-x 2 root root              4096 Oct    2 17:35 sysctl.d
drwxr-xr-x 2 root root              4096 Oct    2 17:35 modules-load.d
drwxr-xr-x 4 root root              4096 Oct    2 17:35 udev
drwxr-xr-x 3 root root              4096 Oct    2 17:35 update-manager
drwxr-xr-x 2 root root              4096 Oct    2 17:35 ubuntu-advantage
drwxr-xr-x 2 root root              4096 Oct    2 17:35 update-motd.d
drwxr-xr-x 5 root root              4096 Oct    2 17:36 systemd
drwxr-xr-x 2 root root              4096 Oct    2 17:36 pam.d
drwxr-x--- 2 root root              4096 Oct    3 08:54 sudoers.d
drwxr-xr-x 4 root root              4096 Oct    3 08:56 ssh
drwxr-xr-x 8 root root              4096 Oct    3 12:32 nginx
-rw-r--r-- 1 root root                178 Oct    4 07:58 subuid-
-rw-r--r-- 1 root root                178 Oct    4 07:58 subgid-
-rw-r----- 1 root shadow            944 Oct    4 08:45 gshadow-
-rw-r--r-- 1 root root              1136 Oct    4 08:45 group-
-rw-r--r-- 1 root root                203 Oct    4 08:45 subuid
-rw-r--r-- 1 root root                203 Oct    4 08:45 subgid
-rw-r----- 1 root shadow          1907 Oct    4 08:59 shadow-
-rw-r--r-- 1 root root              2362 Oct    4 08:59 passwd-
-rw-r--r-- 1 root root              1149 Oct    4 08:59 group
-rw-r----- 1 root shadow            954 Oct    4 08:59 gshadow
-rw-r----- 1 root shadow          1907 Oct    4 08:59 shadow
-rw-r--r-- 1 root root              2377 Oct    4 08:59 passwd
drwxr-xr-x 6 root root              4096 Oct    4 08:59 logcheck
drwxr-xr-x 3 root root              4096 Oct    4 08:59 php
drwxr-xr-x 2 root root              4096 Oct    4 08:59 cron.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 alternatives
drwxr-xr-x 7 root root              4096 Oct    4 08:59 apparmor.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 insserv.conf.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 init.d
drwxr-xr-x 3 root root              4096 Oct    4 08:59 default
drwxr-xr-x 2 root root              4096 Oct    4 08:59 logrotate.d
drwxr-xr-x 4 root root              4096 Oct    4 08:59 mysql
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc6.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc5.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc4.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc3.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc2.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc1.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc0.d
-rw-r--r-- 1 root root            31764 Oct    4 08:59 ld.so.cache
141.95.160.133 | CHANGED | rc=0 >>
total 884
-rw-r--r-- 1 root root                887 Apr    1    2013 rpc
-rw-r--r-- 1 root root              2932 Apr    1    2013 protocols
-rw-r--r-- 1 root root                280 Jun 20    2014 fuse.conf
-rw-r--r-- 1 root root              3663 Jun 20    2016 screenrc
-rw-r--r-- 1 root root                604 Sep 15    2018 deluser.conf
-rw-r----- 1 root daemon            144 Nov 12    2018 at.deny
-rw-r--r-- 1 root root              1260 Dec 14    2018 ucf.conf
-rw-r--r-- 1 root root                533 Jan 21    2019 logrotate.conf
-rw-r--r-- 1 root root            14867 Feb    1    2019 ltrace.conf
-rw-r--r-- 1 root root              2969 Aug    3    2019 debconf.conf
-rw-r--r-- 1 root root              5060 Aug 21    2019 hdparm.conf
-rw-r--r-- 1 root root                642 Sep 24    2019 xattr.conf
-rw-r--r-- 1 root root            24546 Oct 18    2019 mime.types
-rw-r--r-- 1 root root                449 Oct 18    2019 mailcap.order
-rw-r--r-- 1 root root                581 Dec    5    2019 profile
-rw-r--r-- 1 root root                  91 Dec    5    2019 networks
-rw-r--r-- 1 root root                267 Dec    5    2019 legal
-rw-r--r-- 1 root root                  92 Dec    5    2019 host.conf
-rw-r--r-- 1 root root                  13 Dec    5    2019 debian_version
-rw-r--r-- 1 root root                552 Dec 17    2019 pam.conf
-rw-r--r-- 1 root root              1816 Dec 27    2019 ethertypes
-rw-r--r-- 1 root root                111 Jan 16    2020 magic.mime
-rw-r--r-- 1 root root                111 Jan 16    2020 magic
-rw-r--r-- 1 root root                  45 Jan 26    2020 bash_completion
-rw-r--r-- 1 root root              2584 Feb    1    2020 gai.conf
-r--r----- 1 root root                755 Feb    3    2020 sudoers
-rw-r--r-- 1 root root            10037 Feb    7    2020 nanorc
-rw-r--r-- 1 root root            10550 Feb    7    2020 login.defs
-rw-r--r-- 1 root root              1523 Feb 10    2020 usb_modeswitch.conf
-rw-r--r-- 1 root root              1382 Feb 11    2020 rsyslog.conf
-rw-r--r-- 1 root root              1042 Feb 13    2020 crontab
-rw-r--r-- 1 root root              2351 Feb 13    2020 sysctl.conf
-rw-r--r-- 1 root root                808 Feb 14    2020 mke2fs.conf
-rw-r--r-- 1 root root                685 Feb 14    2020 e2scrub.conf
-rw-r--r-- 1 root root            14464 Feb 16    2020 services
-rw-r--r-- 1 root root                191 Feb 18    2020 libaudit.conf
drwxr-xr-x 2 root root              4096 Feb 24    2020 usb_modeswitch.d
-rw-r--r-- 1 root root              1748 Feb 25    2020 inputrc
-rw-r--r-- 1 root root              2319 Feb 25    2020 bash.bashrc
-rw-r--r-- 1 root root              5215 Feb 25    2020 manpath.config
-rw-r--r-- 1 root root                  41 Apr    6    2020 multipath.conf
-rw-r--r-- 1 root root              2996 Apr 14    2020 locale.alias
-rw-r--r-- 1 root root                  34 Apr 14    2020 ld.so.conf
-rw-r--r-- 1 root root                367 Apr 14    2020 bindresvport.blacklist
drwxr-xr-x 2 root root              4096 Apr 22    2020 binfmt.d
-rw-r--r-- 1 root root              6920 Nov    2    2021 overlayroot.conf
-rw-r--r-- 1 root root              4942 Nov 12    2021 wgetrc
-rw-r--r-- 1 root root                477 Feb 10    2022 zsh_command_not_found
drwxrwxr-x 2 root landscape    4096 Feb 14    2022 landscape
lrwxrwxrwx 1 root root                  13 Mar 15    2022 rmt -> /usr/sbin/rmt
-rw-r--r-- 1 root root            10593 Mar 31    2022 sensors3.conf
drwxr-xr-x 2 root root              4096 Apr 25 14:02 update-notifier
drwxr-xr-x 2 root root              4096 Jul 24 21:38 opt
drwxr-xr-x 2 root root              4096 Jul 24 21:38 selinux
drwxr-xr-x 2 root root              4096 Jul 24 21:38 terminfo
-rw-r--r-- 1 root root              3028 Jul 24 21:38 adduser.conf
lrwxrwxrwx 1 root root                  39 Jul 24 21:38 resolv.conf ->
../run/systemd/resolve/st                                                           
ub-resolv.conf
lrwxrwxrwx 1 root root                  19 Jul 24 21:38 mtab -> ../proc/self/mounts
drwxr-xr-x 7 root root              4096 Jul 24 21:38 apt
drwxr-xr-x 3 root root              4096 Jul 24 21:38 ca-certificates
drwxr-xr-x 4 root root              4096 Jul 24 21:38 dbus-1
drwxr-xr-x 8 root root              4096 Jul 24 21:38 networkd-dispatcher
drwxr-xr-x 4 root root              4096 Jul 24 21:38 xdg
drwxr-xr-x 2 root root              4096 Jul 24 21:38 cron.hourly
drwxr-xr-x 2 root root              4096 Jul 24 21:38 cron.monthly
-rw-r--r-- 1 root root                510 Jul 24 21:38 nsswitch.conf
-rw-r--r-- 1 root root                195 Jul 24 21:38 modules
drwxr-xr-x 2 root root              4096 Jul 24 21:38 newt
drwxr-xr-x 4 root root              4096 Jul 24 21:38 iproute2
-rw-r--r-- 1 root root              5713 Jul 24 21:38 ca-certificates.conf.dpkg-old
drwxr-xr-x 2 root root              4096 Jul 24 21:38 python3
lrwxrwxrwx 1 root root                  23 Jul 24 21:38 vtrgb ->
/etc/alternatives/vtrgb
drwxr-xr-x 2 root root              4096 Jul 24 21:38 skel
drwxr-xr-x 4 root root              4096 Jul 24 21:39 dpkg
drwxr-xr-x 2 root root              4096 Jul 24 21:39 ld.so.conf.d
drwxr-xr-x 4 root root              4096 Jul 24 21:39 security
-rw-r--r-- 1 root root                106 Jul 24 21:39 environment
drwxr-xr-x 4 root root              4096 Jul 24 21:39 ssl
drwxr-xr-x 2 root root              4096 Jul 24 21:39 python3.8
drwxr-xr-x 4 root root              4096 Jul 24 21:39 dhcp
drwxr-xr-x 2 root root              4096 Jul 24 21:39 depmod.d
-rw-r--r-- 1 root root              6821 Jul 24 21:39 ca-certificates.conf
-rw-r--r-- 1 root root                110 Jul 24 21:39 kernel-img.conf
drwxr-xr-x 3 root root              4096 Jul 24 21:39 perl
drwxr-xr-x 3 root root              4096 Jul 24 21:39 gss
-rw-r--r-- 1 root root                  54 Jul 24 21:39 crypttab
drwxr-xr-x 5 root root              4096 Jul 24 21:39 kernel
drwxr-xr-x 3 root root              4096 Jul 24 21:39 dconf
drwxr-xr-x 4 root root              4096 Jul 24 21:39 network
drwxr-xr-x 4 root root              4096 Jul 24 21:39 pki
drwxr-xr-x 3 root root              4096 Jul 24 21:39 pm
drwxr-xr-x 3 root root              4096 Jul 24 21:39 libblockdev
drwxr-xr-x 4 root root              4096 Jul 24 21:39 polkit-1
drwxr-xr-x 3 root root              4096 Jul 24 21:39 ModemManager
drwxr-xr-x 3 root root              4096 Jul 24 21:39 NetworkManager
drwxr-xr-x 2 root root              4096 Jul 24 21:39 ldap
drwxr-xr-x 3 root root              4096 Jul 24 21:39 apparmor
-rw-r--r-- 1 root root                711 Jul 24 21:39 hosts.deny
-rw-r--r-- 1 root root                411 Jul 24 21:39 hosts.allow
drwxr-xr-x 2 root root              4096 Jul 24 21:39 calendar
drwxr-xr-x 2 root root              4096 Jul 24 21:39 modprobe.d
drwxr-xr-x 2 root root              4096 Jul 24 21:39 mdadm
drwxr-xr-x 2 root root              4096 Jul 24 21:39 byobu
drwxr-xr-x 2 root root              4096 Jul 24 21:39 tmpfiles.d
-rw-r--r-- 1 root root                146 Jul 24 21:39 shells
drwxr-xr-x 2 root root              4096 Jul 24 21:39 iscsi
drwxr-xr-x 2 root root              4096 Jul 24 21:40 groff
drwxr-xr-x 5 root root              4096 Jul 24 21:40 initramfs-tools
drwxr-xr-x 2 root root              4096 Jul 24 21:40 rsyslog.d
drwxr-xr-x 3 root root              4096 Jul 24 21:40 ufw
drwxr-xr-x 2 root root              4096 Jul 24 21:40 cryptsetup-initramfs
drwxr-xr-x 2 root root              4096 Jul 24 21:40 udisks2
drwxr-xr-x 3 root root              4096 Jul 24 21:40 apport
drwxr-xr-x 2 root root              4096 Jul 24 21:40 bash_completion.d
drwxr-xr-x 2 root root              4096 Jul 24 21:40 pollinate
drwxr-xr-x 3 root root              4096 Jul 24 21:40 fwupd
drwxr-xr-x 3 root root              4096 Jul 24 21:40 lvm
drwxr-xr-x 2 root root              4096 Jul 24 21:40 cron.weekly
drwxr-xr-x 2 root root              4096 Jul 24 21:40 PackageKit
-rw-r--r-- 1 root root                  33 Jul 24 21:40 ec2_version
drwxr-xr-x 2 root root              4096 Jul 24 21:40 console-setup
-rw-r--r-- 1 root root                    0 Jul 24 21:40 popularity-contest.conf
-rw-r--r-- 1 root root              9440 Jul 24 21:40 locale.gen
-rw-r--r-- 1 root root                112 Jul 24 21:40 overlayroot.local.conf
-rw-r--r-- 1 root root                  84 Jul 24 21:41 fstab
drwxr-xr-x 2 root root              4096 Jul 24 21:41 grub.d
drwxr-xr-x 2 root root              4096 Aug    1 05:31 netplan
drwxr-xr-x 3 root root              4096 Aug    1 05:32 qemu
drwxr-xr-x 4 root root              4096 Aug    1 05:32 cloud
-rw-r--r-- 1 root root                104 Aug 22 10:53 lsb-release
lrwxrwxrwx 1 root root                  21 Aug 22 10:54 os-release -> ../usr/lib/os-
release
-rw-r--r-- 1 root root                  19 Aug 22 10:54 issue.net
-rw-r--r-- 1 root root                  26 Aug 22 10:54 issue
drwx------ 2 root root              4096 Sep 14 10:23 multipath
-r--r--r-- 1 root root                  33 Sep 14 10:23 machine-id
-rw-r--r-- 1 root root                271 Sep 14 10:23 hosts
-rw-r--r-- 1 root root                    8 Sep 14 10:30 timezone
lrwxrwxrwx 1 root root                  27 Sep 14 10:30 localtime ->
/usr/share/zoneinfo/Etc/UTC
drwxr-xr-x 4 root root              4096 Sep 14 10:30 vmware-tools
drwxr-xr-x 4 root root              4096 Sep 14 13:28 ssh
drwxr-xr-x 2 root root              4096 Sep 20 06:33 vim
-rw-r--r-- 1 root root                  15 Sep 20 07:01 hostname
drwxr-xr-x 5 root root              4096 Sep 20 07:02 vulkan
drwxr-xr-x 7 root root              4096 Sep 20 07:02 X11
drwxr-xr-x 2 root root              4096 Sep 20 07:02 rcS.d
drwxr-xr-x 2 root root              4096 Sep 20 07:02 sensors.d
drwxr-xr-x 4 root root              4096 Sep 20 07:02 fonts
drwxr-xr-x 2 root root              4096 Sep 20 07:02 environment.d
drwxr-xr-x 5 root root              4096 Sep 20 07:02 java-11-openjdk
-rw-r--r-- 1 root root              3891 Sep 20 07:02 mailcap
drwxr-xr-x 2 root root              4096 Sep 24 19:46 process-exporter
drwxr-xr-x 2 root root              4096 Sep 25 11:29 wildfly
drwxr-xr-x 6 root root              4096 Sep 27 06:06 sos
drwxr-x--- 2 root root              4096 Oct    3 08:58 sudoers.d
drwxr-xr-x 8 root root              4096 Oct    3 12:32 nginx
drwxr-xr-x 8 root root              4096 Oct    3 15:25 apache2
drwxr-xr-x 2 root root              4096 Oct    3 15:25 cron.daily
-rw-r--r-- 1 root root                  98 Oct    4 07:58 subuid-
-rw-r--r-- 1 root root                  98 Oct    4 07:58 subgid-
drwxr-xr-x 2 root root              4096 Oct    4 08:24 profile.d
drwxr-xr-x 2 root root              4096 Oct    4 08:24 sysctl.d
drwxr-xr-x 2 root root              4096 Oct    4 08:24 modules-load.d
drwxr-xr-x 4 root root              4096 Oct    4 08:24 udev
drwxr-xr-x 3 root root              4096 Oct    4 08:24 update-manager
drwxr-xr-x 2 root root              4096 Oct    4 08:24 ubuntu-advantage
drwxr-xr-x 2 root root              4096 Oct    4 08:24 update-motd.d
drwxr-xr-x 5 root root              4096 Oct    4 08:24 systemd
drwxr-xr-x 2 root root              4096 Oct    4 08:24 pam.d
-rw-r----- 1 root shadow            875 Oct    4 08:45 gshadow-
-rw-r--r-- 1 root root              1048 Oct    4 08:45 group-
-rw-r--r-- 1 root root                123 Oct    4 08:45 subuid
-rw-r--r-- 1 root root                123 Oct    4 08:45 subgid
-rw-r----- 1 root shadow          1560 Oct    4 08:59 shadow-
-rw-r--r-- 1 root root              2130 Oct    4 08:59 passwd-
-rw-r--r-- 1 root root              1061 Oct    4 08:59 group
-rw-r----- 1 root shadow            885 Oct    4 08:59 gshadow
-rw-r----- 1 root shadow          1560 Oct    4 08:59 shadow
-rw-r--r-- 1 root root              2145 Oct    4 08:59 passwd
drwxr-xr-x 6 root root              4096 Oct    4 08:59 logcheck
drwxr-xr-x 3 root root              4096 Oct    4 08:59 php
drwxr-xr-x 2 root root              4096 Oct    4 08:59 cron.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 alternatives
drwxr-xr-x 7 root root              4096 Oct    4 08:59 apparmor.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 insserv.conf.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 init.d
drwxr-xr-x 3 root root              4096 Oct    4 08:59 default
drwxr-xr-x 2 root root              4096 Oct    4 08:59 logrotate.d
drwxr-xr-x 4 root root              4096 Oct    4 08:59 mysql
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc6.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc5.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc4.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc3.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc2.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc1.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc0.d
-rw-r--r-- 1 root root            31764 Oct    4 08:59 ld.so.cache
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp"
146.59.158.16 | CHANGED | rc=0 >>
total 48
drwx------ 3 root          root          4096 Aug 26 08:20 systemd-private-
588107954b074b39980b7c                                                               
ddbcfcdf42-systemd-logind.service-68Kuej
drwx------ 3 root          root          4096 Aug 26 08:20 systemd-private-
588107954b074b39980b7c                                                               
ddbcfcdf42-ModemManager.service-cIU2Ef
drwx------ 3 root          root          4096 Aug 26 08:20 snap.lxd
drwx------ 3 root          root          4096 Aug 31 21:07 snap.tree
drwxr-xr-x 2 root          root          4096 Sep 21 10:05 hsperfdata_root
drwxr-xr-x 2 wildfly    wildfly    4096 Sep 25 13:32 hsperfdata_wildfly
drwxr-xr-x 2 apx03        apx03        4096 Sep 26 09:17 hsperfdata_apx03
drwx------ 3 root          root          4096 Oct    2 17:36 systemd-private-
588107954b074b39980b7c                                                               
ddbcfcdf42-systemd-resolved.service-xYNRni
drwx------ 3 root          root          4096 Oct    2 17:36 systemd-private-
588107954b074b39980b7c                                                               
ddbcfcdf42-systemd-timesyncd.service-fMKZlf
-rwxrwxrwx 1 ansadmin ansadmin        0 Oct    3 10:15 cible1.txt
-rw-r--r-- 1 ansadmin ansadmin        0 Oct    4 08:16 test.txt
drwxr-xr-x 2 ansadmin ansadmin 4096 Oct    4 08:20 dir
drwxr-xr-x 2 root          root          4096 Oct    4 09:43 Debian
drwx------ 2 root          root          4096 Oct    4 09:45
ansible_command_payload_eh82ie9y
141.95.160.133 | CHANGED | rc=0 >>
total 44
drwx------ 3 root          root          4096 Sep 14 10:23 systemd-private-
0c62a6f1854e46959ec934                                                               
668ec6cc97-systemd-logind.service-pnYtUi
drwx------ 3 root          root          4096 Sep 14 10:23 systemd-private-
0c62a6f1854e46959ec934                                                               
668ec6cc97-ModemManager.service-1Rmclg
drwx------ 3 root          root          4096 Sep 14 10:23 snap.lxd
drwxr-xr-x 2 root          root          4096 Sep 21 09:23 hsperfdata_root
drwxr-xr-x 2 etl03        etl03        4096 Sep 21 10:24 hsperfdata_etl03
drwxr-xr-x 2 wildfly    wildfly    4096 Sep 25 15:04 hsperfdata_wildfly
-rw-r--r-- 1 ansadmin ansadmin        0 Oct    4 08:16 test.txt
drwxr-xr-x 2 ansadmin ansadmin 4096 Oct    4 08:20 dir
drwx------ 3 root          root          4096 Oct    4 08:24 systemd-private-
0c62a6f1854e46959ec934                                                               
668ec6cc97-systemd-resolved.service-dSPAvh
drwx------ 3 root          root          4096 Oct    4 08:24 systemd-private-
0c62a6f1854e46959ec934                                                               
668ec6cc97-systemd-timesyncd.service-XoIIlf
drwxr-xr-x 2 root          root          4096 Oct    4 09:43 Debian
drwx------ 2 root          root          4096 Oct    4 09:45
ansible_command_payload_rz12wo4b
ansadmin@svl200:~$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
──

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Tue Oct    4 08:53:18 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /etc | grep Deb"
146.59.158.16 | FAILED | rc=1 >>
non-zero return code
141.95.160.133 | FAILED | rc=1 >>
non-zero return code
ansadmin@svl200:~$ ansible-playbook rep.yaml

PLAY [Creation de repertoire]


*********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation]
***********************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]
TASK [Creation]
***********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
1      rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
1      rescued=0        ignored=0

ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /etc | grep Deb"
146.59.158.16 | FAILED | rc=1 >>
non-zero return code
141.95.160.133 | FAILED | rc=1 >>
non-zero return code
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /etc | grep redhat"
146.59.158.16 | FAILED | rc=1 >>
non-zero return code
141.95.160.133 | FAILED | rc=1 >>
non-zero return code
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook rep.yaml

PLAY [Creation de repertoire]


*********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation]
***********************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation]
***********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
1      rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
1      rescued=0        ignored=0
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim rep.yaml
ansadmin@svl200:~$ ansible-playbook rep.yaml

PLAY [Creation de repertoire]


*********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation repertoire]


************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation repertoire]


************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation fichier]


***************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation fichier]


***************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=3      changed=1      unreachable=0   
failed=0        skipped=                                                             
2      rescued=0        ignored=0
146.59.158.16                            : ok=3      changed=1      unreachable=0 
failed=0        skipped=                                                             
2      rescued=0        ignored=0

ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/redhat | grep redhat"
146.59.158.16 | FAILED | rc=1 >>
ls: cannot access '/tmp/redhat': No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=1 >>
ls: cannot access '/tmp/redhat': No such file or directorynon-zero return code
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/redhat"
146.59.158.16 | FAILED | rc=2 >>
ls: cannot access '/tmp/redhat': No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=2 >>
ls: cannot access '/tmp/redhat': No such file or directorynon-zero return code
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/Redhat"
146.59.158.16 | FAILED | rc=2 >>
ls: cannot access '/tmp/Redhat': No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=2 >>
ls: cannot access '/tmp/Redhat': No such file or directorynon-zero return code
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/Debian"
146.59.158.16 | CHANGED | rc=0 >>
total 0
-rw-r--r-- 1 root root 0 Oct    4 09:57 Debian.txt
141.95.160.133 | CHANGED | rc=0 >>
total 0
-rw-r--r-- 1 root root 0 Oct    4 09:57 Debian.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/Debian"
146.59.158.16 | CHANGED | rc=0 >>
total 0
-rw-r--r-- 1 root root 0 Oct    4 09:57 Debian.txt
141.95.160.133 | CHANGED | rc=0 >>
total 0
-rw-r--r-- 1 root root 0 Oct    4 09:57 Debian.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook list.yaml

PLAY [exemple ansible list]


***********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install package]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim list.yaml
ansadmin@svl200:~$ sudo vim list.yaml
ansadmin@svl200:~$ ansible-playbook list.yaml

PLAY [exemple ansible list]


***********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [install package]
****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ ansible-playbook items.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


*************************************************
changed: [146.59.158.16] => (item=init1.txt)
changed: [141.95.160.133] => (item=init1.txt)
changed: [146.59.158.16] => (item=init2.txt)
changed: [141.95.160.133] => (item=init2.txt)
changed: [146.59.158.16] => (item=init3.txt)
changed: [141.95.160.133] => (item=init3.txt)
changed: [146.59.158.16] => (item=init4.txt)
changed: [141.95.160.133] => (item=init4.txt)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ ansible-playbook items.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


*************************************************
changed: [146.59.158.16] => (item=init1.txt)
changed: [141.95.160.133] => (item=init1.txt)
changed: [146.59.158.16] => (item=init2.txt)
changed: [141.95.160.133] => (item=init2.txt)
changed: [146.59.158.16] => (item=init3.txt)
changed: [141.95.160.133] => (item=init3.txt)
changed: [146.59.158.16] => (item=init4.txt)
changed: [141.95.160.133] => (item=init4.txt)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init4.txt
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init4.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | grep init"
146.59.158.16 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init4.txt
141.95.160.133 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init4.txt
ansadmin@svl200:~$ sudo vim items_users.yaml
ansadmin@svl200:~$ sudo -f items_users.yaml
sudo: invalid option -- 'f'
usage: sudo -h | -K | -k | -V
usage: sudo -v [-AknS] [-g group] [-h host] [-p prompt] [-u user]
usage: sudo -l [-AknS] [-g group] [-h host] [-p prompt] [-U user] [-u user] [command]
usage: sudo [-AbEHknPS] [-r role] [-t type] [-C num] [-g group] [-h host] [-p prompt]
                        [-T timeout] [-u user] [VAR=value] [-i|-s] [<command>]
usage: sudo -e [-AknS] [-r role] [-t type] [-C num] [-g group] [-h host] [-p prompt]
                        [-T timeout] [-u user] file ...
ansadmin@svl200:~$
ansadmin@svl200:~$ rm items_users.yaml
rm: remove write-protected regular empty file 'items_users.yaml'?
ansadmin@svl200:~$
ansadmin@svl200:~$ cp items.yaml item_users.yaml
ansadmin@svl200:~$ sudo vim items_users.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo3.yaml      handler.yaml          items.yaml               
rep.yaml              when.yaml
debug.yaml      exo4.yaml      index.html              items_users.yaml    seq.yaml 
when1.yaml
debug1.yaml    fact.yaml      ip.txt                      list.yaml                 
shell.yml
exo2.yaml        fact1.yaml    item_users.yaml    nginx.yaml               
template.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo3.yaml      handler.yaml          items.yaml               
rep.yaml              when.yaml
debug.yaml      exo4.yaml      index.html              items_users.yaml    seq.yaml 
when1.yaml
debug1.yaml    fact.yaml      ip.txt                      list.yaml                 
shell.yml
exo2.yaml        fact1.yaml    item_users.yaml    nginx.yaml               
template.yaml
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefin                                                                             
ed variable. The error was: 'user' is undefined\n\nThe error appears to be in
'/home/an                                                                           
sadmin/item_users.yaml': line 7, column 5, but may\nbe elsewhere in the file
depending                                                                            
on the exact syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n   
- name                                                                               
: creation d'utilisateurs\n        ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefi                                                                               
ned variable. The error was: 'user' is undefined\n\nThe error appears to be in
'/home/a                                                                             
nsadmin/item_users.yaml': line 7, column 5, but may\nbe elsewhere in the file
depending                                                                           
on the exact syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n   
- nam                                                                               
e: creation d'utilisateurs\n        ^ here\n"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [creation d'utilisateurs]
********************************************************
failed: [146.59.158.16] (item=user1.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user1.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user1.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user1.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}
failed: [146.59.158.16] (item=user2.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user2.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user2.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user2.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}
failed: [146.59.158.16] (item=user3.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user3.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user3.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user3.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}
failed: [146.59.158.16] (item=user4.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user4.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user4.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user4.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}^L
failed: [146.59.158.16] (item=user5.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user5.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user5.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user5.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
failed: [146.59.158.16] (item=user1.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user1.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user1.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user1.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}
failed: [146.59.158.16] (item=user2.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user2.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user2.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user2.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}
failed: [146.59.158.16] (item=user3.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user3.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user3.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user3.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}
failed: [146.59.158.16] (item=user4.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user4.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user4.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user4.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}
failed: [146.59.158.16] (item=user5.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user5.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user5.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user5.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                              
uid, update_password"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
changed: [146.59.158.16] => (item=user1.txt)
changed: [141.95.160.133] => (item=user1.txt)
ok: [146.59.158.16] => (item=user2.txt)
ok: [141.95.160.133] => (item=user2.txt)
ok: [146.59.158.16] => (item=user3.txt)
ok: [141.95.160.133] => (item=user3.txt)
ok: [146.59.158.16] => (item=user4.txt)
ok: [141.95.160.133] => (item=user4.txt)
ok: [146.59.158.16] => (item=user5.txt)
ok: [141.95.160.133] => (item=user5.txt)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim item_users.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
ok: [146.59.158.16] => (item=user1.txt)
ok: [141.95.160.133] => (item=user1.txt)
ok: [146.59.158.16] => (item=user2.txt)
ok: [141.95.160.133] => (item=user2.txt)
ok: [146.59.158.16] => (item=user3.txt)
ok: [141.95.160.133] => (item=user3.txt)
ok: [146.59.158.16] => (item=user4.txt)
ok: [141.95.160.133] => (item=user4.txt)
ok: [146.59.158.16] => (item=user5.txt)
ok: [141.95.160.133] => (item=user5.txt)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

    System information as of Tue Oct    4 12:03:00 UTC 2022

    System load:                      0.91


    Usage of /:                        13.7% of 38.58GB
    Memory usage:                    48%
    Swap usage:                        0%
    Processes:                          139
    Users logged in:              1
    IPv4 address for ens3: 146.59.156.114
    IPv6 address for ens3: 2001:41d0:304:200::9356

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Tue Oct    4 09:46:14 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$ ansible-playbook seq.yaml
PLAY [exemple avec items]
*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


*************************************************
changed: [146.59.158.16] => (item=20)
changed: [141.95.160.133] => (item=20)
changed: [146.59.158.16] => (item=21)
changed: [141.95.160.133] => (item=21)
changed: [146.59.158.16] => (item=22)
changed: [141.95.160.133] => (item=22)
changed: [146.59.158.16] => (item=23)
changed: [141.95.160.133] => (item=23)
changed: [146.59.158.16] => (item=24)
changed: [141.95.160.133] => (item=24)
changed: [146.59.158.16] => (item=25)
changed: [141.95.160.133] => (item=25)
changed: [146.59.158.16] => (item=26)
changed: [141.95.160.133] => (item=26)
changed: [146.59.158.16] => (item=27)
changed: [141.95.160.133] => (item=27)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim rep.yaml


ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp"
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | Dev"
146.59.158.16 | FAILED | rc=127 >>
/bin/sh: 1: Dev: not foundnon-zero return code
141.95.160.133 | FAILED | rc=127 >>
/bin/sh: 1: Dev: not foundnon-zero return code
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | grep Dev"
^[[C146.59.158.16 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops27.txt
141.95.160.133 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops27.txt
ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim copie.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo2.yaml    fact1.yaml        item_users.yaml      nginx.yaml   
template.yaml
copie.yaml      exo3.yaml    handler.yaml    items.yaml                rep.yaml     
when.yaml
debug.yaml      exo4.yaml    index.html        items_users.yaml    seq.yaml       
when1.yaml
debug1.yaml    fact.yaml    ip.txt                list.yaml                 
shell.yml
ansadmin@svl200:~$ sudo vim copie.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo2.yaml    fact1.yaml        item_users.yaml      nginx.yaml   
template.yaml
copie.yaml      exo3.yaml    handler.yaml    items.yaml                rep.yaml     
when.yaml
debug.yaml      exo4.yaml    index.html        items_users.yaml    seq.yaml       
when1.yaml
debug1.yaml    fact.yaml    ip.txt                list.yaml                 
shell.yml
ansadmin@svl200:~$ sudo vim copie.yaml
ansadmin@svl200:~$ sudo vim copie.yaml
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Could not find or
access                                                                              
'index.html.j2'\nSearched
in:\n\t/home/ansadmin/templates/index.html.j2\n\t/home/ansadm                       
in/index.html.j2\n\t/home/ansadmin/templates/index.html.j2\n\t/home/ansadmin/
index.html                                                                           
.j2 on the Ansible Controller.\nIf you are using a module and expect the file to
exist                                                                                
on the remote, see the remote_src option"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Could not find or
access                                                                               
'index.html.j2'\nSearched
in:\n\t/home/ansadmin/templates/index.html.j2\n\t/home/ansad                         
min/index.html.j2\n\t/home/ansadmin/templates/index.html.j2\n\t/home/ansadmin/
index.htm                                                                           
l.j2 on the Ansible Controller.\nIf you are using a module and expect the file to
exist                                                                               
on the remote, see the remote_src option"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ 146.59.158.16^C
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************
TASK [Gathering Facts]
****************************************************************
ok: [141.95.160.133]
ok: [146.59.158.16]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable:                                                           
'ansible_all_ipv4_adresses' is undefined"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable                                                           
: 'ansible_all_ipv4_adresses' is undefined"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim index.html.j2


ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable:                                                           
'ansible_all_ipv4_adresses' is undefined"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable                                                           
: 'ansible_all_ipv4_adresses' is undefined"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml
PLAY [exemple avec template]
**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim index.html.j2


ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ cp index.html.j2 index.html1.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml
PLAY [exemple avec template]
**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable:                                                           
'ansible_user' is undefined"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable                                                           
: 'ansible_user' is undefined"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable:                                                           
'ansible_ssh_user' is undefined"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable                                                           
: 'ansible_ssh_user' is undefined"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ cp template.yaml template1.yaml
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: user, template

The error appears to be in '/home/ansadmin/template1.yaml': line 10, column 7, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - user:
            ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo4.yaml            index.html1.j2        nginx.yaml           
when.yaml
copie.yaml      fact.yaml            ip.txt                        rep.yaml         
when1.yaml
debug.yaml      fact1.yaml          item_users.yaml      seq.yaml
debug1.yaml    handler.yaml      items.yaml                shell.yml
exo2.yaml        index.html          items_users.yaml    template.yaml
exo3.yaml        index.html.j2    list.yaml                  template1.yaml
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: user, template

The error appears to be in '/home/ansadmin/template1.yaml': line 7, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: user, template

The error appears to be in '/home/ansadmin/template1.yaml': line 9, column 7, but may


be elsewhere in the file depending on the exact syntax problem.
The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: template, src

The error appears to be in '/home/ansadmin/template1.yaml': line 10, column 7, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: template, src

The error appears to be in '/home/ansadmin/template1.yaml': line 10, column 7, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: template, src

The error appears to be in '/home/ansadmin/template1.yaml': line 10, column 7, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$ w
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! A malformed block was encountered while loading tasks: {'template': None,
'src':                                                                               
'index.html1', 'dest': '/var/www/html/index.html1'} should be a list or None but is
<c                                                                                   
lass 'ansible.parsing.yaml.objects.AnsibleMapping'>

The error appears to be in '/home/ansadmin/template1.yaml': line 2, column 3, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: exemple avec template
    ^ here
ansadmin@svl200:~$ wq
wq: command not found
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-vault create hello.yml
New Vault password: [ERROR]: User interrupted execution
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-vault create hello.yaml
New Vault password:
Confirm New Vault password:
ansadmin@svl200:~$ cp
.ansible/                    cible1.txt                  handler.yaml             
list.yaml
.bash_history            copie.yaml                  hello.yaml                 
nginx.yaml
.bash_logout              debug.yaml                  index.html                 
rep.yaml
.bashrc                        debug1.yaml                index.html.j2           
seq.yaml
.exo4.yaml.swp          exo2.yaml                    index.html1.j2         
shell.yml
.handler.yaml.swp    exo3.yaml                    ip.txt                         
template.yaml
.profile                      exo4.yaml                    item_users.yaml       
template1.yaml
.ssh/                            fact.yaml                    items.yaml             
when.yaml
.viminfo                      fact1.yaml                  items_users.yaml     
when1.yaml
ansadmin@svl200:~$ cat template1.yaml >> hello.yaml
ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$ ansible-playbook hello.yaml
ERROR! Syntax Error while loading YAML.
    found unexpected end of stream

The error appears to be in '/home/ansadmin/hello.yaml': line 15, column 1, but may


be elsewhere in the file depending on the exact syntax problem.

(specified line no longer in file, maybe it changed?)


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook hello.yaml --ask-vault-pass
Vault password:
ERROR! Syntax Error while loading YAML.
    found unexpected end of stream

The error appears to be in '/home/ansadmin/hello.yaml': line 15, column 1, but may


be elsewhere in the file depending on the exact syntax problem.

(specified line no longer in file, maybe it changed?)


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-vault edit
Vault password:
ansadmin@svl200:~$ ansible-vault create hello.yml
New Vault password:
Confirm New Vault password:
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$ ansible-playbook hello.yaml --ask-vault-pass
Vault password:
ERROR! Syntax Error while loading YAML.
    found unexpected end of stream

The error appears to be in '/home/ansadmin/hello.yaml': line 15, column 1, but may


be elsewhere in the file depending on the exact syntax problem.

(specified line no longer in file, maybe it changed?)


ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook hello.yaml --ask-vault-pass
Vault password:
[WARNING]: Found variable using reserved name: port

PLAY [play with vault]


***********************************************************************************

TASK [Gathering Facts]


***********************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo variable]


*************************************************************************************
ok: [146.59.158.16] => {
        "msg": "L'utilisateur ofi03 utilise le port 80 sur la machine master-wildfly"
}
ok: [141.95.160.133] => {
        "msg": "L'utilisateur ofi03 utilise le port 80 sur la machine slave1-wildfly"
}

PLAY RECAP
*************************************************************************************
**********
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        i                                 
gnored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        i                                 
gnored=0
ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$ ansible-vault encrypt when2.yaml
New Vault password:
Confirm New Vault password:
ERROR! Unable to read source file (/home/ansadmin/when2.yaml): [Errno 2] No such file
or directory: '/home                                                                 
/ansadmin/when2.yaml'
ansadmin@svl200:~$ ansible-vault encrypt hello.yaml
New Vault password:
Confirm New Vault password:
Encryption successful
ansadmin@svl200:~$
ansadmin@svl200:~$ cat hello.y
hello.yaml    hello.yml
ansadmin@svl200:~$ cat hello.yaml
$ANSIBLE_VAULT;1.1;AES256
36393466663530663832326138373032333162303465386232666666643638646130303137366137
6137666236326535653833333234373237343936613331340a383331316661363235323737336239
35313137363135336663326139383730336265613532353038303633346337313964643666346538
6363333135363636350a623231333466643832636463383635663564623636633931353861373938
31663065653239396361386539323035663065656332383738303733313365376234376532363235
64393030303066363362626234626334623062306632626231353965333361373036633463363432
62653336663163336666616566653065656236613736663736393530316263636638633130396264
35333465623035633165366131386230363137366537386534646334373537376563343662323134
37643633303237616466383633363338383831386136666231363332323334613061366230326430
31313661616266373233653461613237633934306363316664313365333937626163623764333039
63646336383939313362303630333863373630626361333135623137323463333431663366396565
34353865393865363737316233363131393432333363306365613037653736343433646561613937
64393663353432363736646535386263666266376231376532356430363761636266663332346530
65633634653730396639393933386434326130313165663437373939633132393031373661653530
33616464633335643666616465633964336461613436303231643636333035656366333931636365
31353261376431613431323563333137633165613033343937353162393161353433396137633232
3239
ansadmin@svl200:~$ ansible-vault decrypt hello.yaml
Vault password:
Decryption successful
ansadmin@svl200:~$ cat hello.yaml
---
- name: play with vault
    hosts: all
    become: true

    vars:
          - user: ofi03
          - port: 80

    tasks:
          - name: echo variable
              debug:
                  msg: "L'utilisateur {{user}} utilise le port {{port}} sur la
machine {{ansible_hostname}}"

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim play-vars.yaml
ansadmin@svl200:~$ ansible-playbook play-vars.yaml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


*********************************************************************

TASK [Gathering Facts]


*************************************************************************************
*
ok: [141.95.160.133]
ok: [146.59.158.16]

TASK [Affichage nom distribution et version]


****************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "template error while templating string:
expected token 'end of pr                                                           
int statement', got 'distribution'. String: Le nom de la distribution est {{ansible
distribution}} et la vers                                                           
ion est {{ansible_version}}"}
fatal: [141.95.160.133]: FAILED! => {"msg": "template error while templating string:
expected token 'end of p                                                             
rint statement', got 'distribution'. String: Le nom de la distribution est {{ansible
distribution}} et la ver                                                             
sion est {{ansible_version}}"}

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        igno                               
red=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        igno                               
red=0

ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-vault create play-vars.yml
New Vault password:
Confirm New Vault password:
ansadmin@svl200:~$ cat play-vars.yaml >> play-vars.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim play-vars.yml
ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


*********************************************************************

TASK [Gathering Facts]


*************************************************************************************
*
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


****************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "template error while templating string:
expected token 'end of pr                                                           
int statement', got 'distribution'. String: Le nom de la distribution est {{ansible
distribution}} et la vers                                                           
ion est {{ansible_version}}"}
fatal: [141.95.160.133]: FAILED! => {"msg": "template error while templating string:
expected token 'end of p                                                             
rint statement', got 'distribution'. String: Le nom de la distribution est {{ansible
distribution}} et la ver                                                             
sion est {{ansible_version}}"}

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        igno                               
red=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        igno                               
red=0

ansadmin@svl200:~$ sudo vim play-vars.yml


ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


*********************************************************************

TASK [Gathering Facts]


*************************************************************************************
*
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


****************************************************************
ok: [146.59.158.16] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full': '2.9.6', 'majo                                                     
r': 2, 'minor': 9, 'revision': 6}"
}
ok: [141.95.160.133] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full': '2.9.6', 'majo                                                     
r': 2, 'minor': 9, 'revision': 6}"
}

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0

ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


*********************************************************************

TASK [Gathering Facts]


*************************************************************************************
*
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


****************************************************************
ok: [146.59.158.16] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full': '2.9.6', 'majo                                                     
r': 2, 'minor': 9, 'revision': 6}"
}
ok: [141.95.160.133] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full': '2.9.6', 'majo                                                     
r': 2, 'minor': 9, 'revision': 6}"
}

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0

ansadmin@svl200:~$ sudo vim play-vars.yml


ansadmin@svl200:~$ ansible ansiblecli -m setup | grep "version"
[WARNING]: Could not match supplied host pattern, ignoring: ansiblecli
[WARNING]: No hosts matched, nothing to do
ansadmin@svl200:~$ ansible ansiblecli -m setup | grep "version"
[WARNING]: Could not match supplied host pattern, ignoring: ansiblecli
[WARNING]: No hosts matched, nothing to do
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


*********************************************************************

TASK [Gathering Facts]


*************************************************************************************
*
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


****************************************************************
ok: [146.59.158.16] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full': '2.9.6', 'majo                                                     
r': 2, 'minor': 9, 'revision': 6}"
}
ok: [141.95.160.133] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full': '2.9.6', 'majo                                                     
r': 2, 'minor': 9, 'revision': 6}"
}

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0

ansadmin@svl200:~$ sudo vim play-vars.yml


ansadmin@svl200:~$ sudo vim play-vars.yml
ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


*********************************************************************

TASK [Gathering Facts]


*************************************************************************************
*
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


****************************************************************
ok: [146.59.158.16] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est 20"
}
ok: [141.95.160.133] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est 20"
}

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim locale.yml
ansadmin@svl200:~$ cat play-vars.yml >> locale.yml
-bash: locale.yml: Permission denied
ansadmin@svl200:~$ sudo cat play-vars.yml >> locale.yml
-bash: locale.yml: Permission denied
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim play-vars.yml
ansadmin@svl200:~$ sudo vim locale.yml
ansadmin@svl200:~$ ansible-playbook locale.yml
ERROR! Syntax Error while loading YAML.
    found unacceptable key (unhashable type: 'AnsibleMapping')

The error appears to be in '/home/ansadmin/locale.yml': line 12, column 15, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

            debug:
                msg: {{port_http}}
                            ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim locale.yml
ansadmin@svl200:~$ ansible-playbook locale.yml

PLAY [Affichage d'une variable locale]


**********************************************************************

TASK [Gathering Facts]


*************************************************************************************
*
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [var locale port]


*************************************************************************************
*
ok: [146.59.158.16] => {
        "msg": 8080
}
ok: [141.95.160.133] => {
        "msg": 8080
}

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        igno                               
red=0

ansadmin@svl200:~$ sudo vim locale.yml


ansadmin@svl200:~$ sudo vim play-vars.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic.yml
ansadmin@svl200:~$ ansible-playbook var_dic.yml
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/var_dic.yml': line 13, column 32, but m   


ay
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                        debug:
                            msg: "{{service["name"]    {{service.rpm}}"
                                                              ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic.yml
ansadmin@svl200:~$ ansible-playbook var_dic.yml

PLAY [variable locale de type dictionnaire] **************************************

TASK [Gathering Facts] ***********************************************************


ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [var dict] ******************************************************************


ok: [146.59.158.16] => {
        "msg": "apache et httpd"
}
ok: [141.95.160.133] => {
        "msg": "apache et httpd"
}

PLAY RECAP ***********************************************************************


141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        ski                                                                 
pped=0        rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        ski                                                                 
pped=0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ cp var_dic.yml var_dic1.yml
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14, found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14, found a duplicate dict key (rpm). Using last defined value only.

PLAY [variable locale de type dictionnaire] **************************************

TASK [Gathering Facts] ***********************************************************


ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [var dict] ******************************************************************


fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an un   
defined variable. The error was: 'None' has no attribute 'name'\n\nThe error appea   
rs to be in '/home/ansadmin/var_dic1.yml': line 15, column 13, but may\nbe elsewhe   
re in the file depending on the exact syntax problem.\n\nThe offending line appear   
s to be:\n\n    tasks:\n                    - name: var dict\n                       
^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an u   
ndefined variable. The error was: 'None' has no attribute 'name'\n\nThe error appe   
ars to be in '/home/ansadmin/var_dic1.yml': line 15, column 13, but may\nbe elsewh   
ere in the file depending on the exact syntax problem.\n\nThe offending line appea   
rs to be:\n\n    tasks:\n                    - name: var dict\n                     
^ here\n"}

PLAY RECAP ***********************************************************************


141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      ski                                                                   
pped=0        rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      ski                                                                   
pped=0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    found unexpected end of stream

The error appears to be in '/home/ansadmin/var_dic1.yml': line 20, column 1, but m   


ay
be elsewhere in the file depending on the exact syntax problem.

(specified line no longer in file, maybe it changed?)


ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14, found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14, found a duplicate dict key (rpm). Using last defined value only.

PLAY [variable locale de type dictionnaire]


********************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [var dict]


************************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "template error while templating string:
unex                                                                                 
pected '}'. String: {{service[type]['name']}} et {{service[type]['rpm']}"}
fatal: [141.95.160.133]: FAILED! => {"msg": "template error while templating string:
une                                                                                 
xpected '}'. String: {{service[type]['name']}} et {{service[type]['rpm']}"}

PLAY RECAP
*****************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14,
found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14,
found a duplicate dict key (rpm). Using last defined value only.
ERROR! conflicting action statements: debug, msg

The error appears to be in '/home/ansadmin/var_dic1.yml': line 15, column 9, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


    tasks:
            - name: var dict
                ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column
14, found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column
14, found a duplicate dict key (rpm). Using last defined value only.
ERROR! conflicting action statements: debug, msg

The error appears to be in '/home/ansadmin/var_dic1.yml': line 15, column 5, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
    - name: var dict
        ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/var_dic1.yml': line 13, column 14, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  name: mariadb
                    rpm: mariadb-server
                          ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/var_dic1.yml': line 13, column 14, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  name: mariadb
                    rpm: mariadb-server
                          ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context
The error appears to be in '/home/ansadmin/var_dic1.yml': line 13, column 14, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  name: mariadb
                    rpm: mariadb-server
                          ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/var_dic1.yml': line 13, column 14, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  name: mariadb
                    rpm: mariadb-server
                          ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service apache    httpd"
}
ok: [141.95.160.133] => {
        "msg": "Le service apache    httpd"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic1.yml


ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
PLAY [variable locale de type dictionnaire]
************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service apache era installé par le paquethttpd"
}
ok: [141.95.160.133] => {
        "msg": "Le service apache era installé par le paquethttpd"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service mariadb era installé par le paquetmariadb-server"
}
ok: [141.95.160.133] => {
        "msg": "Le service mariadb era installé par le paquetmariadb-server"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic1.yml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}
ok: [141.95.160.133] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic1.yml


ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/var_dic1.yml': line 11, column 9, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                    rpm: httpd
                db:
                ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [variable dictionnaire]
***************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined va                                                                         
riable. The error was: 'list object' has no attribute 'db'\n\nThe error appears to be
in '/h                                                                               
ome/ansadmin/var_dic1.yml': line 16, column 5, but may\nbe elsewhere in the file
depending o                                                                         
n the exact syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n    -
name: vari                                                                           
able dictionnaire\n        ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefined v                                                                         
ariable. The error was: 'list object' has no attribute 'db'\n\nThe error appears to
be in '/                                                                             
home/ansadmin/var_dic1.yml': line 16, column 5, but may\nbe elsewhere in the file
depending                                                                            
on the exact syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n   
- name: var                                                                         
iable dictionnaire\n        ^ here\n"}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}
ok: [141.95.160.133] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ cp vim var_dic1.yml var_dic2.yml
cp: target 'var_dic2.yml' is not a directory
ansadmin@svl200:~$ cp var_dic1.yml var_dic2.yml
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ mv var_dic2.yml vars.yml
ansadmin@svl200:~$ sudo vim vars.yml
ansadmin@svl200:~$ sudo vim vars_files.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ mv var_dic2.yml vars.yml
mv: cannot stat 'var_dic2.yml': No such file or directory
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ mv var_dic1.yml var
var_dic.yml      var_dic1.yml    vars.yml
ansadmin@svl200:~$ mv var_dic1.yml var_dic2.yml
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ ansible-playbook var_dic2.yml
ERROR! 'vars_file' is not a valid attribute for a Play

The error appears to be in '/home/ansadmin/var_dic2.yml': line 2, column 3, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: variable locale de type dictionnaire
    ^ here
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ ansible-playbook var_dic2.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}
ok: [141.95.160.133] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic2.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}
ok: [141.95.160.133] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic2.yml --extra-vars="type=web"

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service apache sera installé par le paquethttpd"
}
ok: [141.95.160.133] => {
        "msg": "Le service apache sera installé par le paquethttpd"
}
PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic2.yml


ansadmin@svl200:~$
ansadmin@svl200:~$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
───────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
Remote side unexpectedly closed network connection

─────────────────────────────────────────────────────────────────────────────────────
───────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘
Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

10 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Tue Oct    4 12:03:03 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ ls
cible1.txt      exo4.yaml          index.html              items_users.yaml   
rep.yaml                var_dic2.yml
copie.yaml      fact.yaml          index.html.j2        list.yaml                 
seq.yaml                vars.yml
debug.yaml      fact1.yaml        index.html1.j2      locale.yml               
shell.yml              when.yaml
debug1.yaml    handler.yaml    ip.txt                      nginx.yaml               
template.yaml      when1.yaml
exo2.yaml        hello.yaml        item_users.yaml    play-vars.yaml       
template1.yaml
exo3.yaml        hello.yml          items.yaml              play-vars.yml         
var_dic.yml
ansadmin@svl200:~$ cp var_dic2.yml var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim vars_multi.yml
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ ansible-playbook var_dic
var_dic.yml                  var_dic2.yml                var_dic_multi3.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi3.yml
ERROR! Syntax Error while loading YAML.
    found unacceptable key (unhashable type: 'AnsibleMapping')
The error appears to be in '/home/ansadmin/var_dic_multi3.yml': line 11, column 15,
but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

        user:
              name: {{item.key}}
                            ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic_multi3.yml

PLAY [variable locale de type dictionnaire multi dimensions]


*******************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire MultiDim]


******************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined va                                                                         
riable. The error was: 'item' is undefined\n\nThe error appears to be in
'/home/ansadmin/var                                                                 
_dic_multi3.yml': line 9, column 5, but may\nbe elsewhere in the file depending on
the exact                                                                           
syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n    - name:
variable dictio                                                                     
nnaire MultiDim\n        ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefined v                                                                         
ariable. The error was: 'item' is undefined\n\nThe error appears to be in
'/home/ansadmin/va                                                                   
r_dic_multi3.yml': line 9, column 5, but may\nbe elsewhere in the file depending on
the exac                                                                             
t syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n    - name:
variable dicti                                                                       
onnaire MultiDim\n        ^ here\n"}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi3.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/var_dic_multi3.yml': line 10, column 11,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: variable dictionnaire MultiDim


            user:
                    ^ here
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim vars_multi.yml
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi3.yml

PLAY [variable locale de type dictionnaire multi dimensions]


*******************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire MultiDim]


******************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined va                                                                         
riable. The error was: 'item' is undefined\n\nThe error appears to be in
'/home/ansadmin/var                                                                 
_dic_multi3.yml': line 9, column 5, but may\nbe elsewhere in the file depending on
the exact                                                                           
syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n    - name:
variable dictio                                                                     
nnaire MultiDim\n        ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefined v                                                                         
ariable. The error was: 'item' is undefined\n\nThe error appears to be in
'/home/ansadmin/va                                                                   
r_dic_multi3.yml': line 9, column 5, but may\nbe elsewhere in the file depending on
the exac                                                                             
t syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n    - name:
variable dicti                                                                       
onnaire MultiDim\n        ^ here\n"}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic_multi3.yml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic_multi3.yml
ERROR! Syntax Error while loading YAML.
    found unacceptable key (unhashable type: 'AnsibleMapping')

The error appears to be in '/home/ansadmin/var_dic_multi3.yml': line 11, column 16,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

        user:
                name: {{item.key}}
                              ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~$ ansible-playbook var_dic_multi3.yml
ERROR! Syntax Error while loading YAML.
    found unacceptable key (unhashable type: 'AnsibleMapping')

The error appears to be in '/home/ansadmin/var_dic_multi3.yml': line 11, column 16,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

        user:
                name: {{item.key}}
                              ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:
        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic_multi3.yml

PLAY [variable locale de type dictionnaire multi dimensions]


*******************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire MultiDim]


******************************************************
changed: [146.59.158.16] => (item={'key': 'antoine', 'value': {'group': 'users',
'state': 'p                                                                         
resent'}})
changed: [141.95.160.133] => (item={'key': 'antoine', 'value': {'group': 'users',
'state': '                                                                           
present'}})
changed: [146.59.158.16] => (item={'key': 'erwan', 'value': {'group': 'users',
'state': 'pre                                                                       
sent'}})
changed: [141.95.160.133] => (item={'key': 'erwan', 'value': {'group': 'users',
'state': 'pr                                                                         
esent'}})
ok: [146.59.158.16] => (item={'key': 'philippe', 'value': {'group': 'users', 'state':
'absen                                                                               
t'}})
ok: [141.95.160.133] => (item={'key': 'philippe', 'value': {'group': 'users',
'state': 'abse                                                                       
nt'}})

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=1      unreachable=0   
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=1      unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic_multi3.yml


ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ cat var_dic_multi3.yml
---
- name: variable locale de type dictionnaire multi dimensions
    hosts: all
    become: true
    vars_files:
        - /home/ansadmin/vars_multi.yml

    tasks:
    - name: variable dictionnaire MultiDim
        user:
                name: "{{item.key}}"
                group: "{{item.value.group}}"
                state: "{{item.value.state}}"
        [email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

Last login: Mon Oct    3 08:26:57 2022 from 176.160.191.208


ofi03@svl200:~$
Network error: Software caused connection abort
~
────────────────────────────────────────────────────────────────────────────────
~
Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
"handler.yaml" [New File]                                                           
0,0-1                  All
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Mon Oct    3 13:13:55 2022 from 176.160.191.208
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ vim handler.yaml
ansadmin@svl200:~$ sudo vim handler.yaml
ansadmin@svl200:~$ sudo vim index.html
ansadmin@svl200:~$ ansible-playbook handler.yaml

PLAY [configure webserver with nginx]


************************************************

TASK [Gathering Facts]


***************************************************************
ok: [146.59.158.16]

TASK [install    nginx]


****************************************************************
ok: [146.59.158.16]

TASK [copy index.html]


***************************************************************
changed: [146.59.158.16]
RUNNING HANDLER [restart_nginx]
******************************************************
changed: [146.59.158.16]

PLAY RECAP
***************************************************************************
146.59.158.16                            : ok=4        changed=2        unreachable=0
failed=0        skipped                                                             
=0        rescued=0        ignored=0

ansadmin@svl200:~$ 146.59.158.16 ^C
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$ sudo vim handler.yaml
ansadmin@svl200:~$ ansible-playbook handler.yaml
[WARNING]: Could not match supplied host pattern, ignoring: cible{1
[WARNING]: Could not match supplied host pattern, ignoring: 2}

PLAY [configure webserver with nginx]


************************************************
skipping: no hosts matched

PLAY RECAP
***************************************************************************

ansadmin@svl200:~$ sudo vim handler.yaml


ansadmin@svl200:~$ ansible-playbook handler.yaml

PLAY [configure webserver with nginx]


************************************************

TASK [Gathering Facts]


***************************************************************
ok: [141.95.160.133]
ok: [146.59.158.16]

TASK [install    nginx]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [copy index.html]


***************************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

RUNNING HANDLER [restart_nginx]


******************************************************
changed: [141.95.160.133]

PLAY RECAP
***************************************************************************
141.95.160.133                          : ok=4        changed=2        unreachable=0 
failed=0        skipped                                                             
=0        rescued=0        ignored=0
146.59.158.16                            : ok=3        changed=0        unreachable=0
failed=0        skipped                                                             
=0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim handler.yaml


ansadmin@svl200:~$ ansible-playbook handler.yaml

PLAY [configure webserver with nginx]


************************************************

TASK [Gathering Facts]


***************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install    nginx]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [copy index.html]


***************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
***************************************************************************
141.95.160.133                          : ok=3        changed=0        unreachable=0 
failed=0        skipped                                                             
=0        rescued=0        ignored=0
146.59.158.16                            : ok=3        changed=0        unreachable=0
failed=0        skipped                                                             
=0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim handler.yaml


ansadmin@svl200:~$ sudo vim index.html
ansadmin@svl200:~$ ansible-playbook handler.yaml

PLAY [configure webserver with nginx]


************************************************

TASK [Gathering Facts]


***************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install    nginx]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [copy index.html]


***************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]
RUNNING HANDLER [restart_nginx]
******************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
***************************************************************************
141.95.160.133                          : ok=4        changed=2        unreachable=0 
failed=0        skipped                                                             
=0        rescued=0        ignored=0
146.59.158.16                            : ok=4        changed=2        unreachable=0
failed=0        skipped                                                             
=0        rescued=0        ignored=0

ansadmin@svl200:~$ vim /etc/ansible/hosts


ansadmin@svl200:~$ vim /etc/ssh/sshd_config
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible cible1 -m setup
146.59.158.16 | SUCCESS => {
        "ansible_facts": {
                "ansible_all_ipv4_addresses": [
                        "146.59.158.16"
                ],
                "ansible_all_ipv6_addresses": [
                        "2001:41d0:304:200::951d",
                        "fe80::f816:3eff:fee6:102e"
                ],
                "ansible_apparmor": {
                        "status": "enabled"
                },
                "ansible_architecture": "x86_64",
                "ansible_bios_date": "04/01/2014",
                "ansible_bios_version": "2:1.10.2-58953eb7",
                "ansible_cmdline": {
                        "BOOT_IMAGE": "/boot/vmlinuz-5.4.0-122-generic",
                        "console": "ttyS0",
                        "ro": true,
                        "root": "LABEL=cloudimg-rootfs"
                },
                "ansible_date_time": {
                        "date": "2022-10-03",
                        "day": "03",
                        "epoch": "1664805080",
                        "hour": "13",
                        "iso8601": "2022-10-03T13:51:20Z",
                        "iso8601_basic": "20221003T135120753276",
                        "iso8601_basic_short": "20221003T135120",
                        "iso8601_micro": "2022-10-03T13:51:20.753373Z",
                        "minute": "51",
                        "month": "10",
                        "second": "20",
                        "time": "13:51:20",
                        "tz": "UTC",
                        "tz_offset": "+0000",
                        "weekday": "Monday",
                        "weekday_number": "1",
                        "weeknumber": "40",
                        "year": "2022"
                },
                "ansible_default_ipv4": {
                        "address": "146.59.158.16",
                        "alias": "ens3",
                        "broadcast": "global",
                        "gateway": "146.59.156.1",
                        "interface": "ens3",
                        "macaddress": "fa:16:3e:e6:10:2e",
                        "mtu": 1500,
                        "netmask": "255.255.255.255",
                        "network": "146.59.158.16",
                        "type": "ether"
                },
                "ansible_default_ipv6": {
                        "address": "2001:41d0:304:200::951d",
                        "gateway": "2001:41d0:304:200::1",
                        "interface": "ens3",
                        "macaddress": "fa:16:3e:e6:10:2e",
                        "mtu": 1500,
                        "prefix": "56",
                        "scope": "global",
                        "type": "ether"
                },
                "ansible_device_links": {
                        "ids": {
                                "sda": [
                                        "scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0"
                                ],
                                "sda1": [
                                        "scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-
part1"
                                ],
                                "sda14": [
                                        "scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-
part14"
                                ],
                                "sda15": [
                                        "scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-
part15"
                                ]
                        },
                        "labels": {
                                "sda1": [
                                        "cloudimg-rootfs"
                                ],
                                "sda15": [
                                        "UEFI"
                                ]
                        },
                        "masters": {},
                        "uuids": {
                                "sda1": [
                                        "f209b90d-e073-4df4-950a-9c8620c2292b"
                                ],
                                "sda15": [
                                        "C957-9CB6"
                                ]
                        }
                },
                "ansible_devices": {
                        "loop0": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "126888",
                                "sectorsize": "512",
                                "size": "61.96 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop1": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "96176",
                                "sectorsize": "512",
                                "size": "46.96 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop10": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "98272",
                                "sectorsize": "512",
                                "size": "47.98 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop11": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "0",
                                "sectorsize": "512",
                                "size": "0.00 Bytes",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop2": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "138880",
                                "sectorsize": "512",
                                "size": "67.81 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop3": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "126888",
                                "sectorsize": "512",
                                "size": "61.96 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop4": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "233448",
                                "sectorsize": "512",
                                "size": "113.99 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop5": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "8688",
                                "sectorsize": "512",
                                "size": "4.24 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop6": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "129480",
                                "sectorsize": "512",
                                "size": "63.22 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop7": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "98288",
                                "sectorsize": "512",
                                "size": "47.99 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop8": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "235368",
                                "sectorsize": "512",
                                "size": "114.93 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "loop9": {
                                "holders": [],
                                "host": "",
                                "links": {
                                        "ids": [],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": null,
                                "partitions": {},
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "235496",
                                "sectorsize": "512",
                                "size": "114.99 MB",
                                "support_discard": "4096",
                                "vendor": null,
                                "virtual": 1
                        },
                        "sda": {
                                "holders": [],
                                "host": "SCSI storage controller: Red Hat, Inc.
Virtio SCSI",
                                "links": {
                                        "ids": [
                                                "scsi-0QEMU_QEMU_HARDDISK_drive-
scsi0-0-0-0"
                                        ],
                                        "labels": [],
                                        "masters": [],
                                        "uuids": []
                                },
                                "model": "QEMU HARDDISK",
                                "partitions": {
                                        "sda1": {
                                                "holders": [],
                                                "links": {
                                                        "ids": [
                                                                "scsi-
0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-part1"
                                                        ],
                                                        "labels": [
                                                                "cloudimg-rootfs"
                                                        ],
                                                        "masters": [],
                                                        "uuids": [
                                                                "f209b90d-e073-4df4-
950a-9c8620c2292b"
                                                        ]
                                                },
                                                "sectors": "83658719",
                                                "sectorsize": 512,
                                                "size": "39.89 GB",
                                                "start": "227328",
                                                "uuid": "f209b90d-e073-4df4-950a-
9c8620c2292b"
                                        },
                                        "sda14": {
                                                "holders": [],
                                                "links": {
                                                        "ids": [
                                                                "scsi-
0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-part14"
                                                        ],
                                                        "labels": [],
                                                        "masters": [],
                                                        "uuids": []
                                                },
                                                "sectors": "8192",
                                                "sectorsize": 512,
                                                "size": "4.00 MB",
                                                "start": "2048",
                                                "uuid": null
                                        },
                                        "sda15": {
                                                "holders": [],
                                                "links": {
                                                        "ids": [
                                                                "scsi-
0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0-part15"
                                                        ],
                                                        "labels": [
                                                                "UEFI"
                                                        ],
                                                        "masters": [],
                                                        "uuids": [
                                                                "C957-9CB6"
                                                        ]
                                                },
                                                "sectors": "217088",
                                                "sectorsize": 512,
                                                "size": "106.00 MB",
                                                "start": "10240",
                                                "uuid": "C957-9CB6"
                                        }
                                },
                                "removable": "0",
                                "rotational": "1",
                                "sas_address": null,
                                "sas_device_handle": null,
                                "scheduler_mode": "mq-deadline",
                                "sectors": "83886080",
                                "sectorsize": "512",
                                "size": "40.00 GB",
                                "support_discard": "4096",
                                "vendor": "QEMU",
                                "virtual": 1
                        }
                },
                "ansible_distribution": "Ubuntu",
                "ansible_distribution_file_parsed": true,
                "ansible_distribution_file_path": "/etc/os-release",
                "ansible_distribution_file_variety": "Debian",
                "ansible_distribution_major_version": "20",
                "ansible_distribution_release": "focal",
                "ansible_distribution_version": "20.04",
                "ansible_dns": {
                        "nameservers": [
                                "127.0.0.53"
                        ],
                        "options": {
                                "edns0": true,
                                "trust-ad": true
                        },
                        "search": [
                                "openstacklocal"
                        ]
                },
                "ansible_domain": "vps.ovh.net",
                "ansible_effective_group_id": 1006,
                "ansible_effective_user_id": 1006,
                "ansible_ens3": {
                        "active": true,
                        "device": "ens3",
                        "features": {
                                "esp_hw_offload": "off [fixed]",
                                "esp_tx_csum_hw_offload": "off [fixed]",
                                "fcoe_mtu": "off [fixed]",
                                "generic_receive_offload": "on",
                                "generic_segmentation_offload": "on",
                                "highdma": "on [fixed]",
                                "hw_tc_offload": "off [fixed]",
                                "l2_fwd_offload": "off [fixed]",
                                "large_receive_offload": "off [fixed]",
                                "loopback": "off [fixed]",
                                "netns_local": "off [fixed]",
                                "ntuple_filters": "off [fixed]",
                                "receive_hashing": "off [fixed]",
                                "rx_all": "off [fixed]",
                                "rx_checksumming": "on [fixed]",
                                "rx_fcs": "off [fixed]",
                                "rx_gro_hw": "on",
                                "rx_udp_tunnel_port_offload": "off [fixed]",
                                "rx_vlan_filter": "on [fixed]",
                                "rx_vlan_offload": "off [fixed]",
                                "rx_vlan_stag_filter": "off [fixed]",
                                "rx_vlan_stag_hw_parse": "off [fixed]",
                                "scatter_gather": "on",
                                "tcp_segmentation_offload": "on",
                                "tls_hw_record": "off [fixed]",
                                "tls_hw_rx_offload": "off [fixed]",
                                "tls_hw_tx_offload": "off [fixed]",
                                "tx_checksum_fcoe_crc": "off [fixed]",
                                "tx_checksum_ip_generic": "on",
                                "tx_checksum_ipv4": "off [fixed]",
                                "tx_checksum_ipv6": "off [fixed]",
                                "tx_checksum_sctp": "off [fixed]",
                                "tx_checksumming": "on",
                                "tx_esp_segmentation": "off [fixed]",
                                "tx_fcoe_segmentation": "off [fixed]",
                                "tx_gre_csum_segmentation": "off [fixed]",
                                "tx_gre_segmentation": "off [fixed]",
                                "tx_gso_partial": "off [fixed]",
                                "tx_gso_robust": "on [fixed]",
                                "tx_ipxip4_segmentation": "off [fixed]",
                                "tx_ipxip6_segmentation": "off [fixed]",
                                "tx_lockless": "off [fixed]",
                                "tx_nocache_copy": "off",
                                "tx_scatter_gather": "on",
                                "tx_scatter_gather_fraglist": "off [fixed]",
                                "tx_sctp_segmentation": "off [fixed]",
                                "tx_tcp6_segmentation": "on",
                                "tx_tcp_ecn_segmentation": "on",
                                "tx_tcp_mangleid_segmentation": "off",
                                "tx_tcp_segmentation": "on",
                                "tx_udp_segmentation": "off [fixed]",
                                "tx_udp_tnl_csum_segmentation": "off [fixed]",
                                "tx_udp_tnl_segmentation": "off [fixed]",
                                "tx_vlan_offload": "off [fixed]",
                                "tx_vlan_stag_hw_insert": "off [fixed]",
                                "vlan_challenged": "off [fixed]"
                        },
                        "hw_timestamp_filters": [],
                        "ipv4": {
                                "address": "146.59.158.16",
                                "broadcast": "global",
                                "netmask": "255.255.255.255",
                                "network": "146.59.158.16"
                        },
                        "ipv6": [
                                {
                                        "address": "2001:41d0:304:200::951d",
                                        "prefix": "56",
                                        "scope": "global"
                                },
                                {
                                        "address": "fe80::f816:3eff:fee6:102e",
                                        "prefix": "64",
                                        "scope": "link"
                                }
                        ],
                        "macaddress": "fa:16:3e:e6:10:2e",
                        "module": "virtio_net",
                        "mtu": 1500,
                        "pciid": "virtio0",
                        "promisc": false,
                        "speed": -1,
                        "timestamping": [
                                "tx_software",
                                "rx_software",
                                "software"
                        ],
                        "type": "ether"
                },
                "ansible_env": {
                        "DBUS_SESSION_BUS_ADDRESS": "unix:path=/run/user/1006/bus",
                        "HOME": "/home/ansadmin",
                        "LANG": "C.UTF-8",
                        "LOGNAME": "ansadmin",
                        "MOTD_SHOWN": "pam",
                        "PATH":
"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games             
/usr/local/games:/snap/bin",
                        "PWD": "/home/ansadmin",
                        "SHELL": "/bin/bash",
                        "SHLVL": "0",
                        "SSH_CLIENT": "146.59.156.114 35036 55600",
                        "SSH_CONNECTION": "146.59.156.114 35036 146.59.158.16 55600",
                        "SSH_TTY": "/dev/pts/2",
                        "TERM": "xterm",
                        "USER": "ansadmin",
                        "XDG_RUNTIME_DIR": "/run/user/1006",
                        "XDG_SESSION_CLASS": "user",
                        "XDG_SESSION_ID": "468",
                        "XDG_SESSION_TYPE": "tty",
                        "_": "/bin/sh"
                },
                "ansible_fibre_channel_wwn": [],
                "ansible_fips": false,
                "ansible_form_factor": "Other",
                "ansible_fqdn": "vps-698c29b2.vps.ovh.net",
                "ansible_hostname": "master-wildfly",
                "ansible_hostnqn": "",
                "ansible_interfaces": [
                        "lo",
                        "ens3"
                ],
                "ansible_is_chroot": false,
                "ansible_iscsi_iqn": "",
                "ansible_kernel": "5.4.0-122-generic",
                "ansible_kernel_version": "#138-Ubuntu SMP Wed Jun 22 15:00:31 UTC
2022",
                "ansible_lo": {
                        "active": true,
                        "device": "lo",
                        "features": {
                                "esp_hw_offload": "off [fixed]",
                                "esp_tx_csum_hw_offload": "off [fixed]",
                                "fcoe_mtu": "off [fixed]",
                                "generic_receive_offload": "on",
                                "generic_segmentation_offload": "on",
                                "highdma": "on [fixed]",
                                "hw_tc_offload": "off [fixed]",
                                "l2_fwd_offload": "off [fixed]",
                                "large_receive_offload": "off [fixed]",
                                "loopback": "on [fixed]",
                                "netns_local": "on [fixed]",
                                "ntuple_filters": "off [fixed]",
                                "receive_hashing": "off [fixed]",
                                "rx_all": "off [fixed]",
                                "rx_checksumming": "on [fixed]",
                                "rx_fcs": "off [fixed]",
                                "rx_gro_hw": "off [fixed]",
                                "rx_udp_tunnel_port_offload": "off [fixed]",
                                "rx_vlan_filter": "off [fixed]",
                                "rx_vlan_offload": "off [fixed]",
                                "rx_vlan_stag_filter": "off [fixed]",
                                "rx_vlan_stag_hw_parse": "off [fixed]",
                                "scatter_gather": "on",
                                "tcp_segmentation_offload": "on",
                                "tls_hw_record": "off [fixed]",
                                "tls_hw_rx_offload": "off [fixed]",
                                "tls_hw_tx_offload": "off [fixed]",
                                "tx_checksum_fcoe_crc": "off [fixed]",
                                "tx_checksum_ip_generic": "on [fixed]",
                                "tx_checksum_ipv4": "off [fixed]",
                                "tx_checksum_ipv6": "off [fixed]",
                                "tx_checksum_sctp": "on [fixed]",
                                "tx_checksumming": "on",
                                "tx_esp_segmentation": "off [fixed]",
                                "tx_fcoe_segmentation": "off [fixed]",
                                "tx_gre_csum_segmentation": "off [fixed]",
                                "tx_gre_segmentation": "off [fixed]",
                                "tx_gso_partial": "off [fixed]",
                                "tx_gso_robust": "off [fixed]",
                                "tx_ipxip4_segmentation": "off [fixed]",
                                "tx_ipxip6_segmentation": "off [fixed]",
                                "tx_lockless": "on [fixed]",
                                "tx_nocache_copy": "off [fixed]",
                                "tx_scatter_gather": "on [fixed]",
                                "tx_scatter_gather_fraglist": "on [fixed]",
                                "tx_sctp_segmentation": "on",
                                "tx_tcp6_segmentation": "on",
                                "tx_tcp_ecn_segmentation": "on",
                                "tx_tcp_mangleid_segmentation": "on",
                                "tx_tcp_segmentation": "on",
                                "tx_udp_segmentation": "off [fixed]",
                                "tx_udp_tnl_csum_segmentation": "off [fixed]",
                                "tx_udp_tnl_segmentation": "off [fixed]",
                                "tx_vlan_offload": "off [fixed]",
                                "tx_vlan_stag_hw_insert": "off [fixed]",
                                "vlan_challenged": "on [fixed]"
                        },
                        "hw_timestamp_filters": [],
                        "ipv4": {
                                "address": "127.0.0.1",
                                "broadcast": "host",
                                "netmask": "255.0.0.0",
                                "network": "127.0.0.0"
                        },
                        "ipv6": [
                                {
                                        "address": "::1",
                                        "prefix": "128",
                                        "scope": "host"
                                }
                        ],
                        "mtu": 65536,
                        "promisc": false,
                        "timestamping": [
                                "tx_software",
                                "rx_software",
                                "software"
                        ],
                        "type": "loopback"
                },
                "ansible_local": {},
                "ansible_lsb": {
                        "codename": "focal",
                        "description": "Ubuntu 20.04.5 LTS",
                        "id": "Ubuntu",
                        "major_release": "20",
                        "release": "20.04"
                },
                "ansible_machine": "x86_64",
                "ansible_machine_id": "adc4dbb14d4447ada17154213d422c09",
                "ansible_memfree_mb": 222,
                "ansible_memory_mb": {
                        "nocache": {
                                "free": 1278,
                                "used": 657
                        },
                        "real": {
                                "free": 222,
                                "total": 1935,
                                "used": 1713
                        },
                        "swap": {
                                "cached": 0,
                                "free": 0,
                                "total": 0,
                                "used": 0
                        }
                },
                "ansible_memtotal_mb": 1935,
                "ansible_mounts": [
                        {
                                "block_available": 8921537,
                                "block_size": 4096,
                                "block_total": 10114671,
                                "block_used": 1193134,
                                "device": "/dev/sda1",
                                "fstype": "ext4",
                                "inode_available": 5046647,
                                "inode_total": 5160960,
                                "inode_used": 114313,
                                "mount": "/",
                                "options": "rw,relatime",
                                "size_available": 36542615552,
                                "size_total": 41429692416,
                                "uuid": "f209b90d-e073-4df4-950a-9c8620c2292b"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 543,
                                "block_used": 543,
                                "device": "/dev/loop2",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 802,
                                "inode_used": 802,
                                "mount": "/snap/lxd/22753",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 71172096,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 203074,
                                "block_size": 512,
                                "block_total": 213716,
                                "block_used": 10642,
                                "device": "/dev/sda15",
                                "fstype": "vfat",
                                "inode_available": 0,
                                "inode_total": 0,
                                "inode_used": 0,
                                "mount": "/boot/efi",
                                "options":
"rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=iso8859                   
1,shortname=mixed,errors=remount-ro",
                                "size_available": 103973888,
                                "size_total": 109422592,
                                "uuid": "C957-9CB6"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 496,
                                "block_used": 496,
                                "device": "/dev/loop3",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 11796,
                                "inode_used": 11796,
                                "mount": "/snap/core20/1611",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 65011712,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 34,
                                "block_used": 34,
                                "device": "/dev/loop5",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 690,
                                "inode_used": 690,
                                "mount": "/snap/tree/18",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 4456448,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 506,
                                "block_used": 506,
                                "device": "/dev/loop6",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 11882,
                                "inode_used": 11882,
                                "mount": "/snap/core20/1623",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 66322432,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 384,
                                "block_used": 384,
                                "device": "/dev/loop7",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 486,
                                "inode_used": 486,
                                "mount": "/snap/snapd/16778",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 50331648,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 920,
                                "block_used": 920,
                                "device": "/dev/loop8",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 12845,
                                "inode_used": 12845,
                                "mount": "/snap/core/13741",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 120586240,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 920,
                                "block_used": 920,
                                "device": "/dev/loop9",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 12845,
                                "inode_used": 12845,
                                "mount": "/snap/core/13886",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 120586240,
                                "uuid": "N/A"
                        },
                        {
                                "block_available": 0,
                                "block_size": 131072,
                                "block_total": 384,
                                "block_used": 384,
                                "device": "/dev/loop10",
                                "fstype": "squashfs",
                                "inode_available": 0,
                                "inode_total": 486,
                                "inode_used": 486,
                                "mount": "/snap/snapd/17029",
                                "options": "ro,nodev,relatime",
                                "size_available": 0,
                                "size_total": 50331648,
                                "uuid": "N/A"
                        }
                ],
                "ansible_nodename": "master-wildfly",
                "ansible_os_family": "Debian",
                "ansible_pkg_mgr": "apt",
                "ansible_proc_cmdline": {
                        "BOOT_IMAGE": "/boot/vmlinuz-5.4.0-122-generic",
                        "console": [
                                "tty1",
                                "ttyS0"
                        ],
                        "ro": true,
                        "root": "LABEL=cloudimg-rootfs"
                },
                "ansible_processor": [
                        "0",
                        "GenuineIntel",
                        "Intel Core Processor (Haswell, no TSX)"
                ],
                "ansible_processor_cores": 1,
                "ansible_processor_count": 1,
                "ansible_processor_threads_per_core": 1,
                "ansible_processor_vcpus": 1,
                "ansible_product_name": "OpenStack Nova",
                "ansible_product_serial": "NA",
                "ansible_product_uuid": "NA",
                "ansible_product_version": "19.0.4",
                "ansible_python": {
                        "executable": "/usr/bin/python3",
                        "has_sslcontext": true,
                        "type": "cpython",
                        "version": {
                                "major": 3,
                                "micro": 10,
                                "minor": 8,
                                "releaselevel": "final",
                                "serial": 0
                        },
                        "version_info": [
                                3,
                                8,
                                10,
                                "final",
                                0
                        ]
                },
                "ansible_python_version": "3.8.10",
                "ansible_real_group_id": 1006,
                "ansible_real_user_id": 1006,
                "ansible_selinux": {
                        "status": "Missing selinux Python library"
                },
                "ansible_selinux_python_present": false,
                "ansible_service_mgr": "systemd",
                "ansible_ssh_host_key_dsa_public":
"AAAAB3NzaC1kc3MAAACBAP6HcF8z3pABr7Ha4Z/hiKaYFifK                                   
BMqCxMrB4joQeAx3e/OA93XudbdbwRmW2GtjdJf9mvVOjbvHZr44KAITI65I+MzAWn/
Bhx0cMyljGJJDyXFSQqzuwmzL                                                           
XHbHnPAhw93kp1Ct1NOgEBTnwbhVzaQhEDQ6pmHCj/NIRyCFwLAAAAFQCPsGFnGGnYxsX59fhj2Aymc7tsfwA
AAIB7qf                                                                             
O5uJoTj2nu3mbAVI8BuVRpGS4hBUctkR1pmvTkNbKJzAxrFDynG9fMx2LKsgIqjCgNFk0YahxigpGRJuLOe3L
6b0ymXG                                                                             
QzJ2dvyB7ghpTLbRxgJa+MiZJuJlrztCrtrIjvxF1H9y2J7dLlwF9F6GsZAFCpm7uQKcLOpgDgAAAIEAoD+6L
4p4aFw7                                                                             
ev0y+ehe3JCxLLC5NvblMLDGvqkA098r1EUCWSowH24IeFRHJ+cdWtcArJNclJDaNA8oePwjuQKtubQyr4W8O
1VYTYw3                                                                             
P3W6qFDeFl5yLKA9EHUmxWc8ymXDGBcmwuVH2W1ZbteSSpKS1Ycp8OxzXqEalRrYc=",
                "ansible_ssh_host_key_ecdsa_public":
"AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNT                                     
AAABBBOn8ceAE4EDAWwmXkogeKexuv0b82zK+3VenUUR8P2cicoaQSsQ83fldYHzqhVSP5x98ZhqkHaHMgBkS
MZY8rBQ                                                                             
",
                "ansible_ssh_host_key_ed25519_public":
"AAAAC3NzaC1lZDI1NTE5AAAAIM0bpK+LEEg6bH+uMeDK                                       
HlvcQHBfj37qCeWUF+pS2uQ",
                "ansible_ssh_host_key_rsa_public":
"AAAAB3NzaC1yc2EAAAADAQABAAABgQDByfqYTpZnEJQpKILW                                   
ELvPYKwSedP1hbHtGGEEymgw0dWhkKahKqNITSTPBF/0pALPm+3/IKONDAUr53cZQLngFrV+qu8rnKdaRo3OX
DZzJrWe                                                                             
ZVmlyQTmF+uA8L3e+IJitvPPm+7Aj7SrbwfBqCPLNdEfN1ausTQZK/hIPCgOfAV2Yswr93nqtOSiiybhZ6lQx
e2KsDbh                                                                             
XRjFUb4tgIUkt1Hbb3x22uqL4BAZ0htJ3EsDkwUv1VwTOc/CVs0IZryQZH1nEXJakk3z8Ibte2f75jIe1A1Vt
rYw6zQL                                                                             
8HxkGs9S4YWxQJpeJ6k9bYRJ+SF+UPS3gchon+A2rOuaOSYMUCh9RH2g8DoIDawP7BPX38HTsgu6RPciz5nb2
oDJ0iCW                                                                             
t8Zfj4rwGoigcYBWQ5NkBWHK1GpGs0wdt0VbiUlF2SzEDgJmESOn2bhyiXhoT/2OaX5lViPyjzr3NGVOO6z7V
j3HBEBq                                                                             
F4+y/c4b08NiiucMDDp3CjQ5JtClE=",
                "ansible_swapfree_mb": 0,
                "ansible_swaptotal_mb": 0,
                "ansible_system": "Linux",
                "ansible_system_capabilities": [
                        ""
                ],
                "ansible_system_capabilities_enforced": "True",
                "ansible_system_vendor": "OpenStack Foundation",
                "ansible_uptime_seconds": 3303036,
                "ansible_user_dir": "/home/ansadmin",
                "ansible_user_gecos": ",,,",
                "ansible_user_gid": 1006,
                "ansible_user_id": "ansadmin",
                "ansible_user_shell": "/bin/bash",
                "ansible_user_uid": 1006,
                "ansible_userspace_architecture": "x86_64",
                "ansible_userspace_bits": "64",
                "ansible_virtualization_role": "guest",
                "ansible_virtualization_type": "openstack",
                "discovered_interpreter_python": "/usr/bin/python3",
                "gather_subset": [
                        "all"
                ],
                "module_setup": true
        },
        "changed": false
}
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible cible1 -m setup -a "filter=*family*"
146.59.158.16 | SUCCESS => {
        "ansible_facts": {
                "ansible_os_family": "Debian",
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false
}
ansadmin@svl200:~$ ansible cible2 -m setup -a "filter=*family*"
141.95.160.133 | SUCCESS => {
        "ansible_facts": {
                "ansible_os_family": "Debian",
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible cible2 -m setup -a "filter=*ip*"
141.95.160.133 | SUCCESS => {
        "ansible_facts": {
                "ansible_all_ipv4_addresses": [
                        "141.95.160.133"
                ],
                "ansible_all_ipv6_addresses": [
                        "2001:41d0:304:200::82a1",
                        "fe80::f816:3eff:fef2:cdf9"
                ],
                "ansible_default_ipv4": {
                        "address": "141.95.160.133",
                        "alias": "ens3",
                        "broadcast": "global",
                        "gateway": "141.95.160.1",
                        "interface": "ens3",
                        "macaddress": "fa:16:3e:f2:cd:f9",
                        "mtu": 1500,
                        "netmask": "255.255.255.255",
                        "network": "141.95.160.133",
                        "type": "ether"
                },
                "ansible_default_ipv6": {
                        "address": "2001:41d0:304:200::82a1",
                        "gateway": "2001:41d0:304:200::1",
                        "interface": "ens3",
                        "macaddress": "fa:16:3e:f2:cd:f9",
                        "mtu": 1500,
                        "prefix": "56",
                        "scope": "global",
                        "type": "ether"
                },
                "ansible_fips": false,
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false
}
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim fact.yaml
ansadmin@svl200:~$ cat fact.yaml
---
- name: facts
    hosts: all
    become: true
    vars:
        - var1: Hello DevOps1
        - var2: Good Morning DevOps2

    tasks:
        - name: echo text
            shell: echo "{{var1}} is var1, but var2 is {{var2}} >
/home/ansadmin/{{ansible_os_fami
ansadmin@svl200:~$ sudo vim fact.yaml
ansadmin@svl200:~$ ansible-playbook fact.yaml

PLAY [facts]
*******************************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo text]


***************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=0                                                           
ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=0                                                           
ignored=0

ansadmin@svl200:~$ ansible all -a "ls -lrt"


146.59.158.16 | CHANGED | rc=0 >>
total 8
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
141.95.160.133 | CHANGED | rc=0 >>
total 8
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
ansadmin@svl200:~$ ansible all -a "cat Redhat.txt"
146.59.158.16 | FAILED | rc=1 >>
cat: Redhat.txt: No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=1 >>
cat: Redhat.txt: No such file or directorynon-zero return code
ansadmin@svl200:~$ ansible all -a "cat RedHat.txt"
146.59.158.16 | FAILED | rc=1 >>
cat: RedHat.txt: No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=1 >>
cat: RedHat.txt: No such file or directorynon-zero return code
ansadmin@svl200:~$ ansible all -a "cat Debian.txt"
146.59.158.16 | CHANGED | rc=0 >>
Hello DevOps1 is var1, but var2 is Good Morning DevOps2
141.95.160.133 | CHANGED | rc=0 >>
Hello DevOps1 is var1, but var2 is Good Morning DevOps2
ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$ cp fact.yaml fact1.yaml
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim fact.yaml
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim fact.yaml
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim ip.txt
ansadmin@svl200:~$ ansible-playbook fact1.yaml

PLAY [facts]
*******************************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo text]


***************************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined va                                                                         
e error was: 'ip' is undefined\n\nThe error appears to be in
'/home/ansadmin/fact1.yaml': li                                                     
mn 7, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe
offend                                                                               
ppears to be:\n\n    tasks:\n        - name: echo text\n            ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefined v                                                                         
he error was: 'ip' is undefined\n\nThe error appears to be in
'/home/ansadmin/fact1.yaml': l                                                       
umn 7, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\
nThe offen                                                                           
appears to be:\n\n    tasks:\n        - name: echo text\n            ^ here\n"}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
ignored=0

ansadmin@svl200:~$ sudo vim fact1.yaml


ansadmin@svl200:~$ ansible-playbook fact1.yaml

PLAY [facts]
*******************************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo text]


***************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]
PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=0                                                           
ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=0                                                           
ignored=0

ansadmin@svl200:~$ sudo vim fact1.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook fact1.yaml

PLAY [facts]
*******************************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo text]


***************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=0                                                           
ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=0                                                           
ignored=0

ansadmin@svl200:~$ sudo vim ip.txt


ansadmin@svl200:~$ cat ip.txt
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ ansible all -a "cat ip.txt"
146.59.158.16 | CHANGED | rc=0 >>
['146.59.158.16']
141.95.160.133 | CHANGED | rc=0 >>
['141.95.160.133']
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim fact1.yaml
ansadmin@svl200:~$ sudo vim debug.yaml
ansadmin@svl200:~$ cat debug.yaml
---
-name: debug
hosts: cible1
become: true
vars:
      - var1: Hello Devops
tasks:
      - name: echo test
          command: echo -e "{{var1}} is var1 it works"
          register: results

      - name: show results


          debug: msg={{results}}

ansadmin@svl200:~$ ansible-playbook debug.yaml


ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/debug.yaml': line 3, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

-name: debug
hosts: cible1
            ^ here
ansadmin@svl200:~$ sudo vim debug.yaml
ansadmin@svl200:~$ ansible-playbook debug.yaml

PLAY [debug]
*******************************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]

TASK [echo test]


***************************************************************************
changed: [146.59.158.16]

TASK [show results]


************************************************************************
ok: [146.59.158.16] => {
        "msg": {
                "changed": true,
                "cmd": [
                        "echo",
                        "-e",
                        "Hello Devops is var1 it works"
                ],
                "delta": "0:00:00.003328",
                "end": "2022-10-03 15:01:22.526831",
                "failed": false,
                "rc": 0,
                "start": "2022-10-03 15:01:22.523503",
                "stderr": "",
                "stderr_lines": [],
                "stdout": "Hello Devops is var1 it works",
                "stdout_lines": [
                        "Hello Devops is var1 it works"
                ]
        }
}

PLAY RECAP
*********************************************************************************
146.59.158.16                            : ok=3        changed=1        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim debug.yaml


ansadmin@svl200:~$ ansible-playbook debug.yaml

PLAY [debug]
*******************************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]

TASK [echo test]


***************************************************************************
changed: [146.59.158.16]

TASK [show results]


************************************************************************
ok: [146.59.158.16] => {
        "msg": [
                "Hello Devops is var1 it works"
        ]
}

PLAY RECAP
*********************************************************************************
146.59.158.16                            : ok=3        changed=1        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ cp debug.yaml debug1.yaml
ansadmin@svl200:~$ sudo vim debug1.yaml
ansadmin@svl200:~$ ansible-playbook debug1.yaml

PLAY [debug]
*******************************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]

TASK [show results]


************************************************************************
ok: [146.59.158.16] => {
        "msg": "Le serveur Apache utilise par defaut le port 80 sur ma machine
Debian"
}

PLAY RECAP
*********************************************************************************
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


*********************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


*************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time"                                                                 
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg:                                                                           
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' faile                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd                                                                               
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation ca                                                                     
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state info                                                                           
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.                                                                         
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webf                                                               
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-h                                                                 
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...                                                                             
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-                                                                               
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3",                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubu                                                                         
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenser                                                                     
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time                                                                   
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg                                                                               
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' fail                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'http                                                                               
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation c                                                                       
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inf                                                                           
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20                                                                         
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    web                                                               
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-                                                                   
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree..                                                                               
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx                                                                               
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3"                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ub                                                                           
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigense                                                                       
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when.yaml
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


*********************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


*************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time"                                                                 
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg:                                                                           
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' faile                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd                                                                               
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation ca                                                                     
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state info                                                                           
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.                                                                         
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webf                                                               
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-h                                                                 
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...                                                                             
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-                                                                               
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3",                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubu                                                                         
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenser                                                                     
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time                                                                   
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg                                                                               
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' fail                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'http                                                                               
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation c                                                                       
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inf                                                                           
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20                                                                         
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    web                                                               
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-                                                                   
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree..                                                                               
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx                                                                               
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3"                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ub                                                                           
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigense                                                                       
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


*********************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [apt get install httpd on centos]


*****************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time"                                                                 
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg:                                                                           
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' faile                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd                                                                               
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation ca                                                                     
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state info                                                                           
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.                                                                         
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webf                                                               
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-h                                                                 
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...                                                                             
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-                                                                               
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3",                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubu                                                                         
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenser                                                                     
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time                                                                   
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg                                                                               
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' fail                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'http                                                                               
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation c                                                                       
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inf                                                                           
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20                                                                         
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    web                                                               
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-                                                                   
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree..                                                                               
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx                                                                               
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3"                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ub                                                                           
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigense                                                                       
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when.yaml
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


*********************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [apt-get install httpd on centos]


*****************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time"                                                                 
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg:                                                                           
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' faile                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd                                                                               
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation ca                                                                     
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state info                                                                           
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.                                                                         
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webf                                                               
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-h                                                                 
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...                                                                             
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-                                                                               
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3",                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubu                                                                         
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenser                                                                     
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time                                                                   
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg                                                                               
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' fail                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'http                                                                               
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation c                                                                       
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inf                                                                           
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20                                                                         
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    web                                                               
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-                                                                   
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree..                                                                               
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx                                                                               
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3"                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ub                                                                           
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigense                                                                       
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when.yaml
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


*********************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


*************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time"                                                                 
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg:                                                                           
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' faile                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd                                                                               
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation ca                                                                     
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state info                                                                           
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.                                                                         
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webf                                                               
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-h                                                                 
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...                                                                             
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-                                                                               
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3",                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubu                                                                         
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenser                                                                     
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time                                                                   
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg                                                                               
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' fail                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'http                                                                               
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation c                                                                       
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inf                                                                           
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20                                                                         
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    web                                                               
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-                                                                   
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree..                                                                               
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx                                                                               
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3"                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ub                                                                           
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigense                                                                       
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


*********************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


*************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time"                                                                 
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg:                                                                           
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' faile                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd                                                                               
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation ca                                                                     
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state info                                                                           
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.                                                                         
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webf                                                               
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-h                                                                 
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...                                                                             
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-                                                                               
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3",                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubu                                                                         
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenser                                                                     
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
...ignoring
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time                                                                   
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg                                                                               
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' fail                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'http                                                                               
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation c                                                                       
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inf                                                                           
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20                                                                         
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    web                                                               
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-                                                                   
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree..                                                                               
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx                                                                               
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3"                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ub                                                                           
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigense                                                                       
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
...ignoring

TASK [install apache2 on ubuntu]


***********************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=3        changed=1        unreachable=0 
failed=0        skipped=0                                                           
cued=0        ignored=1
146.59.158.16                            : ok=3        changed=0        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=1

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$ -
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
───────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Mon Oct    3 13:16:15 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$ sudo vim when.yml
ansadmin@svl200:~$ history
        1    ssh-keygen -t rsa
        2    ssh
        3    ssh-copy-id [email protected] [email protected]
        4    sudo vim /etc/ssh/sshd_config
        5    ls -l .ssh/
        6    ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub [email protected] -p
55600
        7    ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub [email protected] -p
55600
        8    sudo vim /etc/ansible/hosts
        9    ansible all -m ping
      10    sudo vim /etc/ansible/hosts
      11    ansible all -m ping
      12    ansible cible1 -m ping
      13    ansible cible2 -m ping
      14    ansible 146.59.158.16 -m ping
      15    ansible 141.95.160.133 -m ping
      16    sudo touch cible1.txt
      17    ansible cible1 -m copy -a "src=cible1.txt dest=/tmp"
      18    ansible cible1 -m ls -a "dest=/tmp"
      19    ansible cible1 -m shell -a "ls -lrt /tmp"
      20    ansible cible1 -m file -a "dest=/tmp/cible1.txt mode=777"
      21    ansible cible1 -m user -a "name=cible1 state=present"
      22    ansible cible1 -b -m user -a "name=cible1 state=present"
      23    ansible cible1 -m shell -a "cat /etc/passwd | grep cible1"
      24    ansible all -b -m apt -a "name=curl state=latest"
      25    ansible cible1 -m service -a "name=cron state=started"
      26    ansible cible1 -b -m service -a "name=cron state=started"
      27    ansible cible1 -b -m service -a "name=cron state=stopped"
      28    ansible cible1 -b -m systemd -a "name=cron state=started"
      29    ansible cible1 -b -m systemd -a "name=cron state=stopped"
      30    ansible cible1 -b -m systemd -a "name=cron state=restarted"
      31    ansible all -a 'whoami'
      32    ansible cible1 -a 'whoami'
      33    ansible cible2 -a 'whoami'
      34    ansible all -ab 'whoami'
      35    ansible all -b -a 'whoami'
      36    ansible all -ba 'whoami'
      37    sudo vim nginx.yaml
      38    ansible-playbook nginx.yml
      39    ansible-playbook nginx.yaml
      40    sudo vim nginx.yaml
      41    ansible all -m service -a "name=apache2 state=status"
      42    ansible cible1 -bm shell -a "systemctl status cron"
      43    uname -a
      44    uname -r
      45    cat /etc/os-release
      46    lsb_release
      47    ansible all -a "cat /ho
      48    sudo vim shell.yml
      49    ansible all -a "cat /home/ansadmin/resultat.txt"
      50    ansible-playbook resultat.txt
      51    sudo vim shell.yml
      52    ansible-playbook /home/ansadmin/resultat.txt
      53    sudo vim shell.yml
      54    ansible-playbook shell.yml
      55    ansible all -a "cat /home/ansadmin/resultat.txt"
      56    sudo vim shell.yml
      57    ansible-playbook shell.yml
      58    sudo vim shell.yml
      59    ansible-playbook shell.yml
      60    sudo vim shell.yml
      61    ansible-playbook shell.yml
      62    ansible-playbook -b shell.yml
      63    ansible all -a "cat /home/ansadmin/resultat.txt"
      64    sudo vim handler.yaml
      65    sudo vim handler.yaml
      66    vim handler.yaml
      67    sudo vim when.yml
      68    history
ansadmin@svl200:~$ ls
cible1.txt    debug1.yaml    fact1.yaml        index.html    nginx.yaml    when.yaml
debug.yaml    fact.yaml        handler.yaml    ip.txt            shell.yml
ansadmin@svl200:~$ sudo vim debug1.yaml
ansadmin@svl200:~$ ansible-playbook -b debug1.yaml

PLAY [debug]
*******************************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]

TASK [show results]


************************************************************************
ok: [146.59.158.16] => {
        "msg": "Le serveur Apache utilise par defaut le port 80 sur ma machine
Debian"
}

PLAY RECAP
*********************************************************************************
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim when.yaml


ansadmin@svl200:~$ ansible-playbook when.yaml

PLAY [exemple avec condition when]


*********************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


*************************************************************
fatal: [146.59.158.16]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time"                                                                 
664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -
o \"Dpkg:                                                                           
tions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' faile                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'httpd                                                                               
as no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation ca                                                                     
date"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state info                                                                           
tion...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
inx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20.                                                                         
1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    webf                                                               
.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-h                                                                 
d 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree...                                                                             
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx-                                                                               
ht 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3",                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ubu                                                                         
3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigenser                                                                     
2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
...ignoring
fatal: [141.95.160.133]: FAILED! => {"ansible_facts": {"pkg_mgr": "apt"},
"cache_update_time                                                                   
1664804313, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o
\"Dpkg                                                                               
ptions::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\"            install
'httpd'' fail                                                                       
E: Package 'httpd' has no installation candidate\n", "rc": 100, "stderr": "E: Package
'http                                                                               
has no installation candidate\n", "stderr_lines": ["E: Package 'httpd' has no
installation c                                                                       
idate"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state inf                                                                           
ation...\nPackage httpd is a virtual package provided by:\n    nginx-light 1.18.0-
0ubuntu1.3\n                                                                         
ginx-full 1.18.0-0ubuntu1.3\n    nginx-extras 1.18.0-0ubuntu1.3\n    lighttpd 1.4.55-
1ubuntu1.20                                                                         
.1\n    nginx-core 1.18.0-0ubuntu1.3\n    apache2 2.4.41-4ubuntu3.12\n    yaws
2.0.7+dfsg-1\n    web                                                               
1.21+ds1-12\n    tntnet 2.2.1-4build1\n    ocsigenserver 2.16.0-2\n    mini-httpd
1.30-2\n    micro-                                                                   
pd 20140814-2\n\n", "stdout_lines": ["Reading package lists...", "Building dependency
tree..                                                                               
"Reading state information...", "Package httpd is a virtual package provided by:", " 
nginx                                                                               
ght 1.18.0-0ubuntu1.3", "    nginx-full 1.18.0-0ubuntu1.3", "    nginx-extras 1.18.0-
0ubuntu1.3"                                                                         
lighttpd 1.4.55-1ubuntu1.20.04.1", "    nginx-core 1.18.0-0ubuntu1.3", "    apache2
2.4.41-4ub                                                                           
u3.12", "    yaws 2.0.7+dfsg-1", "    webfs 1.21+ds1-12", "    tntnet 2.2.1-4build1",
"    ocsigense                                                                       
r 2.16.0-2", "    mini-httpd 1.30-2", "    micro-httpd 20140814-2", ""]}
...ignoring

TASK [install apache2 on ubuntu]


***********************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=3        changed=0        unreachable=0 
failed=0        skipped=0                                                           
cued=0        ignored=1
146.59.158.16                            : ok=3        changed=0        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=1

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when1.yaml
ansadmin@svl200:~$ sudo rm when1.yaml
rm: cannot remove 'when1.yaml': No such file or directory
ansadmin@svl200:~$ sudo rm -f when1.yaml
ansadmin@svl200:~$ ls
cible1.txt    debug1.yaml    fact1.yaml        index.html    nginx.yaml    when.yaml
debug.yaml    fact.yaml        handler.yaml    ip.txt            shell.yml
ansadmin@svl200:~$ sudo cp when.yaml when1.yaml
ansadmin@svl200:~$ sudo vim when1.yaml
ansadmin@svl200:~$ ansible-playbook when1.yaml

PLAY [exemple avec condition when]


*********************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


*************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [install apache2 on ubuntu]


***********************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=1                                                           
cued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=1                                                           
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim list.yaml


ansadmin@svl200:~$ ansible-playbook list.yaml

PLAY [exemple ansible list]


****************************************************************
TASK [Gathering Facts]
*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install package]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ ansible-playbook items.yaml

PLAY [exemple avec items]


******************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


******************************************************
changed: [146.59.158.16] => (item=init1.txt)
changed: [141.95.160.133] => (item=init1.txt)
changed: [146.59.158.16] => (item=init2.txt)
changed: [141.95.160.133] => (item=init2.txt)
changed: [146.59.158.16] => (item=init3.txt)
changed: [141.95.160.133] => (item=init3.txt)
changed: [146.59.158.16] => (item=init4.txt)
changed: [141.95.160.133] => (item=init4.txt)

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ ls
cible1.txt    debug1.yaml    fact1.yaml        index.html    items.yaml    nginx.yaml
when.yaml
debug.yaml    fact.yaml        handler.yaml    ip.txt            list.yaml     
shell.yml      when1.yaml
ansadmin@svl200:~$ ansible cible1 -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$ ansible cible1 -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$ ansible cible2 -bm shell -a "ls -lrt /home/ansadmin"
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$ ansible all -bma "ls -lrt /home/ansadmin"
usage: ansible [-h] [--version] [-v] [-b] [--become-method BECOME_METHOD]
                              [--become-user BECOME_USER] [-K] [-i INVENTORY] [--
list-hosts] [-l SUBSET]
                              [-P POLL_INTERVAL] [-B SECONDS] [-o] [-t TREE] [-k]
                              [--private-key PRIVATE_KEY_FILE] [-u REMOTE_USER] [-c
CONNECTION] [-T TIMEOUT
                              [--ssh-common-args SSH_COMMON_ARGS] [--sftp-extra-args
SFTP_EXTRA_ARGS]
                              [--scp-extra-args SCP_EXTRA_ARGS] [--ssh-extra-args
SSH_EXTRA_ARGS] [-C]
                              [--syntax-check] [-D] [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                              [--ask-vault-pass | --vault-password-file
VAULT_PASSWORD_FILES] [-f FORKS]
                              [-M MODULE_PATH] [--playbook-dir BASEDIR] [-a
MODULE_ARGS] [-m MODULE_NAME]
                              pattern
ansible: error: unrecognized arguments: ls -lrt /home/ansadmin
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$ cp items.yaml seq.yaml
ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$ ansible-playbook seq.yaml

PLAY [exemple avec items]


******************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [creation de liste des fichiers]
******************************************************
changed: [146.59.158.16] => (item=20)
changed: [141.95.160.133] => (item=20)
changed: [146.59.158.16] => (item=21)
changed: [141.95.160.133] => (item=21)
changed: [146.59.158.16] => (item=22)
changed: [141.95.160.133] => (item=22)
changed: [146.59.158.16] => (item=23)
changed: [141.95.160.133] => (item=23)
changed: [146.59.158.16] => (item=24)
changed: [141.95.160.133] => (item=24)
changed: [146.59.158.16] => (item=25)
changed: [141.95.160.133] => (item=25)
changed: [146.59.158.16] => (item=26)
changed: [141.95.160.133] => (item=26)
changed: [146.59.158.16] => (item=27)
changed: [141.95.160.133] => (item=27)

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin"


146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:14 init4.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | grep Dev"
146.59.158.16 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
141.95.160.133 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
ansadmin@svl200:~$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
───────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Mon Oct    3 17:50:31 2022 from 80.119.120.22
ofi03@svl200:~$
ofi03@svl200:~$ ansible all -bm group -a "name=rennes"
The authenticity of host '[146.59.158.16]:55600 ([146.59.158.16]:55600)' can't be
establishe
ECDSA key fingerprint is SHA256:aQH+1UeVJklKq8A45Soa63iOGGkNRC/op7o5MgPiJtc.
The authenticity of host '[141.95.160.133]:55600 ([141.95.160.133]:55600)' can't be
establis
ECDSA key fingerprint is SHA256:XtY+kTiWN4Ohe3xBY3YAQ9YLSSuP7bbmxZjN/R9SBcs.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
146.59.158.16 | UNREACHABLE! => {
        "changed": false,
        "msg": "Failed to connect to the host via ssh: Warning: Permanently added
'[146.59.158.1                                                                       
ickey,password).",
        "unreachable": true
}
^C [ERROR]: User interrupted execution
ofi03@svl200:~$
ofi03@svl200:~$ ansible all -bm group -a "name=rennes"
The authenticity of host '[141.95.160.133]:55600 ([141.95.160.133]:55600)' can't be
establis
ECDSA key fingerprint is SHA256:XtY+kTiWN4Ohe3xBY3YAQ9YLSSuP7bbmxZjN/R9SBcs.
Are you sure you want to continue connecting (yes/no/[fingerprint])? 146.59.158.16 |
UNREACH
        "changed": false,
        "msg": "Failed to connect to the host via ssh: [email protected]:
Permission denied (p
        "unreachable": true
}
yes
141.95.160.133 | UNREACHABLE! => {
        "changed": false,
        "msg": "Failed to connect to the host via ssh: Warning: Permanently added
'[141.95.160.1                                                                       
blickey,password).",
        "unreachable": true
}
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | grep Dev"
146.59.158.16 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
141.95.160.133 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm group -a "name=rennes"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1008,
        "name": "rennes",
        "state": "present",
        "system": false
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1004,
        "name": "rennes",
        "state": "present",
        "system": false
}
ansadmin@svl200:~$ ansible all -bm group -a "name=lille"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1009,
        "name": "lille",
        "state": "present",
        "system": false
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1005,
        "name": "lille",
        "state": "present",
        "system": false
}
ansadmin@svl200:~$ ansible all -bm group -a "name=paris"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1010,
        "name": "paris",
        "state": "present",
        "system": false
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1006,
        "name": "paris",
        "state": "present",
        "system": false
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm user -a "name=core"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "comment": "",
        "create_home": true,
        "group": 1011,
        "home": "/home/core",
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "system": false,
        "uid": 1008
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "comment": "",
        "create_home": true,
        "group": 1007,
        "home": "/home/core",
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "system": false,
        "uid": 1004
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm user -a "name=core uid=10000"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "append": false,
        "changed": true,
        "comment": "",
        "group": 1011,
        "home": "/home/core",
        "move_home": false,
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "uid": 10000
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "append": false,
        "changed": true,
        "comment": "",
        "group": 1007,
        "home": "/home/core",
        "move_home": false,
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "uid": 10000
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm user -a "name=core groups=rennes"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "append": false,
        "changed": true,
        "comment": "",
        "group": 1011,
        "groups": "rennes",
        "home": "/home/core",
        "move_home": false,
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "uid": 10000
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "append": false,
        "changed": true,
        "comment": "",
        "group": 1007,
        "groups": "rennes",
        "home": "/home/core",
        "move_home": false,
        "name": "core",
        "shell": "/bin/sh",
        "state": "present",
        "uid": 10000
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm apt -a "name=tree state=latest"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "cache_update_time": 1664843277,
        "cache_updated": false,
        "changed": true,
        "stderr": "",
        "stderr_lines": [],
        "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informat                                                                       
0 to remove and 0 not upgraded.\nNeed to get 43.0 kB of archives.\nAfter this
operation, 11                                                                       
tu focal/universe amd64 tree amd64 1.8.0-1 [43.0 kB]\nFetched 43.0 kB in 0s (133
kB/s)\nSele                                                                         
\r(Reading database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\
r(Reading                                                                           
40%\r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Read                                                                               
... 75%\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading database ...
90%\r(                                                                               
irectories currently installed.)\r\nPreparing to unpack .../tree_1.8.0-
1_amd64.deb ...\r\nUn                                                               
(2.9.1-1) ...\r\n",
        "stdout_lines": [
                "Reading package lists...",
                "Building dependency tree...",
                "Reading state information...",
                "The following NEW packages will be installed:",
                "    tree",
                "0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.",
                "Need to get 43.0 kB of archives.",
                "After this operation, 115 kB of additional disk space will be
used.",
                "Get:1 http://nova.clouds.archive.ubuntu.com/ubuntu focal/universe
amd64 tree amd64
                "Fetched 43.0 kB in 0s (133 kB/s)",
                "Selecting previously unselected package tree.",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97568 files and directories currently
installed.)",
                "Preparing to unpack .../tree_1.8.0-1_amd64.deb ...",
                "Unpacking tree (1.8.0-1) ...",
                "Setting up tree (1.8.0-1) ...",
                "Processing triggers for man-db (2.9.1-1) ..."
        ]
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "cache_update_time": 1664804313,
        "cache_updated": false,
        "changed": true,
        "stderr": "",
        "stderr_lines": [],
        "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informat                                                                       
0 to remove and 18 not upgraded.\nNeed to get 43.0 kB of archives.\nAfter this
operation, 1                                                                         
ntu focal/universe amd64 tree amd64 1.8.0-1 [43.0 kB]\nFetched 43.0 kB in 0s (129
kB/s)\nSel                                                                           
%\r(Reading database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\
r(Reading                                                                           
. 40%\r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ...
55%\r(Rea                                                                           
e ... 75%\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading
database ... 90%\r                                                                   
directories currently installed.)\r\nPreparing to unpack .../tree_1.8.0-
1_amd64.deb ...\r\nU                                                                 
b (2.9.1-1) ...\r\n",
        "stdout_lines": [
                "Reading package lists...",
                "Building dependency tree...",
                "Reading state information...",
                "The following NEW packages will be installed:",
                "    tree",
                "0 upgraded, 1 newly installed, 0 to remove and 18 not upgraded.",
                "Need to get 43.0 kB of archives.",
                "After this operation, 115 kB of additional disk space will be
used.",
                "Get:1 http://nova.clouds.archive.ubuntu.com/ubuntu focal/universe
amd64 tree amd64
                "Fetched 43.0 kB in 0s (129 kB/s)",
                "Selecting previously unselected package tree.",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97537 files and directories currently
installed.)",
                "Preparing to unpack .../tree_1.8.0-1_amd64.deb ...",
                "Unpacking tree (1.8.0-1) ...",
                "Setting up tree (1.8.0-1) ...",
                "Processing triggers for man-db (2.9.1-1) ..."
        ]
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm service -a "name=cron state=stopped"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "name": "cron",
        "state": "stopped",
        "status": {
                "ActiveEnterTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ActiveEnterTimestampMonotonic": "3297087651422",
                "ActiveExitTimestamp": "Mon 2022-10-03 12:11:21 UTC",
                "ActiveExitTimestampMonotonic": "3297037132653",
                "ActiveState": "active",
                "After": "nss-user-lookup.target system.slice systemd-journald.socket
remote-fs.targ
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "AssertTimestampMonotonic": "3297087645970",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "no",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_fowner                                                       
e cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner
cap_sys_module cap_                                                                 
cap_sys_resource cap_sys_time cap_sys_tty_config cap_mknod cap_lease cap_audit_write
cap_au                                                                               
spend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ConditionTimestampMonotonic": "3297087645969",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlGroup": "/system.slice/cron.service",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "Regular background program processing daemon",
                "DevicePolicy": "auto",
                "Documentation": "man:cron(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "EnvironmentFiles": "/etc/default/cron (ignore_errors=yes)",
                "ExecMainCode": "0",
                "ExecMainExitTimestampMonotonic": "0",
                "ExecMainPID": "253639",
                "ExecMainStartTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ExecMainStartTimestampMonotonic": "3297087647720",
                "ExecMainStatus": "0",
                "ExecStart": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; ignore_
                "ExecStartEx": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; flags
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/cron.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "cron.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "no",
                "InactiveEnterTimestamp": "Mon 2022-10-03 12:11:21 UTC",
                "InactiveEnterTimestampMonotonic": "3297037133883",
                "InactiveExitTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "InactiveExitTimestampMonotonic": "3297087651422",
                "InvocationID": "1146685551e74a078e22588cc853b8b0",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "process",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "253639",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "2965504",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "cron.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "system.slice sysinit.target",
                "Restart": "on-failure",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "StateChangeTimestampMonotonic": "3297087651422",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "running",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "1",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "1min 30s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "1min 30s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "simple",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "name": "cron",
        "state": "stopped",
        "status": {
                "ActiveEnterTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ActiveEnterTimestampMonotonic": "15934843",
                "ActiveExitTimestampMonotonic": "0",
                "ActiveState": "active",
                "After": "nss-user-lookup.target basic.target sysinit.target systemd-
journald.socket
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "AssertTimestampMonotonic": "15930137",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "no",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_fowner                                                       
e cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner
cap_sys_module cap_                                                                 
cap_sys_resource cap_sys_time cap_sys_tty_config cap_mknod cap_lease cap_audit_write
cap_au                                                                               
spend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ConditionTimestampMonotonic": "15930135",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlGroup": "/system.slice/cron.service",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "Regular background program processing daemon",
                "DevicePolicy": "auto",
                "Documentation": "man:cron(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "EnvironmentFiles": "/etc/default/cron (ignore_errors=yes)",
                "ExecMainCode": "0",
                "ExecMainExitTimestampMonotonic": "0",
                "ExecMainPID": "679",
                "ExecMainStartTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ExecMainStartTimestampMonotonic": "15934762",
                "ExecMainStatus": "0",
                "ExecStart": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; ignore_
                "ExecStartEx": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; flags
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/cron.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "cron.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "no",
                "InactiveEnterTimestampMonotonic": "0",
                "InactiveExitTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "InactiveExitTimestampMonotonic": "15934843",
                "InvocationID": "dcee66e33a3a4a47a8ce4148d9734e2f",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "process",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "679",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "6848512",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "cron.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "sysinit.target system.slice",
                "Restart": "on-failure",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "StateChangeTimestampMonotonic": "15934843",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "running",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "1",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "1min 30s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "1min 30s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "simple",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm service -a "name=cron state=disabled"
146.59.158.16 | FAILED! => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false,
        "msg": "value of state must be one of: reloaded, restarted, started, stopped,
got: disab
}
141.95.160.133 | FAILED! => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false,
        "msg": "value of state must be one of: reloaded, restarted, started, stopped,
got: disab
}
ansadmin@svl200:~$ ansible all -bm service -a "name=cron enabled=no"
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "enabled": false,
        "name": "cron",
        "status": {
                "ActiveEnterTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ActiveEnterTimestampMonotonic": "15934843",
                "ActiveExitTimestamp": "Tue 2022-10-04 08:09:19 UTC",
                "ActiveExitTimestampMonotonic": "1719968363076",
                "ActiveState": "inactive",
                "After": "nss-user-lookup.target basic.target sysinit.target systemd-
journald.socket
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "AssertTimestampMonotonic": "15930137",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "no",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_fowner                                                       
e cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner
cap_sys_module cap_                                                                 
cap_sys_resource cap_sys_time cap_sys_tty_config cap_mknod cap_lease cap_audit_write
cap_au                                                                               
spend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ConditionTimestampMonotonic": "15930135",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "Regular background program processing daemon",
                "DevicePolicy": "auto",
                "Documentation": "man:cron(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "EnvironmentFiles": "/etc/default/cron (ignore_errors=yes)",
                "ExecMainCode": "2",
                "ExecMainExitTimestamp": "Tue 2022-10-04 08:09:19 UTC",
                "ExecMainExitTimestampMonotonic": "1719968363869",
                "ExecMainPID": "679",
                "ExecMainStartTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "ExecMainStartTimestampMonotonic": "15934762",
                "ExecMainStatus": "15",
                "ExecStart": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; ignore_                                                               
] ; pid=679 ; code=killed ; status=15/TERM }",
                "ExecStartEx": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; flags                                                                 
679 ; code=killed ; status=15/TERM }",
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/cron.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "cron.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "no",
                "InactiveEnterTimestamp": "Tue 2022-10-04 08:09:19 UTC",
                "InactiveEnterTimestampMonotonic": "1719968363887",
                "InactiveExitTimestamp": "Wed 2022-09-14 10:23:26 UTC",
                "InactiveExitTimestampMonotonic": "15934843",
                "InvocationID": "dcee66e33a3a4a47a8ce4148d9734e2f",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "process",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "0",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "[not set]",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "cron.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "sysinit.target system.slice",
                "Restart": "on-failure",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Tue 2022-10-04 08:09:19 UTC",
                "StateChangeTimestampMonotonic": "1719968363887",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "dead",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "[not set]",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "1min 30s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "1min 30s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "simple",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "enabled": false,
        "name": "cron",
        "status": {
                "ActiveEnterTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ActiveEnterTimestampMonotonic": "3297087651422",
                "ActiveExitTimestamp": "Tue 2022-10-04 08:09:18 UTC",
                "ActiveExitTimestampMonotonic": "3368914737265",
                "ActiveState": "inactive",
                "After": "nss-user-lookup.target system.slice systemd-journald.socket
remote-fs.targ
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "AssertTimestampMonotonic": "3297087645970",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "no",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_fowner                                                       
e cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner
cap_sys_module cap_                                                                 
cap_sys_resource cap_sys_time cap_sys_tty_config cap_mknod cap_lease cap_audit_write
cap_au                                                                               
spend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ConditionTimestampMonotonic": "3297087645969",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "Regular background program processing daemon",
                "DevicePolicy": "auto",
                "Documentation": "man:cron(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "EnvironmentFiles": "/etc/default/cron (ignore_errors=yes)",
                "ExecMainCode": "2",
                "ExecMainExitTimestamp": "Tue 2022-10-04 08:09:18 UTC",
                "ExecMainExitTimestampMonotonic": "3368914738115",
                "ExecMainPID": "253639",
                "ExecMainStartTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "ExecMainStartTimestampMonotonic": "3297087647720",
                "ExecMainStatus": "15",
                "ExecStart": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; ignore_                                                               
] ; pid=253639 ; code=killed ; status=15/TERM }",
                "ExecStartEx": "{ path=/usr/sbin/cron ; argv[]=/usr/sbin/cron -f
$EXTRA_OPTS ; flags                                                                 
253639 ; code=killed ; status=15/TERM }",
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/cron.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "cron.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "no",
                "InactiveEnterTimestamp": "Tue 2022-10-04 08:09:18 UTC",
                "InactiveEnterTimestampMonotonic": "3368914738600",
                "InactiveExitTimestamp": "Mon 2022-10-03 12:12:11 UTC",
                "InactiveExitTimestampMonotonic": "3297087651422",
                "InvocationID": "1146685551e74a078e22588cc853b8b0",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "process",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "0",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "[not set]",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "cron.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "system.slice sysinit.target",
                "Restart": "on-failure",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Tue 2022-10-04 08:09:18 UTC",
                "StateChangeTimestampMonotonic": "3368914738600",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "dead",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "[not set]",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "1min 30s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "1min 30s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "simple",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -m file -a "path=/tmp/test.txt state=touch mode=0644"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "dest": "/tmp/test.txt",
        "gid": 1006,
        "group": "ansadmin",
        "mode": "0644",
        "owner": "ansadmin",
        "size": 0,
        "state": "file",
        "uid": 1006
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "dest": "/tmp/test.txt",
        "gid": 1003,
        "group": "ansadmin",
        "mode": "0644",
        "owner": "ansadmin",
        "size": 0,
        "state": "file",
        "uid": 1003
}
ansadmin@svl200:~$ ansible all -m shell -a "ls -lrt /tmp/test.txt | grep test"
141.95.160.133 | CHANGED | rc=0 >>
-rw-r--r-- 1 ansadmin ansadmin 0 Oct    4 08:16 /tmp/test.txt
146.59.158.16 | CHANGED | rc=0 >>
-rw-r--r-- 1 ansadmin ansadmin 0 Oct    4 08:16 /tmp/test.txt
ansadmin@svl200:~$ ansible all -m shell -a "ls -lrt /tmp | grep test"
146.59.158.16 | CHANGED | rc=0 >>
-rw-r--r-- 1 ansadmin ansadmin        0 Oct    4 08:16 test.txt
141.95.160.133 | CHANGED | rc=0 >>
-rw-r--r-- 1 ansadmin ansadmin        0 Oct    4 08:16 test.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -m directory -a "path=/tmp/dir state= mode=755"
146.59.158.16 | FAILED! => {
        "msg": "The module directory was not found in configured module paths"
}
141.95.160.133 | FAILED! => {
        "msg": "The module directory was not found in configured module paths"
}
ansadmin@svl200:~$ ansible all -m dir -a "path=/tmp/dir state= mode=755"
141.95.160.133 | FAILED! => {
        "msg": "The module dir was not found in configured module paths"
}
146.59.158.16 | FAILED! => {
        "msg": "The module dir was not found in configured module paths"
}
ansadmin@svl200:~$ ansible all -m file -a "path=/tmp/dir state=directory    mode=755"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1006,
        "group": "ansadmin",
        "mode": "0755",
        "owner": "ansadmin",
        "path": "/tmp/dir",
        "size": 4096,
        "state": "directory",
        "uid": 1006
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "gid": 1003,
        "group": "ansadmin",
        "mode": "0755",
        "owner": "ansadmin",
        "path": "/tmp/dir",
        "size": 4096,
        "state": "directory",
        "uid": 1003
}
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm apt -a "name=* state=latest"
146.59.158.16 | SUCCESS => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false,
        "msg": "Reading package lists...\nBuilding dependency tree...\nReading state
information                                                                         
",
        "stderr": "",
        "stderr_lines": [],
        "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informat                                                                       
.\n",
        "stdout_lines": [
                "Reading package lists...",
                "Building dependency tree...",
                "Reading state information...",
                "Calculating upgrade...",
                "0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded."
        ]
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "msg": "Reading package lists...\nBuilding dependency tree...\nReading state
information                                                                         
n0 libnss-systemd libpam-systemd libsystemd0\n    libtss2-esys0 libudev1 motd-news-
config netp                                                                         
syncd\n    ubuntu-advantage-tools ubuntu-release-upgrader-core udev\n18 upgraded, 0
newly inst                                                                           
n, 2594 kB disk space will be freed.\nGet:1
http://nova.clouds.archive.ubuntu.com/ubuntu foc                                     
hive.ubuntu.com/ubuntu focal-updates/main amd64 base-files amd64 11ubuntu5.6 [60.4
kB]\nGet:                                                                           
245.4-4ubuntu3.18 [96.1 kB]\nGet:4 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-update                                                                         
com/ubuntu focal-updates/main amd64 libudev1 amd64 245.4-4ubuntu3.18 [76.3 kB]\nGet:6
http:/                                                                               
ntu3.18 [10.3 kB]\nGet:7 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd                                                               
tu.com/ubuntu focal-updates/main amd64 libpam-systemd amd64 245.4-4ubuntu3.18 [186
kB]\nGet:                                                                           
ubuntu3.18 [3808 kB]\nGet:10 http://nova.clouds.archive.ubuntu.com/ubuntu focal-
updates/main                                                                         
.com/ubuntu focal-updates/main amd64 netplan.io amd64 0.104-0ubuntu2~20.04.2 [88.0
kB]\nGet:                                                                           
104-0ubuntu2~20.04.2 [82.5 kB]\nGet:13 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-up                                                                             
uds.archive.ubuntu.com/ubuntu focal-updates/main amd64 python3-apt amd64
2.0.0ubuntu0.20.04.                                                                 
tu-advantage-tools amd64 27.10.1~20.04.1 [146 kB]\nGet:16
http://nova.clouds.archive.ubuntu.                                                   
t:17 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 python3-
distupgra                                                                           
/main amd64 libtss2-esys0 amd64 2.3.2-1ubuntu0.20.04.1 [226 kB]\nPreconfiguring
packages ...                                                                         
ng database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\r(Reading
database                                                                             
eading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Reading data                                                                       
\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading database ... 90%\
r(Reading                                                                           
es currently installed.)\r\nPreparing to unpack .../motd-news-
config_11ubuntu5.6_all.deb ...                                                       
./base-files_11ubuntu5.6_amd64.deb ...\r\nWarning: Stopping motd-news.service, but it
can st                                                                               
u5.5) ...\r\nSetting up base-files (11ubuntu5.6) ...\r\nInstalling new version of
config fil                                                                           
w version of config file /etc/lsb-release ...\r\nmotd-news.service is a disabled or a
static                                                                               
e ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\r(Reading
database ... 25%\r                                                                   
abase ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\r(Reading
database ... 6                                                                       
database ... 80%\r(Reading database ... 85%\r(Reading database ... 90%\r(Reading
database .                                                                           
ly installed.)\r\nPreparing to unpack .../libnss-systemd_245.4-
4ubuntu3.18_amd64.deb ...\r\n                                                       
to unpack .../udev_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking udev (245.4-
4ubuntu3.18) ove                                                                     
\r\nUnpacking libudev1:amd64 (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\
nSetting up                                                                         
Reading database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\
r(Reading dat                                                                       
%\r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Reading                                                                           
. 75%\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading database ...
90%\r(Rea                                                                           
ctories currently installed.)\r\nPreparing to unpack .../systemd-sysv_245.4-
4ubuntu3.18_amd6                                                                     
ring to unpack .../systemd-timesyncd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking
systemd-ti                                                                           
stemd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking libpam-systemd:amd64 (245.4-
4ubuntu3.18)                                                                         
..\r\nUnpacking systemd (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nPreparing
to unp                                                                               
untu3.18) over (245.4-4ubuntu3.17) ...\r\nSetting up libsystemd0:amd64 (245.4-
4ubuntu3.18) .                                                                       
atabase ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\r(Reading
database ...                                                                         
ng database ... 50%\r(Reading database ... 55%\r(Reading database ... 60%\r(Reading
database                                                                             
eading database ... 85%\r(Reading database ... 90%\r(Reading database ... 95%\
r(Reading data                                                                       
paring to unpack .../0-netplan.io_0.104-0ubuntu2~20.04.2_amd64.deb ...\r\nUnpacking
netplan.                                                                             
bnetplan0_0.104-0ubuntu2~20.04.2_amd64.deb ...\r\nUnpacking libnetplan0:amd64 (0.104-
0ubuntu                                                                             
.0.0ubuntu0.20.04.8_all.deb ...\r\nUnpacking python-apt-common (2.0.0ubuntu0.20.04.8)
over (                                                                               
.deb ...\r\nUnpacking python3-apt (2.0.0ubuntu0.20.04.8) over
(2.0.0ubuntu0.20.04.7) ...\r\n                                                       
buntu-advantage-tools (27.10.1~20.04.1) over (27.9~20.04.1) ...\r\nPreparing to
unpack .../5                                                                         
ore (1:20.04.39) over (1:20.04.38) ...\r\nPreparing to unpack .../6-python3-
distupgrade_1%3a                                                                     
reparing to unpack .../7-libtss2-esys0_2.3.2-1ubuntu0.20.04.1_amd64.deb ...\r\
nUnpacking lib                                                                       
tu5.6) ...\r\nSetting up libtss2-esys0 (2.3.2-1ubuntu0.20.04.1) ...\r\nSetting up
libnetplan                                                                           
tramfs: deferring update (trigger activated)\r\nSetting up python-apt-common
(2.0.0ubuntu0.2                                                                     
grade (1:20.04.39) ...\r\nSetting up ubuntu-release-upgrader-core (1:20.04.39) ...\r\
nSettin                                                                             
..\r\nSetting up netplan.io (0.104-0ubuntu2~20.04.2) ...\r\nSetting up systemd-
timesyncd (24                                                                       
systemd:amd64 (245.4-4ubuntu3.18) ...\r\nSetting up libpam-systemd:amd64 (245.4-
4ubuntu3.18)                                                                         
libc-bin (2.31-0ubuntu9.9) ...\r\nProcessing triggers for man-db (2.9.1-1) ...\r\
nProcessing                                                                         
s: deferring update (trigger activated)\r\nProcessing triggers for dbus (1.12.16-
2ubuntu2.2)                                                                         
erating /boot/initrd.img-5.4.0-126-generic\r\n",
        "stderr": "",
        "stderr_lines": [],
        "stdout": "Reading package lists...\nBuilding dependency tree...\nReading
state informat                                                                       
plan0 libnss-systemd libpam-systemd libsystemd0\n    libtss2-esys0 libudev1 motd-
news-config n                                                                       
imesyncd\n    ubuntu-advantage-tools ubuntu-release-upgrader-core udev\n18 upgraded,
0 newly i                                                                           
tion, 2594 kB disk space will be freed.\nGet:1
http://nova.clouds.archive.ubuntu.com/ubuntu                                         
archive.ubuntu.com/ubuntu focal-updates/main amd64 base-files amd64 11ubuntu5.6 [60.4
kB]\nG                                                                               
64 245.4-4ubuntu3.18 [96.1 kB]\nGet:4 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-upd                                                                           
tu.com/ubuntu focal-updates/main amd64 libudev1 amd64 245.4-4ubuntu3.18 [76.3 kB]\
nGet:6 htt                                                                           
ubuntu3.18 [10.3 kB]\nGet:7 http://nova.clouds.archive.ubuntu.com/ubuntu focal-
updates/main                                                                         
buntu.com/ubuntu focal-updates/main amd64 libpam-systemd amd64 245.4-4ubuntu3.18 [186
kB]\nG                                                                               
4-4ubuntu3.18 [3808 kB]\nGet:10 http://nova.clouds.archive.ubuntu.com/ubuntu focal-
updates/m                                                                           
ntu.com/ubuntu focal-updates/main amd64 netplan.io amd64 0.104-0ubuntu2~20.04.2 [88.0
kB]\nG                                                                               
0.104-0ubuntu2~20.04.2 [82.5 kB]\nGet:13 http://nova.clouds.archive.ubuntu.com/ubuntu
focal                                                                               
clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64 python3-apt amd64
2.0.0ubuntu0.20.                                                                     
buntu-advantage-tools amd64 27.10.1~20.04.1 [146 kB]\nGet:16
http://nova.clouds.archive.ubun                                                     
nGet:17 http://nova.clouds.archive.ubuntu.com/ubuntu focal-updates/main amd64
python3-distup                                                                       
tes/main amd64 libtss2-esys0 amd64 2.3.2-1ubuntu0.20.04.1 [226 kB]\nPreconfiguring
packages                                                                             
ading database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\
r(Reading datab                                                                     
r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Reading d                                                                         
75%\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading database ... 90%\
r(Readi                                                                             
ories currently installed.)\r\nPreparing to unpack .../motd-news-
config_11ubuntu5.6_all.deb                                                           
.../base-files_11ubuntu5.6_amd64.deb ...\r\nWarning: Stopping motd-news.service, but
it can                                                                               
untu5.5) ...\r\nSetting up base-files (11ubuntu5.6) ...\r\nInstalling new version of
config                                                                               
new version of config file /etc/lsb-release ...\r\nmotd-news.service is a disabled or
a sta                                                                               
base ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\r(Reading database
... 25                                                                               
database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\r(Reading
database ..                                                                         
ing database ... 80%\r(Reading database ... 85%\r(Reading database ... 90%\r(Reading
databas                                                                             
ently installed.)\r\nPreparing to unpack .../libnss-systemd_245.4-
4ubuntu3.18_amd64.deb ...\                                                           
ng to unpack .../udev_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking udev (245.4-
4ubuntu3.18)                                                                         
...\r\nUnpacking libudev1:amd64 (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\
nSetting                                                                             
\r(Reading database ... 10%\r(Reading database ... 15%\r(Reading database ... 20%\
r(Reading                                                                           
40%\r(Reading database ... 45%\r(Reading database ... 50%\r(Reading database ... 55%\
r(Read                                                                               
... 75%\r(Reading database ... 80%\r(Reading database ... 85%\r(Reading database ...
90%\r(                                                                               
irectories currently installed.)\r\nPreparing to unpack .../systemd-sysv_245.4-
4ubuntu3.18_a                                                                       
eparing to unpack .../systemd-timesyncd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking
systemd                                                                             
-systemd_245.4-4ubuntu3.18_amd64.deb ...\r\nUnpacking libpam-systemd:amd64 (245.4-
4ubuntu3.1                                                                           
b ...\r\nUnpacking systemd (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\
nPreparing to                                                                       
4ubuntu3.18) over (245.4-4ubuntu3.17) ...\r\nSetting up libsystemd0:amd64 (245.4-
4ubuntu3.18                                                                         
g database ... 15%\r(Reading database ... 20%\r(Reading database ... 25%\r(Reading
database                                                                             
ading database ... 50%\r(Reading database ... 55%\r(Reading database ... 60%\
r(Reading datab                                                                     
r(Reading database ... 85%\r(Reading database ... 90%\r(Reading database ... 95%\
r(Reading d                                                                         
Preparing to unpack .../0-netplan.io_0.104-0ubuntu2~20.04.2_amd64.deb ...\r\
nUnpacking netpl                                                                     
-libnetplan0_0.104-0ubuntu2~20.04.2_amd64.deb ...\r\nUnpacking libnetplan0:amd64
(0.104-0ubu                                                                         
n_2.0.0ubuntu0.20.04.8_all.deb ...\r\nUnpacking python-apt-common
(2.0.0ubuntu0.20.04.8) ove                                                           
d64.deb ...\r\nUnpacking python3-apt (2.0.0ubuntu0.20.04.8) over
(2.0.0ubuntu0.20.04.7) ...\                                                         
g ubuntu-advantage-tools (27.10.1~20.04.1) over (27.9~20.04.1) ...\r\nPreparing to
unpack ..                                                                           
r-core (1:20.04.39) over (1:20.04.38) ...\r\nPreparing to unpack .../6-python3-
distupgrade_1                                                                       
\nPreparing to unpack .../7-libtss2-esys0_2.3.2-1ubuntu0.20.04.1_amd64.deb ...\r\
nUnpacking                                                                           
buntu5.6) ...\r\nSetting up libtss2-esys0 (2.3.2-1ubuntu0.20.04.1) ...\r\nSetting up
libnetp                                                                             
initramfs: deferring update (trigger activated)\r\nSetting up python-apt-common
(2.0.0ubuntu                                                                         
tupgrade (1:20.04.39) ...\r\nSetting up ubuntu-release-upgrader-core
(1:20.04.39) ...\r\nSet                                                             
) ...\r\nSetting up netplan.io (0.104-0ubuntu2~20.04.2) ...\r\nSetting up systemd-
timesyncd                                                                           
ss-systemd:amd64 (245.4-4ubuntu3.18) ...\r\nSetting up libpam-systemd:amd64 (245.4-
4ubuntu3.                                                                           
or libc-bin (2.31-0ubuntu9.9) ...\r\nProcessing triggers for man-db (2.9.1-1) ...\r\
nProcess                                                                             
amfs: deferring update (trigger activated)\r\nProcessing triggers for dbus (1.12.16-
2ubuntu2                                                                             
Generating /boot/initrd.img-5.4.0-126-generic\r\n",
        "stdout_lines": [
                "Reading package lists...",
                "Building dependency tree...",
                "Reading state information...",
                "Calculating upgrade...",
                "The following packages will be upgraded:",
                "    base-files libnetplan0 libnss-systemd libpam-systemd
libsystemd0",
                "    libtss2-esys0 libudev1 motd-news-config netplan.io python-apt-
common",
                "    python3-apt python3-distupgrade systemd systemd-sysv systemd-
timesyncd",
                "    ubuntu-advantage-tools ubuntu-release-upgrader-core udev",
                "18 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.",
                "Need to get 6747 kB of archives.",
                "After this operation, 2594 kB disk space will be freed.",
                "Get:1 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 motd-ne
                "Get:2 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 base-fi
                "Get:3 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libnss-
                "Get:4 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 udev am
                "Get:5 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libudev
                "Get:6 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 systemd
                "Get:7 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 systemd
                "Get:8 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libpam-
                "Get:9 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 systemd
                "Get:10 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libsys
                "Get:11 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 netpla
                "Get:12 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libnet
                "Get:13 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 python
                "Get:14 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 python
                "Get:15 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 ubuntu
                "Get:16 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 ubuntu
                "Get:17 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 python
                "Get:18 http://nova.clouds.archive.ubuntu.com/ubuntu
focal-updates/main amd64 libtss
                "Preconfiguring packages ...",
                "Fetched 6747 kB in 1s (6785 kB/s)",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97544 files and directories currently
installed.)",
                "Preparing to unpack .../motd-news-config_11ubuntu5.6_all.deb ...",
                "Unpacking motd-news-config (11ubuntu5.6) over (11ubuntu5.5) ...",
                "Preparing to unpack .../base-files_11ubuntu5.6_amd64.deb ...",
                "Warning: Stopping motd-news.service, but it can still be activated
by:",
                "    motd-news.timer",
                "Unpacking base-files (11ubuntu5.6) over (11ubuntu5.5) ...",
                "Setting up base-files (11ubuntu5.6) ...",
                "Installing new version of config file /etc/issue ...",
                "Installing new version of config file /etc/issue.net ...",
                "Installing new version of config file /etc/lsb-release ...",
                "motd-news.service is a disabled or a static unit, not starting it.",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97544 files and directories currently
installed.)",
                "Preparing to unpack .../libnss-systemd_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking libnss-systemd:amd64 (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Preparing to unpack .../udev_245.4-4ubuntu3.18_amd64.deb ...",
                "Unpacking udev (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...",
                "Preparing to unpack .../libudev1_245.4-4ubuntu3.18_amd64.deb ...",
                "Unpacking libudev1:amd64 (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Setting up libudev1:amd64 (245.4-4ubuntu3.18) ...",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97544 files and directories currently
installed.)",
                "Preparing to unpack .../systemd-sysv_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking systemd-sysv (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Preparing to unpack .../systemd-timesyncd_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking systemd-timesyncd (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Preparing to unpack .../libpam-systemd_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking libpam-systemd:amd64 (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Preparing to unpack .../systemd_245.4-4ubuntu3.18_amd64.deb ...",
                "Unpacking systemd (245.4-4ubuntu3.18) over (245.4-4ubuntu3.17) ...",
                "Preparing to unpack .../libsystemd0_245.4-
4ubuntu3.18_amd64.deb ...",
                "Unpacking libsystemd0:amd64 (245.4-4ubuntu3.18) over (245.4-
4ubuntu3.17) ...",
                "Setting up libsystemd0:amd64 (245.4-4ubuntu3.18) ...",
                "(Reading database ... ",
                "(Reading database ... 5%",
                "(Reading database ... 10%",
                "(Reading database ... 15%",
                "(Reading database ... 20%",
                "(Reading database ... 25%",
                "(Reading database ... 30%",
                "(Reading database ... 35%",
                "(Reading database ... 40%",
                "(Reading database ... 45%",
                "(Reading database ... 50%",
                "(Reading database ... 55%",
                "(Reading database ... 60%",
                "(Reading database ... 65%",
                "(Reading database ... 70%",
                "(Reading database ... 75%",
                "(Reading database ... 80%",
                "(Reading database ... 85%",
                "(Reading database ... 90%",
                "(Reading database ... 95%",
                "(Reading database ... 100%",
                "(Reading database ... 97544 files and directories currently
installed.)",
                "Preparing to unpack .../0-netplan.io_0.104-
0ubuntu2~20.04.2_amd64.deb ...",
                "Unpacking netplan.io (0.104-0ubuntu2~20.04.2) over (0.104-
0ubuntu2~20.04.1) ...",
                "Preparing to unpack .../1-libnetplan0_0.104-
0ubuntu2~20.04.2_amd64.deb ...",
                "Unpacking libnetplan0:amd64 (0.104-0ubuntu2~20.04.2) over (0.104-
0ubuntu2~20.04.1)
                "Preparing to unpack .../2-python-apt-
common_2.0.0ubuntu0.20.04.8_all.deb ...",
                "Unpacking python-apt-common (2.0.0ubuntu0.20.04.8) over
(2.0.0ubuntu0.20.04.7) ..."
                "Preparing to unpack .../3-python3-apt_2.0.0ubuntu0.20.04.8_amd64.deb
...",
                "Unpacking python3-apt (2.0.0ubuntu0.20.04.8) over
(2.0.0ubuntu0.20.04.7) ...",
                "Preparing to unpack .../4-ubuntu-advantage-
tools_27.10.1~20.04.1_amd64.deb ...",
                "Unpacking ubuntu-advantage-tools (27.10.1~20.04.1) over
(27.9~20.04.1) ...",
                "Preparing to unpack .../5-ubuntu-release-upgrader-
core_1%3a20.04.39_all.deb ...",
                "Unpacking ubuntu-release-upgrader-core (1:20.04.39) over
(1:20.04.38) ...",
                "Preparing to unpack .../6-python3-
distupgrade_1%3a20.04.39_all.deb ...",
                "Unpacking python3-distupgrade (1:20.04.39) over (1:20.04.38) ...",
                "Preparing to unpack .../7-libtss2-esys0_2.3.2-
1ubuntu0.20.04.1_amd64.deb ...",
                "Unpacking libtss2-esys0 (2.3.2-1ubuntu0.20.04.1) over (2.3.2-
1) ...",
                "Setting up motd-news-config (11ubuntu5.6) ...",
                "Setting up libtss2-esys0 (2.3.2-1ubuntu0.20.04.1) ...",
                "Setting up libnetplan0:amd64 (0.104-0ubuntu2~20.04.2) ...",
                "Setting up udev (245.4-4ubuntu3.18) ...",
                "update-initramfs: deferring update (trigger activated)",
                "Setting up python-apt-common (2.0.0ubuntu0.20.04.8) ...",
                "Setting up python3-apt (2.0.0ubuntu0.20.04.8) ...",
                "Setting up python3-distupgrade (1:20.04.39) ...",
                "Setting up ubuntu-release-upgrader-core (1:20.04.39) ...",
                "Setting up ubuntu-advantage-tools (27.10.1~20.04.1) ...",
                "Setting up systemd (245.4-4ubuntu3.18) ...",
                "Setting up netplan.io (0.104-0ubuntu2~20.04.2) ...",
                "Setting up systemd-timesyncd (245.4-4ubuntu3.18) ...",
                "Setting up systemd-sysv (245.4-4ubuntu3.18) ...",
                "Setting up libnss-systemd:amd64 (245.4-4ubuntu3.18) ...",
                "Setting up libpam-systemd:amd64 (245.4-4ubuntu3.18) ...",
                "Processing triggers for install-info (6.7.0.dfsg.2-5) ...",
                "Processing triggers for libc-bin (2.31-0ubuntu9.9) ...",
                "Processing triggers for man-db (2.9.1-1) ...",
                "Processing triggers for plymouth-theme-ubuntu-text
(0.9.4git20200323-0ubuntu6.2) ..
                "update-initramfs: deferring update (trigger activated)",
                "Processing triggers for dbus (1.12.16-2ubuntu2.2) ...",
                "Processing triggers for initramfs-tools (0.136ubuntu6.7) ...",
                "update-initramfs: Generating /boot/initrd.img-5.4.0-126-generic"
        ]
}
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo2.yaml
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ ansible-playbook exo3.yaml
ERROR! conflicting action statements: shell, uid

The error appears to be in '/home/ansadmin/exo3.yaml': line 7, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: utilisateur
            ^ here
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ ansible-playbook exo3.yaml
ERROR! unexpected parameter type in action: <class 'int'>

The error appears to be in '/home/ansadmin/exo3.yaml': line 7, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


    tasks:
        - name: adduser supervision
            ^ here
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook exo3.yaml
ERROR! A malformed block was encountered while loading tasks: {'user': [{'name':
'supervisio                                                                         
'uid': '5000', 'groups': 'rennes'}]} should be a list or None but is <class
'ansible.parsin                                                                     
aml.objects.AnsibleMapping'>

The error appears to be in '/home/ansadmin/exo3.yaml': line 2, column 3, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: creation d'utilisateur
    ^ here
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ ansible-playbook exo3.yaml

PLAY [creation d'utilisateur]


**************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creer user]


**************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ ansible -bm shell -a "id supervision"


usage: ansible [-h] [--version] [-v] [-b] [--become-method BECOME_METHOD]
                              [--become-user BECOME_USER] [-K] [-i INVENTORY] [--
list-hosts] [-l SUBSET]
                              [-P POLL_INTERVAL] [-B SECONDS] [-o] [-t TREE] [-k]
                              [--private-key PRIVATE_KEY_FILE] [-u REMOTE_USER] [-c
CONNECTION] [-T TIMEOUT
                              [--ssh-common-args SSH_COMMON_ARGS] [--sftp-extra-args
SFTP_EXTRA_ARGS]
                              [--scp-extra-args SCP_EXTRA_ARGS] [--ssh-extra-args
SSH_EXTRA_ARGS] [-C]
                              [--syntax-check] [-D] [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                              [--ask-vault-pass | --vault-password-file
VAULT_PASSWORD_FILES] [-f FORKS]
                              [-M MODULE_PATH] [--playbook-dir BASEDIR] [-a
MODULE_ARGS] [-m MODULE_NAME]
                              pattern
ansible: error: the following arguments are required: pattern
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible -bm shell -a "cat /etc/passwd | grep super"
usage: ansible [-h] [--version] [-v] [-b] [--become-method BECOME_METHOD]
                              [--become-user BECOME_USER] [-K] [-i INVENTORY] [--
list-hosts] [-l SUBSET]
                              [-P POLL_INTERVAL] [-B SECONDS] [-o] [-t TREE] [-k]
                              [--private-key PRIVATE_KEY_FILE] [-u REMOTE_USER] [-c
CONNECTION] [-T TIMEOUT
                              [--ssh-common-args SSH_COMMON_ARGS] [--sftp-extra-args
SFTP_EXTRA_ARGS]
                              [--scp-extra-args SCP_EXTRA_ARGS] [--ssh-extra-args
SSH_EXTRA_ARGS] [-C]
                              [--syntax-check] [-D] [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                              [--ask-vault-pass | --vault-password-file
VAULT_PASSWORD_FILES] [-f FORKS]
                              [-M MODULE_PATH] [--playbook-dir BASEDIR] [-a
MODULE_ARGS] [-m MODULE_NAME]
                              pattern
ansible: error: the following arguments are required: pattern
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible -b -m shell -a "cat /etc/passwd | grep super"
usage: ansible [-h] [--version] [-v] [-b] [--become-method BECOME_METHOD]
                              [--become-user BECOME_USER] [-K] [-i INVENTORY] [--
list-hosts] [-l SUBSET]
                              [-P POLL_INTERVAL] [-B SECONDS] [-o] [-t TREE] [-k]
                              [--private-key PRIVATE_KEY_FILE] [-u REMOTE_USER] [-c
CONNECTION] [-T TIMEOUT
                              [--ssh-common-args SSH_COMMON_ARGS] [--sftp-extra-args
SFTP_EXTRA_ARGS]
                              [--scp-extra-args SCP_EXTRA_ARGS] [--ssh-extra-args
SSH_EXTRA_ARGS] [-C]
                              [--syntax-check] [-D] [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                              [--ask-vault-pass | --vault-password-file
VAULT_PASSWORD_FILES] [-f FORKS]
                              [-M MODULE_PATH] [--playbook-dir BASEDIR] [-a
MODULE_ARGS] [-m MODULE_NAME]
                              pattern
ansible: error: the following arguments are required: pattern
ansadmin@svl200:~$ ansible all -b -m shell -a "cat /etc/passwd | grep super"
146.59.158.16 | CHANGED | rc=0 >>
supervision:x:5000:5000::/home/supervision:/bin/sh
141.95.160.133 | CHANGED | rc=0 >>
supervision:x:5000:5000::/home/supervision:/bin/sh
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ cd /etc/ap
apache2/        apparmor/      apparmor.d/ apport/          apt/
ansadmin@svl200:~$
---
- name: Deployer apache
    hosts: cible1
    become: true

    tasks:
        - name: deploiement

Network error: Software caused connection abort


~
─────────────────────────────────────────────────────────────────────────────────────
───────
~
Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
-- INSERT --                                                                         
8,7                      A

Network error: Connection timed out

─────────────────────────────────────────────────────────────────────────────────────
───────
Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Last login: Tue Oct    4 07:50:40 2022 from 176.160.191.208


ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ ansible-playbook exo4.yaml
ERROR! conflicting action statements: apt, state

The error appears to be in '/home/ansadmin/exo4.yaml': line 7, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: deploiement
            ^ here
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ ansible-playbook exo4.yaml

PLAY [Deployer apache]


*********************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]

TASK [deploiement]
*************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "No package matching
'apache' i                                                                           
vailable"}

PLAY RECAP
*********************************************************************************
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ ansible-playbook exo4.yaml

PLAY [Deployer apache]


*********************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [deploiement]
*************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "No package matching
'apache' i                                                                           
vailable"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "No package matching
'apache'                                                                             
available"}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim exo4.yaml


ansadmin@svl200:~$ ansible-playbook exo4.yaml

PLAY [Deployer apache]


*********************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [deploiement]
*************************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=0                                                           
cued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=0                                                           
cued=0        ignored=0

ansadmin@svl200:~$ sudo vim exo4.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when1.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim when.yaml
ansadmin@svl200:~$ sudo vim when1.yaml
ansadmin@svl200:~$ ansible-playbook when1.yaml

PLAY [exemple avec condition when]


****************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install httpd on centos]


********************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [install apache2 on ubuntu]


******************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=                                                             
1        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=                                                             
1        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim when1.yaml


ansadmin@svl200:~$ sudo vim rep.yaml
ansadmin@svl200:~$ ansible-playbook rep.yaml
PLAY [Creation de repertoire]
*********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation]
***********************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation]
***********************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=                                                             
1        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=                                                             
1        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim rep.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /etc"
146.59.158.16 | CHANGED | rc=0 >>
total 884
-rw-r--r-- 1 root root                887 Apr    1    2013 rpc
-rw-r--r-- 1 root root              2932 Apr    1    2013 protocols
-rw-r--r-- 1 root root                280 Jun 20    2014 fuse.conf
-rw-r--r-- 1 root root              3663 Jun 20    2016 screenrc
-rw-r--r-- 1 root root                604 Sep 15    2018 deluser.conf
-rw-r----- 1 root daemon            144 Nov 12    2018 at.deny
-rw-r--r-- 1 root root              1260 Dec 14    2018 ucf.conf
-rw-r--r-- 1 root root                533 Jan 21    2019 logrotate.conf
-rw-r--r-- 1 root root            14867 Feb    1    2019 ltrace.conf
-rw-r--r-- 1 root root              2969 Aug    3    2019 debconf.conf
-rw-r--r-- 1 root root              5060 Aug 21    2019 hdparm.conf
-rw-r--r-- 1 root root                642 Sep 24    2019 xattr.conf
-rw-r--r-- 1 root root            24546 Oct 18    2019 mime.types
-rw-r--r-- 1 root root                449 Oct 18    2019 mailcap.order
-rw-r--r-- 1 root root                581 Dec    5    2019 profile
-rw-r--r-- 1 root root                  91 Dec    5    2019 networks
-rw-r--r-- 1 root root                267 Dec    5    2019 legal
-rw-r--r-- 1 root root                  92 Dec    5    2019 host.conf
-rw-r--r-- 1 root root                  13 Dec    5    2019 debian_version
-rw-r--r-- 1 root root                552 Dec 17    2019 pam.conf
-rw-r--r-- 1 root root              1816 Dec 27    2019 ethertypes
-rw-r--r-- 1 root root                111 Jan 16    2020 magic.mime
-rw-r--r-- 1 root root                111 Jan 16    2020 magic
-rw-r--r-- 1 root root                  45 Jan 26    2020 bash_completion
-rw-r--r-- 1 root root              2584 Feb    1    2020 gai.conf
-r--r----- 1 root root                755 Feb    3    2020 sudoers
-rw-r--r-- 1 root root            10037 Feb    7    2020 nanorc
-rw-r--r-- 1 root root            10550 Feb    7    2020 login.defs
-rw-r--r-- 1 root root              1523 Feb 10    2020 usb_modeswitch.conf
-rw-r--r-- 1 root root              1382 Feb 11    2020 rsyslog.conf
-rw-r--r-- 1 root root              1042 Feb 13    2020 crontab
-rw-r--r-- 1 root root              2351 Feb 13    2020 sysctl.conf
-rw-r--r-- 1 root root                808 Feb 14    2020 mke2fs.conf
-rw-r--r-- 1 root root                685 Feb 14    2020 e2scrub.conf
-rw-r--r-- 1 root root            14464 Feb 16    2020 services
-rw-r--r-- 1 root root                191 Feb 18    2020 libaudit.conf
drwxr-xr-x 2 root root              4096 Feb 24    2020 usb_modeswitch.d
-rw-r--r-- 1 root root              1748 Feb 25    2020 inputrc
-rw-r--r-- 1 root root              2319 Feb 25    2020 bash.bashrc
-rw-r--r-- 1 root root              5215 Feb 25    2020 manpath.config
-rw-r--r-- 1 root root                  41 Apr    6    2020 multipath.conf
-rw-r--r-- 1 root root              2996 Apr 14    2020 locale.alias
-rw-r--r-- 1 root root                  34 Apr 14    2020 ld.so.conf
-rw-r--r-- 1 root root                367 Apr 14    2020 bindresvport.blacklist
drwxr-xr-x 2 root root              4096 Apr 22    2020 binfmt.d
-rw-r--r-- 1 root root              6920 Nov    2    2021 overlayroot.conf
-rw-r--r-- 1 root root              4942 Nov 12    2021 wgetrc
-rw-r--r-- 1 root root                477 Feb 10    2022 zsh_command_not_found
drwxrwxr-x 2 root landscape    4096 Feb 14    2022 landscape
lrwxrwxrwx 1 root root                  13 Mar 15    2022 rmt -> /usr/sbin/rmt
-rw-r--r-- 1 root root            10593 Mar 31    2022 sensors3.conf
drwxr-xr-x 2 root root              4096 Apr 25 14:02 update-notifier
drwxr-xr-x 2 root root              4096 Jul 24 21:38 opt
drwxr-xr-x 2 root root              4096 Jul 24 21:38 selinux
drwxr-xr-x 2 root root              4096 Jul 24 21:38 terminfo
-rw-r--r-- 1 root root              3028 Jul 24 21:38 adduser.conf
lrwxrwxrwx 1 root root                  39 Jul 24 21:38 resolv.conf ->
../run/systemd/resolve/st                                                           
ub-resolv.conf
lrwxrwxrwx 1 root root                  19 Jul 24 21:38 mtab -> ../proc/self/mounts
drwxr-xr-x 7 root root              4096 Jul 24 21:38 apt
drwxr-xr-x 3 root root              4096 Jul 24 21:38 ca-certificates
drwxr-xr-x 4 root root              4096 Jul 24 21:38 dbus-1
drwxr-xr-x 8 root root              4096 Jul 24 21:38 networkd-dispatcher
drwxr-xr-x 4 root root              4096 Jul 24 21:38 xdg
drwxr-xr-x 2 root root              4096 Jul 24 21:38 cron.hourly
drwxr-xr-x 2 root root              4096 Jul 24 21:38 cron.monthly
-rw-r--r-- 1 root root                510 Jul 24 21:38 nsswitch.conf
-rw-r--r-- 1 root root                195 Jul 24 21:38 modules
drwxr-xr-x 2 root root              4096 Jul 24 21:38 newt
drwxr-xr-x 4 root root              4096 Jul 24 21:38 iproute2
-rw-r--r-- 1 root root              5713 Jul 24 21:38 ca-certificates.conf.dpkg-old
drwxr-xr-x 2 root root              4096 Jul 24 21:38 python3
lrwxrwxrwx 1 root root                  23 Jul 24 21:38 vtrgb ->
/etc/alternatives/vtrgb
drwxr-xr-x 2 root root              4096 Jul 24 21:38 skel
drwxr-xr-x 4 root root              4096 Jul 24 21:39 dpkg
drwxr-xr-x 2 root root              4096 Jul 24 21:39 ld.so.conf.d
drwxr-xr-x 4 root root              4096 Jul 24 21:39 security
-rw-r--r-- 1 root root                106 Jul 24 21:39 environment
drwxr-xr-x 4 root root              4096 Jul 24 21:39 ssl
drwxr-xr-x 2 root root              4096 Jul 24 21:39 python3.8
drwxr-xr-x 4 root root              4096 Jul 24 21:39 dhcp
drwxr-xr-x 2 root root              4096 Jul 24 21:39 depmod.d
-rw-r--r-- 1 root root              6821 Jul 24 21:39 ca-certificates.conf
-rw-r--r-- 1 root root                110 Jul 24 21:39 kernel-img.conf
drwxr-xr-x 3 root root              4096 Jul 24 21:39 perl
drwxr-xr-x 3 root root              4096 Jul 24 21:39 gss
-rw-r--r-- 1 root root                  54 Jul 24 21:39 crypttab
drwxr-xr-x 5 root root              4096 Jul 24 21:39 kernel
drwxr-xr-x 3 root root              4096 Jul 24 21:39 dconf
drwxr-xr-x 4 root root              4096 Jul 24 21:39 network
drwxr-xr-x 4 root root              4096 Jul 24 21:39 pki
drwxr-xr-x 3 root root              4096 Jul 24 21:39 pm
drwxr-xr-x 3 root root              4096 Jul 24 21:39 libblockdev
drwxr-xr-x 4 root root              4096 Jul 24 21:39 polkit-1
drwxr-xr-x 3 root root              4096 Jul 24 21:39 ModemManager
drwxr-xr-x 3 root root              4096 Jul 24 21:39 NetworkManager
drwxr-xr-x 2 root root              4096 Jul 24 21:39 ldap
drwxr-xr-x 3 root root              4096 Jul 24 21:39 apparmor
-rw-r--r-- 1 root root                711 Jul 24 21:39 hosts.deny
-rw-r--r-- 1 root root                411 Jul 24 21:39 hosts.allow
drwxr-xr-x 2 root root              4096 Jul 24 21:39 calendar
drwxr-xr-x 2 root root              4096 Jul 24 21:39 modprobe.d
drwxr-xr-x 2 root root              4096 Jul 24 21:39 mdadm
drwxr-xr-x 2 root root              4096 Jul 24 21:39 byobu
drwxr-xr-x 2 root root              4096 Jul 24 21:39 tmpfiles.d
-rw-r--r-- 1 root root                146 Jul 24 21:39 shells
drwxr-xr-x 2 root root              4096 Jul 24 21:39 iscsi
drwxr-xr-x 2 root root              4096 Jul 24 21:40 groff
drwxr-xr-x 5 root root              4096 Jul 24 21:40 initramfs-tools
drwxr-xr-x 2 root root              4096 Jul 24 21:40 rsyslog.d
drwxr-xr-x 3 root root              4096 Jul 24 21:40 ufw
drwxr-xr-x 2 root root              4096 Jul 24 21:40 cryptsetup-initramfs
drwxr-xr-x 2 root root              4096 Jul 24 21:40 udisks2
drwxr-xr-x 3 root root              4096 Jul 24 21:40 apport
drwxr-xr-x 2 root root              4096 Jul 24 21:40 bash_completion.d
drwxr-xr-x 2 root root              4096 Jul 24 21:40 pollinate
drwxr-xr-x 3 root root              4096 Jul 24 21:40 fwupd
drwxr-xr-x 3 root root              4096 Jul 24 21:40 lvm
drwxr-xr-x 2 root root              4096 Jul 24 21:40 cron.weekly
drwxr-xr-x 2 root root              4096 Jul 24 21:40 PackageKit
-rw-r--r-- 1 root root                  33 Jul 24 21:40 ec2_version
drwxr-xr-x 2 root root              4096 Jul 24 21:40 console-setup
-rw-r--r-- 1 root root                    0 Jul 24 21:40 popularity-contest.conf
-rw-r--r-- 1 root root              9440 Jul 24 21:40 locale.gen
-rw-r--r-- 1 root root                112 Jul 24 21:40 overlayroot.local.conf
-rw-r--r-- 1 root root                  84 Jul 24 21:41 fstab
drwxr-xr-x 2 root root              4096 Jul 24 21:41 grub.d
drwxr-xr-x 2 root root              4096 Aug    1 05:31 netplan
drwxr-xr-x 3 root root              4096 Aug    1 05:32 qemu
drwxr-xr-x 4 root root              4096 Aug    1 05:32 cloud
-rw-r--r-- 1 root root                104 Aug 22 10:53 lsb-release
lrwxrwxrwx 1 root root                  21 Aug 22 10:54 os-release -> ../usr/lib/os-
release
-rw-r--r-- 1 root root                  19 Aug 22 10:54 issue.net
-rw-r--r-- 1 root root                  26 Aug 22 10:54 issue
drwx------ 2 root root              4096 Aug 26 08:20 multipath
-r--r--r-- 1 root root                  33 Aug 26 08:20 machine-id
drwxr-xr-x 4 root root              4096 Aug 27 06:07 vmware-tools
-rw-r--r-- 1 root root                    8 Sep    8 06:16 timezone
lrwxrwxrwx 1 root root                  27 Sep    8 06:16 localtime ->
/usr/share/zoneinfo/Etc/UTC
drwxr-xr-x 5 root root              4096 Sep 19 09:45 vulkan
drwxr-xr-x 7 root root              4096 Sep 19 09:46 X11
drwxr-xr-x 2 root root              4096 Sep 19 09:46 rcS.d
drwxr-xr-x 2 root root              4096 Sep 19 09:46 sensors.d
drwxr-xr-x 4 root root              4096 Sep 19 09:46 fonts
drwxr-xr-x 2 root root              4096 Sep 19 09:46 environment.d
drwxr-xr-x 5 root root              4096 Sep 19 09:46 java-11-openjdk
-rw-r--r-- 1 root root                  15 Sep 20 05:01 hostname
drwxr-xr-x 2 root root              4096 Sep 20 06:40 vim
-rw-r--r-- 1 root root              3956 Sep 20 06:40 mailcap
-rw-r--r-- 1 root root                363 Sep 21 08:44 hosts
drwxr-xr-x 8 root root              4096 Sep 22 15:42 apache2
drwxr-xr-x 2 root root              4096 Sep 22 15:42 cron.daily
drwxr-xr-x 2 root root              4096 Sep 23 09:32 wildfly
drwxr-xr-x 2 root root              4096 Sep 25 18:18 process-exporter
drwxr-xr-x 6 root root              4096 Sep 28 06:24 sos
drwxr-xr-x 2 root root              4096 Oct    2 17:35 profile.d
drwxr-xr-x 2 root root              4096 Oct    2 17:35 sysctl.d
drwxr-xr-x 2 root root              4096 Oct    2 17:35 modules-load.d
drwxr-xr-x 4 root root              4096 Oct    2 17:35 udev
drwxr-xr-x 3 root root              4096 Oct    2 17:35 update-manager
drwxr-xr-x 2 root root              4096 Oct    2 17:35 ubuntu-advantage
drwxr-xr-x 2 root root              4096 Oct    2 17:35 update-motd.d
drwxr-xr-x 5 root root              4096 Oct    2 17:36 systemd
drwxr-xr-x 2 root root              4096 Oct    2 17:36 pam.d
drwxr-x--- 2 root root              4096 Oct    3 08:54 sudoers.d
drwxr-xr-x 4 root root              4096 Oct    3 08:56 ssh
drwxr-xr-x 8 root root              4096 Oct    3 12:32 nginx
-rw-r--r-- 1 root root                178 Oct    4 07:58 subuid-
-rw-r--r-- 1 root root                178 Oct    4 07:58 subgid-
-rw-r----- 1 root shadow            944 Oct    4 08:45 gshadow-
-rw-r--r-- 1 root root              1136 Oct    4 08:45 group-
-rw-r--r-- 1 root root                203 Oct    4 08:45 subuid
-rw-r--r-- 1 root root                203 Oct    4 08:45 subgid
-rw-r----- 1 root shadow          1907 Oct    4 08:59 shadow-
-rw-r--r-- 1 root root              2362 Oct    4 08:59 passwd-
-rw-r--r-- 1 root root              1149 Oct    4 08:59 group
-rw-r----- 1 root shadow            954 Oct    4 08:59 gshadow
-rw-r----- 1 root shadow          1907 Oct    4 08:59 shadow
-rw-r--r-- 1 root root              2377 Oct    4 08:59 passwd
drwxr-xr-x 6 root root              4096 Oct    4 08:59 logcheck
drwxr-xr-x 3 root root              4096 Oct    4 08:59 php
drwxr-xr-x 2 root root              4096 Oct    4 08:59 cron.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 alternatives
drwxr-xr-x 7 root root              4096 Oct    4 08:59 apparmor.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 insserv.conf.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 init.d
drwxr-xr-x 3 root root              4096 Oct    4 08:59 default
drwxr-xr-x 2 root root              4096 Oct    4 08:59 logrotate.d
drwxr-xr-x 4 root root              4096 Oct    4 08:59 mysql
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc6.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc5.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc4.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc3.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc2.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc1.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc0.d
-rw-r--r-- 1 root root            31764 Oct    4 08:59 ld.so.cache
141.95.160.133 | CHANGED | rc=0 >>
total 884
-rw-r--r-- 1 root root                887 Apr    1    2013 rpc
-rw-r--r-- 1 root root              2932 Apr    1    2013 protocols
-rw-r--r-- 1 root root                280 Jun 20    2014 fuse.conf
-rw-r--r-- 1 root root              3663 Jun 20    2016 screenrc
-rw-r--r-- 1 root root                604 Sep 15    2018 deluser.conf
-rw-r----- 1 root daemon            144 Nov 12    2018 at.deny
-rw-r--r-- 1 root root              1260 Dec 14    2018 ucf.conf
-rw-r--r-- 1 root root                533 Jan 21    2019 logrotate.conf
-rw-r--r-- 1 root root            14867 Feb    1    2019 ltrace.conf
-rw-r--r-- 1 root root              2969 Aug    3    2019 debconf.conf
-rw-r--r-- 1 root root              5060 Aug 21    2019 hdparm.conf
-rw-r--r-- 1 root root                642 Sep 24    2019 xattr.conf
-rw-r--r-- 1 root root            24546 Oct 18    2019 mime.types
-rw-r--r-- 1 root root                449 Oct 18    2019 mailcap.order
-rw-r--r-- 1 root root                581 Dec    5    2019 profile
-rw-r--r-- 1 root root                  91 Dec    5    2019 networks
-rw-r--r-- 1 root root                267 Dec    5    2019 legal
-rw-r--r-- 1 root root                  92 Dec    5    2019 host.conf
-rw-r--r-- 1 root root                  13 Dec    5    2019 debian_version
-rw-r--r-- 1 root root                552 Dec 17    2019 pam.conf
-rw-r--r-- 1 root root              1816 Dec 27    2019 ethertypes
-rw-r--r-- 1 root root                111 Jan 16    2020 magic.mime
-rw-r--r-- 1 root root                111 Jan 16    2020 magic
-rw-r--r-- 1 root root                  45 Jan 26    2020 bash_completion
-rw-r--r-- 1 root root              2584 Feb    1    2020 gai.conf
-r--r----- 1 root root                755 Feb    3    2020 sudoers
-rw-r--r-- 1 root root            10037 Feb    7    2020 nanorc
-rw-r--r-- 1 root root            10550 Feb    7    2020 login.defs
-rw-r--r-- 1 root root              1523 Feb 10    2020 usb_modeswitch.conf
-rw-r--r-- 1 root root              1382 Feb 11    2020 rsyslog.conf
-rw-r--r-- 1 root root              1042 Feb 13    2020 crontab
-rw-r--r-- 1 root root              2351 Feb 13    2020 sysctl.conf
-rw-r--r-- 1 root root                808 Feb 14    2020 mke2fs.conf
-rw-r--r-- 1 root root                685 Feb 14    2020 e2scrub.conf
-rw-r--r-- 1 root root            14464 Feb 16    2020 services
-rw-r--r-- 1 root root                191 Feb 18    2020 libaudit.conf
drwxr-xr-x 2 root root              4096 Feb 24    2020 usb_modeswitch.d
-rw-r--r-- 1 root root              1748 Feb 25    2020 inputrc
-rw-r--r-- 1 root root              2319 Feb 25    2020 bash.bashrc
-rw-r--r-- 1 root root              5215 Feb 25    2020 manpath.config
-rw-r--r-- 1 root root                  41 Apr    6    2020 multipath.conf
-rw-r--r-- 1 root root              2996 Apr 14    2020 locale.alias
-rw-r--r-- 1 root root                  34 Apr 14    2020 ld.so.conf
-rw-r--r-- 1 root root                367 Apr 14    2020 bindresvport.blacklist
drwxr-xr-x 2 root root              4096 Apr 22    2020 binfmt.d
-rw-r--r-- 1 root root              6920 Nov    2    2021 overlayroot.conf
-rw-r--r-- 1 root root              4942 Nov 12    2021 wgetrc
-rw-r--r-- 1 root root                477 Feb 10    2022 zsh_command_not_found
drwxrwxr-x 2 root landscape    4096 Feb 14    2022 landscape
lrwxrwxrwx 1 root root                  13 Mar 15    2022 rmt -> /usr/sbin/rmt
-rw-r--r-- 1 root root            10593 Mar 31    2022 sensors3.conf
drwxr-xr-x 2 root root              4096 Apr 25 14:02 update-notifier
drwxr-xr-x 2 root root              4096 Jul 24 21:38 opt
drwxr-xr-x 2 root root              4096 Jul 24 21:38 selinux
drwxr-xr-x 2 root root              4096 Jul 24 21:38 terminfo
-rw-r--r-- 1 root root              3028 Jul 24 21:38 adduser.conf
lrwxrwxrwx 1 root root                  39 Jul 24 21:38 resolv.conf ->
../run/systemd/resolve/st                                                           
ub-resolv.conf
lrwxrwxrwx 1 root root                  19 Jul 24 21:38 mtab -> ../proc/self/mounts
drwxr-xr-x 7 root root              4096 Jul 24 21:38 apt
drwxr-xr-x 3 root root              4096 Jul 24 21:38 ca-certificates
drwxr-xr-x 4 root root              4096 Jul 24 21:38 dbus-1
drwxr-xr-x 8 root root              4096 Jul 24 21:38 networkd-dispatcher
drwxr-xr-x 4 root root              4096 Jul 24 21:38 xdg
drwxr-xr-x 2 root root              4096 Jul 24 21:38 cron.hourly
drwxr-xr-x 2 root root              4096 Jul 24 21:38 cron.monthly
-rw-r--r-- 1 root root                510 Jul 24 21:38 nsswitch.conf
-rw-r--r-- 1 root root                195 Jul 24 21:38 modules
drwxr-xr-x 2 root root              4096 Jul 24 21:38 newt
drwxr-xr-x 4 root root              4096 Jul 24 21:38 iproute2
-rw-r--r-- 1 root root              5713 Jul 24 21:38 ca-certificates.conf.dpkg-old
drwxr-xr-x 2 root root              4096 Jul 24 21:38 python3
lrwxrwxrwx 1 root root                  23 Jul 24 21:38 vtrgb ->
/etc/alternatives/vtrgb
drwxr-xr-x 2 root root              4096 Jul 24 21:38 skel
drwxr-xr-x 4 root root              4096 Jul 24 21:39 dpkg
drwxr-xr-x 2 root root              4096 Jul 24 21:39 ld.so.conf.d
drwxr-xr-x 4 root root              4096 Jul 24 21:39 security
-rw-r--r-- 1 root root                106 Jul 24 21:39 environment
drwxr-xr-x 4 root root              4096 Jul 24 21:39 ssl
drwxr-xr-x 2 root root              4096 Jul 24 21:39 python3.8
drwxr-xr-x 4 root root              4096 Jul 24 21:39 dhcp
drwxr-xr-x 2 root root              4096 Jul 24 21:39 depmod.d
-rw-r--r-- 1 root root              6821 Jul 24 21:39 ca-certificates.conf
-rw-r--r-- 1 root root                110 Jul 24 21:39 kernel-img.conf
drwxr-xr-x 3 root root              4096 Jul 24 21:39 perl
drwxr-xr-x 3 root root              4096 Jul 24 21:39 gss
-rw-r--r-- 1 root root                  54 Jul 24 21:39 crypttab
drwxr-xr-x 5 root root              4096 Jul 24 21:39 kernel
drwxr-xr-x 3 root root              4096 Jul 24 21:39 dconf
drwxr-xr-x 4 root root              4096 Jul 24 21:39 network
drwxr-xr-x 4 root root              4096 Jul 24 21:39 pki
drwxr-xr-x 3 root root              4096 Jul 24 21:39 pm
drwxr-xr-x 3 root root              4096 Jul 24 21:39 libblockdev
drwxr-xr-x 4 root root              4096 Jul 24 21:39 polkit-1
drwxr-xr-x 3 root root              4096 Jul 24 21:39 ModemManager
drwxr-xr-x 3 root root              4096 Jul 24 21:39 NetworkManager
drwxr-xr-x 2 root root              4096 Jul 24 21:39 ldap
drwxr-xr-x 3 root root              4096 Jul 24 21:39 apparmor
-rw-r--r-- 1 root root                711 Jul 24 21:39 hosts.deny
-rw-r--r-- 1 root root                411 Jul 24 21:39 hosts.allow
drwxr-xr-x 2 root root              4096 Jul 24 21:39 calendar
drwxr-xr-x 2 root root              4096 Jul 24 21:39 modprobe.d
drwxr-xr-x 2 root root              4096 Jul 24 21:39 mdadm
drwxr-xr-x 2 root root              4096 Jul 24 21:39 byobu
drwxr-xr-x 2 root root              4096 Jul 24 21:39 tmpfiles.d
-rw-r--r-- 1 root root                146 Jul 24 21:39 shells
drwxr-xr-x 2 root root              4096 Jul 24 21:39 iscsi
drwxr-xr-x 2 root root              4096 Jul 24 21:40 groff
drwxr-xr-x 5 root root              4096 Jul 24 21:40 initramfs-tools
drwxr-xr-x 2 root root              4096 Jul 24 21:40 rsyslog.d
drwxr-xr-x 3 root root              4096 Jul 24 21:40 ufw
drwxr-xr-x 2 root root              4096 Jul 24 21:40 cryptsetup-initramfs
drwxr-xr-x 2 root root              4096 Jul 24 21:40 udisks2
drwxr-xr-x 3 root root              4096 Jul 24 21:40 apport
drwxr-xr-x 2 root root              4096 Jul 24 21:40 bash_completion.d
drwxr-xr-x 2 root root              4096 Jul 24 21:40 pollinate
drwxr-xr-x 3 root root              4096 Jul 24 21:40 fwupd
drwxr-xr-x 3 root root              4096 Jul 24 21:40 lvm
drwxr-xr-x 2 root root              4096 Jul 24 21:40 cron.weekly
drwxr-xr-x 2 root root              4096 Jul 24 21:40 PackageKit
-rw-r--r-- 1 root root                  33 Jul 24 21:40 ec2_version
drwxr-xr-x 2 root root              4096 Jul 24 21:40 console-setup
-rw-r--r-- 1 root root                    0 Jul 24 21:40 popularity-contest.conf
-rw-r--r-- 1 root root              9440 Jul 24 21:40 locale.gen
-rw-r--r-- 1 root root                112 Jul 24 21:40 overlayroot.local.conf
-rw-r--r-- 1 root root                  84 Jul 24 21:41 fstab
drwxr-xr-x 2 root root              4096 Jul 24 21:41 grub.d
drwxr-xr-x 2 root root              4096 Aug    1 05:31 netplan
drwxr-xr-x 3 root root              4096 Aug    1 05:32 qemu
drwxr-xr-x 4 root root              4096 Aug    1 05:32 cloud
-rw-r--r-- 1 root root                104 Aug 22 10:53 lsb-release
lrwxrwxrwx 1 root root                  21 Aug 22 10:54 os-release -> ../usr/lib/os-
release
-rw-r--r-- 1 root root                  19 Aug 22 10:54 issue.net
-rw-r--r-- 1 root root                  26 Aug 22 10:54 issue
drwx------ 2 root root              4096 Sep 14 10:23 multipath
-r--r--r-- 1 root root                  33 Sep 14 10:23 machine-id
-rw-r--r-- 1 root root                271 Sep 14 10:23 hosts
-rw-r--r-- 1 root root                    8 Sep 14 10:30 timezone
lrwxrwxrwx 1 root root                  27 Sep 14 10:30 localtime ->
/usr/share/zoneinfo/Etc/UTC
drwxr-xr-x 4 root root              4096 Sep 14 10:30 vmware-tools
drwxr-xr-x 4 root root              4096 Sep 14 13:28 ssh
drwxr-xr-x 2 root root              4096 Sep 20 06:33 vim
-rw-r--r-- 1 root root                  15 Sep 20 07:01 hostname
drwxr-xr-x 5 root root              4096 Sep 20 07:02 vulkan
drwxr-xr-x 7 root root              4096 Sep 20 07:02 X11
drwxr-xr-x 2 root root              4096 Sep 20 07:02 rcS.d
drwxr-xr-x 2 root root              4096 Sep 20 07:02 sensors.d
drwxr-xr-x 4 root root              4096 Sep 20 07:02 fonts
drwxr-xr-x 2 root root              4096 Sep 20 07:02 environment.d
drwxr-xr-x 5 root root              4096 Sep 20 07:02 java-11-openjdk
-rw-r--r-- 1 root root              3891 Sep 20 07:02 mailcap
drwxr-xr-x 2 root root              4096 Sep 24 19:46 process-exporter
drwxr-xr-x 2 root root              4096 Sep 25 11:29 wildfly
drwxr-xr-x 6 root root              4096 Sep 27 06:06 sos
drwxr-x--- 2 root root              4096 Oct    3 08:58 sudoers.d
drwxr-xr-x 8 root root              4096 Oct    3 12:32 nginx
drwxr-xr-x 8 root root              4096 Oct    3 15:25 apache2
drwxr-xr-x 2 root root              4096 Oct    3 15:25 cron.daily
-rw-r--r-- 1 root root                  98 Oct    4 07:58 subuid-
-rw-r--r-- 1 root root                  98 Oct    4 07:58 subgid-
drwxr-xr-x 2 root root              4096 Oct    4 08:24 profile.d
drwxr-xr-x 2 root root              4096 Oct    4 08:24 sysctl.d
drwxr-xr-x 2 root root              4096 Oct    4 08:24 modules-load.d
drwxr-xr-x 4 root root              4096 Oct    4 08:24 udev
drwxr-xr-x 3 root root              4096 Oct    4 08:24 update-manager
drwxr-xr-x 2 root root              4096 Oct    4 08:24 ubuntu-advantage
drwxr-xr-x 2 root root              4096 Oct    4 08:24 update-motd.d
drwxr-xr-x 5 root root              4096 Oct    4 08:24 systemd
drwxr-xr-x 2 root root              4096 Oct    4 08:24 pam.d
-rw-r----- 1 root shadow            875 Oct    4 08:45 gshadow-
-rw-r--r-- 1 root root              1048 Oct    4 08:45 group-
-rw-r--r-- 1 root root                123 Oct    4 08:45 subuid
-rw-r--r-- 1 root root                123 Oct    4 08:45 subgid
-rw-r----- 1 root shadow          1560 Oct    4 08:59 shadow-
-rw-r--r-- 1 root root              2130 Oct    4 08:59 passwd-
-rw-r--r-- 1 root root              1061 Oct    4 08:59 group
-rw-r----- 1 root shadow            885 Oct    4 08:59 gshadow
-rw-r----- 1 root shadow          1560 Oct    4 08:59 shadow
-rw-r--r-- 1 root root              2145 Oct    4 08:59 passwd
drwxr-xr-x 6 root root              4096 Oct    4 08:59 logcheck
drwxr-xr-x 3 root root              4096 Oct    4 08:59 php
drwxr-xr-x 2 root root              4096 Oct    4 08:59 cron.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 alternatives
drwxr-xr-x 7 root root              4096 Oct    4 08:59 apparmor.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 insserv.conf.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 init.d
drwxr-xr-x 3 root root              4096 Oct    4 08:59 default
drwxr-xr-x 2 root root              4096 Oct    4 08:59 logrotate.d
drwxr-xr-x 4 root root              4096 Oct    4 08:59 mysql
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc6.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc5.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc4.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc3.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc2.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc1.d
drwxr-xr-x 2 root root              4096 Oct    4 08:59 rc0.d
-rw-r--r-- 1 root root            31764 Oct    4 08:59 ld.so.cache
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp"
146.59.158.16 | CHANGED | rc=0 >>
total 48
drwx------ 3 root          root          4096 Aug 26 08:20 systemd-private-
588107954b074b39980b7c                                                               
ddbcfcdf42-systemd-logind.service-68Kuej
drwx------ 3 root          root          4096 Aug 26 08:20 systemd-private-
588107954b074b39980b7c                                                               
ddbcfcdf42-ModemManager.service-cIU2Ef
drwx------ 3 root          root          4096 Aug 26 08:20 snap.lxd
drwx------ 3 root          root          4096 Aug 31 21:07 snap.tree
drwxr-xr-x 2 root          root          4096 Sep 21 10:05 hsperfdata_root
drwxr-xr-x 2 wildfly    wildfly    4096 Sep 25 13:32 hsperfdata_wildfly
drwxr-xr-x 2 apx03        apx03        4096 Sep 26 09:17 hsperfdata_apx03
drwx------ 3 root          root          4096 Oct    2 17:36 systemd-private-
588107954b074b39980b7c                                                               
ddbcfcdf42-systemd-resolved.service-xYNRni
drwx------ 3 root          root          4096 Oct    2 17:36 systemd-private-
588107954b074b39980b7c                                                               
ddbcfcdf42-systemd-timesyncd.service-fMKZlf
-rwxrwxrwx 1 ansadmin ansadmin        0 Oct    3 10:15 cible1.txt
-rw-r--r-- 1 ansadmin ansadmin        0 Oct    4 08:16 test.txt
drwxr-xr-x 2 ansadmin ansadmin 4096 Oct    4 08:20 dir
drwxr-xr-x 2 root          root          4096 Oct    4 09:43 Debian
drwx------ 2 root          root          4096 Oct    4 09:45
ansible_command_payload_eh82ie9y
141.95.160.133 | CHANGED | rc=0 >>
total 44
drwx------ 3 root          root          4096 Sep 14 10:23 systemd-private-
0c62a6f1854e46959ec934                                                               
668ec6cc97-systemd-logind.service-pnYtUi
drwx------ 3 root          root          4096 Sep 14 10:23 systemd-private-
0c62a6f1854e46959ec934                                                               
668ec6cc97-ModemManager.service-1Rmclg
drwx------ 3 root          root          4096 Sep 14 10:23 snap.lxd
drwxr-xr-x 2 root          root          4096 Sep 21 09:23 hsperfdata_root
drwxr-xr-x 2 etl03        etl03        4096 Sep 21 10:24 hsperfdata_etl03
drwxr-xr-x 2 wildfly    wildfly    4096 Sep 25 15:04 hsperfdata_wildfly
-rw-r--r-- 1 ansadmin ansadmin        0 Oct    4 08:16 test.txt
drwxr-xr-x 2 ansadmin ansadmin 4096 Oct    4 08:20 dir
drwx------ 3 root          root          4096 Oct    4 08:24 systemd-private-
0c62a6f1854e46959ec934                                                               
668ec6cc97-systemd-resolved.service-dSPAvh
drwx------ 3 root          root          4096 Oct    4 08:24 systemd-private-
0c62a6f1854e46959ec934                                                               
668ec6cc97-systemd-timesyncd.service-XoIIlf
drwxr-xr-x 2 root          root          4096 Oct    4 09:43 Debian
drwx------ 2 root          root          4096 Oct    4 09:45
ansible_command_payload_rz12wo4b
ansadmin@svl200:~$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
──

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Tue Oct    4 08:53:18 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /etc | grep Deb"
146.59.158.16 | FAILED | rc=1 >>
non-zero return code
141.95.160.133 | FAILED | rc=1 >>
non-zero return code
ansadmin@svl200:~$ ansible-playbook rep.yaml

PLAY [Creation de repertoire]


*********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation]
***********************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation]
***********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=                                                             
1        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=                                                             
1        rescued=0        ignored=0

ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /etc | grep Deb"
146.59.158.16 | FAILED | rc=1 >>
non-zero return code
141.95.160.133 | FAILED | rc=1 >>
non-zero return code
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /etc | grep redhat"
146.59.158.16 | FAILED | rc=1 >>
non-zero return code
141.95.160.133 | FAILED | rc=1 >>
non-zero return code
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook rep.yaml

PLAY [Creation de repertoire]


*********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation]
***********************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation]
***********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=                                                             
1        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=                                                             
1        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim rep.yaml
ansadmin@svl200:~$ ansible-playbook rep.yaml

PLAY [Creation de repertoire]


*********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation repertoire]


************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation repertoire]


************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Creation fichier]


***************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [Creation fichier]


***************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=3        changed=1        unreachable=0 
failed=0        skipped=                                                             
2        rescued=0        ignored=0
146.59.158.16                            : ok=3        changed=1        unreachable=0
failed=0        skipped=                                                             
2        rescued=0        ignored=0

ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/redhat | grep redhat"
146.59.158.16 | FAILED | rc=1 >>
ls: cannot access '/tmp/redhat': No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=1 >>
ls: cannot access '/tmp/redhat': No such file or directorynon-zero return code
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/redhat"
146.59.158.16 | FAILED | rc=2 >>
ls: cannot access '/tmp/redhat': No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=2 >>
ls: cannot access '/tmp/redhat': No such file or directorynon-zero return code
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/Redhat"
146.59.158.16 | FAILED | rc=2 >>
ls: cannot access '/tmp/Redhat': No such file or directorynon-zero return code
141.95.160.133 | FAILED | rc=2 >>
ls: cannot access '/tmp/Redhat': No such file or directorynon-zero return code
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/Debian"
146.59.158.16 | CHANGED | rc=0 >>
total 0
-rw-r--r-- 1 root root 0 Oct    4 09:57 Debian.txt
141.95.160.133 | CHANGED | rc=0 >>
total 0
-rw-r--r-- 1 root root 0 Oct    4 09:57 Debian.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp/Debian"
146.59.158.16 | CHANGED | rc=0 >>
total 0
-rw-r--r-- 1 root root 0 Oct    4 09:57 Debian.txt
141.95.160.133 | CHANGED | rc=0 >>
total 0
-rw-r--r-- 1 root root 0 Oct    4 09:57 Debian.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook list.yaml

PLAY [exemple ansible list]


***********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install package]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim list.yaml
ansadmin@svl200:~$ sudo vim list.yaml
ansadmin@svl200:~$ ansible-playbook list.yaml

PLAY [exemple ansible list]


***********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install package]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ ansible-playbook items.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


*************************************************
changed: [146.59.158.16] => (item=init1.txt)
changed: [141.95.160.133] => (item=init1.txt)
changed: [146.59.158.16] => (item=init2.txt)
changed: [141.95.160.133] => (item=init2.txt)
changed: [146.59.158.16] => (item=init3.txt)
changed: [141.95.160.133] => (item=init3.txt)
changed: [146.59.158.16] => (item=init4.txt)
changed: [141.95.160.133] => (item=init4.txt)
PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ ansible-playbook items.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


*************************************************
changed: [146.59.158.16] => (item=init1.txt)
changed: [141.95.160.133] => (item=init1.txt)
changed: [146.59.158.16] => (item=init2.txt)
changed: [141.95.160.133] => (item=init2.txt)
changed: [146.59.158.16] => (item=init3.txt)
changed: [141.95.160.133] => (item=init3.txt)
changed: [146.59.158.16] => (item=init4.txt)
changed: [141.95.160.133] => (item=init4.txt)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin"
146.59.158.16 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            18 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init4.txt
141.95.160.133 | CHANGED | rc=0 >>
total 16
-rw-rw-r-- 1 ansadmin ansadmin 598 Oct    3 13:02 resultat.txt
-rw-r--r-- 1 root          root            56 Oct    3 14:02 Debian.txt
-rw-r--r-- 1 root          root            35 Oct    3 14:41 var.txt
-rw-r--r-- 1 root          root            19 Oct    3 14:46 ip.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    3 20:36 Devops27.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init4.txt
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | grep init"
146.59.158.16 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init4.txt
141.95.160.133 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init1.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:19 init2.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init3.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 10:20 init4.txt
ansadmin@svl200:~$ sudo vim items_users.yaml
ansadmin@svl200:~$ sudo -f items_users.yaml
sudo: invalid option -- 'f'
usage: sudo -h | -K | -k | -V
usage: sudo -v [-AknS] [-g group] [-h host] [-p prompt] [-u user]
usage: sudo -l [-AknS] [-g group] [-h host] [-p prompt] [-U user] [-u user] [command]
usage: sudo [-AbEHknPS] [-r role] [-t type] [-C num] [-g group] [-h host] [-p prompt]
                        [-T timeout] [-u user] [VAR=value] [-i|-s] [<command>]
usage: sudo -e [-AknS] [-r role] [-t type] [-C num] [-g group] [-h host] [-p prompt]
                        [-T timeout] [-u user] file ...
ansadmin@svl200:~$
ansadmin@svl200:~$ rm items_users.yaml
rm: remove write-protected regular empty file 'items_users.yaml'?
ansadmin@svl200:~$
ansadmin@svl200:~$ cp items.yaml item_users.yaml
ansadmin@svl200:~$ sudo vim items_users.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo3.yaml      handler.yaml          items.yaml               
rep.yaml              when.yaml
debug.yaml      exo4.yaml      index.html              items_users.yaml    seq.yaml 
when1.yaml
debug1.yaml    fact.yaml      ip.txt                      list.yaml                 
shell.yml
exo2.yaml        fact1.yaml    item_users.yaml    nginx.yaml               
template.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo3.yaml      handler.yaml          items.yaml               
rep.yaml              when.yaml
debug.yaml      exo4.yaml      index.html              items_users.yaml    seq.yaml 
when1.yaml
debug1.yaml    fact.yaml      ip.txt                      list.yaml                 
shell.yml
exo2.yaml        fact1.yaml    item_users.yaml    nginx.yaml               
template.yaml
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefin                                                                             
ed variable. The error was: 'user' is undefined\n\nThe error appears to be in
'/home/an                                                                           
sadmin/item_users.yaml': line 7, column 5, but may\nbe elsewhere in the file
depending                                                                           
on the exact syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n   
- name                                                                               
: creation d'utilisateurs\n        ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefi                                                                               
ned variable. The error was: 'user' is undefined\n\nThe error appears to be in
'/home/a                                                                             
nsadmin/item_users.yaml': line 7, column 5, but may\nbe elsewhere in the file
depending                                                                           
on the exact syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n   
- nam                                                                               
e: creation d'utilisateurs\n        ^ here\n"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
failed: [146.59.158.16] (item=user1.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user1.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user1.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user1.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}
failed: [146.59.158.16] (item=user2.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user2.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user2.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user2.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}
failed: [146.59.158.16] (item=user3.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user3.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user3.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user3.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}
failed: [146.59.158.16] (item=user4.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user4.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user4.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user4.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}^L
failed: [146.59.158.16] (item=user5.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user5.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user5.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user5.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim items.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************
TASK [Gathering Facts]
****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
failed: [146.59.158.16] (item=user1.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user1.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user1.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user1.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}
failed: [146.59.158.16] (item=user2.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user2.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user2.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user2.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}
failed: [146.59.158.16] (item=user3.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user3.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user3.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user3.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}
failed: [146.59.158.16] (item=user4.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user4.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user4.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user4.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}
failed: [146.59.158.16] (item=user5.txt) => {"ansible_loop_var": "item", "changed":
fal                                                                                 
se, "item": "user5.txt", "msg": "Unsupported parameters for (user) module: path
Support                                                                             
ed parameters include: append, authorization, comment, create_home, expires, force,
gen                                                                                 
erate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_un                                                                               
ique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key_                                                                             
bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state, system,
u                                                                                   
id, update_password"}
failed: [141.95.160.133] (item=user5.txt) => {"ansible_loop_var": "item", "changed":
fa                                                                                   
lse, "item": "user5.txt", "msg": "Unsupported parameters for (user) module: path
Suppor                                                                               
ted parameters include: append, authorization, comment, create_home, expires, force,
ge                                                                                   
nerate_ssh_key, group, groups, hidden, home, local, login_class, move_home, name,
non_u                                                                               
nique, password, password_lock, profile, remove, role, seuser, shell, skeleton,
ssh_key                                                                             
_bits, ssh_key_comment, ssh_key_file, ssh_key_passphrase, ssh_key_type, state,
system,                                                                             
uid, update_password"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
changed: [146.59.158.16] => (item=user1.txt)
changed: [141.95.160.133] => (item=user1.txt)
ok: [146.59.158.16] => (item=user2.txt)
ok: [141.95.160.133] => (item=user2.txt)
ok: [146.59.158.16] => (item=user3.txt)
ok: [141.95.160.133] => (item=user3.txt)
ok: [146.59.158.16] => (item=user4.txt)
ok: [141.95.160.133] => (item=user4.txt)
ok: [146.59.158.16] => (item=user5.txt)
ok: [141.95.160.133] => (item=user5.txt)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim item_users.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook item_users.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation d'utilisateurs]


********************************************************
ok: [146.59.158.16] => (item=user1.txt)
ok: [141.95.160.133] => (item=user1.txt)
ok: [146.59.158.16] => (item=user2.txt)
ok: [141.95.160.133] => (item=user2.txt)
ok: [146.59.158.16] => (item=user3.txt)
ok: [141.95.160.133] => (item=user3.txt)
ok: [146.59.158.16] => (item=user4.txt)
ok: [141.95.160.133] => (item=user4.txt)
ok: [146.59.158.16] => (item=user5.txt)
ok: [141.95.160.133] => (item=user5.txt)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
Network error: Software caused connection abort
─────────────────────────────────────────────────────────────────────────────────────
────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

    System information as of Tue Oct    4 12:03:00 UTC 2022

    System load:                      0.91


    Usage of /:                        13.7% of 38.58GB
    Memory usage:                    48%
    Swap usage:                        0%
    Processes:                          139
    Users logged in:              1
    IPv4 address for ens3: 146.59.156.114
    IPv6 address for ens3: 2001:41d0:304:200::9356

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

9 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Tue Oct    4 09:46:14 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$ ansible-playbook seq.yaml

PLAY [exemple avec items]


*************************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [creation de liste des fichiers]


*************************************************
changed: [146.59.158.16] => (item=20)
changed: [141.95.160.133] => (item=20)
changed: [146.59.158.16] => (item=21)
changed: [141.95.160.133] => (item=21)
changed: [146.59.158.16] => (item=22)
changed: [141.95.160.133] => (item=22)
changed: [146.59.158.16] => (item=23)
changed: [141.95.160.133] => (item=23)
changed: [146.59.158.16] => (item=24)
changed: [141.95.160.133] => (item=24)
changed: [146.59.158.16] => (item=25)
changed: [141.95.160.133] => (item=25)
changed: [146.59.158.16] => (item=26)
changed: [141.95.160.133] => (item=26)
changed: [146.59.158.16] => (item=27)
changed: [141.95.160.133] => (item=27)

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim rep.yaml


ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /tmp"
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | Dev"
146.59.158.16 | FAILED | rc=127 >>
/bin/sh: 1: Dev: not foundnon-zero return code
141.95.160.133 | FAILED | rc=127 >>
/bin/sh: 1: Dev: not foundnon-zero return code
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible all -bm shell -a "ls -lrt /home/ansadmin | grep Dev"
^[[C146.59.158.16 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops27.txt
141.95.160.133 | CHANGED | rc=0 >>
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops20.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops21.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops22.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops23.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops24.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops25.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops26.txt
-rwxrwxr-x 1 ansadmin ansadmin      0 Oct    4 12:05 Devops27.txt
ansadmin@svl200:~$ sudo vim seq.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim copie.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo2.yaml    fact1.yaml        item_users.yaml      nginx.yaml   
template.yaml
copie.yaml      exo3.yaml    handler.yaml    items.yaml                rep.yaml     
when.yaml
debug.yaml      exo4.yaml    index.html        items_users.yaml    seq.yaml       
when1.yaml
debug1.yaml    fact.yaml    ip.txt                list.yaml                 
shell.yml
ansadmin@svl200:~$ sudo vim copie.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo2.yaml    fact1.yaml        item_users.yaml      nginx.yaml   
template.yaml
copie.yaml      exo3.yaml    handler.yaml    items.yaml                rep.yaml     
when.yaml
debug.yaml      exo4.yaml    index.html        items_users.yaml    seq.yaml       
when1.yaml
debug1.yaml    fact.yaml    ip.txt                list.yaml                 
shell.yml
ansadmin@svl200:~$ sudo vim copie.yaml
ansadmin@svl200:~$ sudo vim copie.yaml
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************
TASK [Gathering Facts]
****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Could not find or
access                                                                               
'index.html.j2'\nSearched
in:\n\t/home/ansadmin/templates/index.html.j2\n\t/home/ansadm                       
in/index.html.j2\n\t/home/ansadmin/templates/index.html.j2\n\t/home/ansadmin/
index.html                                                                           
.j2 on the Ansible Controller.\nIf you are using a module and expect the file to
exist                                                                               
on the remote, see the remote_src option"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Could not find or
access                                                                               
'index.html.j2'\nSearched
in:\n\t/home/ansadmin/templates/index.html.j2\n\t/home/ansad                         
min/index.html.j2\n\t/home/ansadmin/templates/index.html.j2\n\t/home/ansadmin/
index.htm                                                                           
l.j2 on the Ansible Controller.\nIf you are using a module and expect the file to
exist                                                                               
on the remote, see the remote_src option"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ 146.59.158.16^C
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [141.95.160.133]
ok: [146.59.158.16]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable:                                                           
'ansible_all_ipv4_adresses' is undefined"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable                                                           
: 'ansible_all_ipv4_adresses' is undefined"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim index.html.j2


ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable:                                                           
'ansible_all_ipv4_adresses' is undefined"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable                                                           
: 'ansible_all_ipv4_adresses' is undefined"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim index.html.j2


ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]
PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=2        changed=1        unreachable=0 
failed=0        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=1        unreachable=0
failed=0        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ cp index.html.j2 index.html1.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [ajout index.html file]


**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable:                                                           
'ansible_user' is undefined"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable                                                           
: 'ansible_user' is undefined"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ ansible-playbook template.yaml

PLAY [exemple avec template]


**********************************************************

TASK [Gathering Facts]


****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [ajout index.html file]
**********************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable:                                                           
'ansible_ssh_user' is undefined"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg":
"AnsibleUndefinedVariable                                                           
: 'ansible_ssh_user' is undefined"}

PLAY RECAP
****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=                                                             
0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=                                                             
0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ sudo vim index.html.j2
ansadmin@svl200:~$ sudo vim index.html1.j2
ansadmin@svl200:~$ cp template.yaml template1.yaml
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: user, template

The error appears to be in '/home/ansadmin/template1.yaml': line 10, column 7, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - user:
            ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ls
cible1.txt      exo4.yaml            index.html1.j2        nginx.yaml           
when.yaml
copie.yaml      fact.yaml            ip.txt                        rep.yaml         
when1.yaml
debug.yaml      fact1.yaml          item_users.yaml      seq.yaml
debug1.yaml    handler.yaml      items.yaml                shell.yml
exo2.yaml        index.html          items_users.yaml    template.yaml
exo3.yaml        index.html.j2    list.yaml                  template1.yaml
ansadmin@svl200:~$ sudo vim exo4.yaml
ansadmin@svl200:~$ sudo vim exo3.yaml
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: user, template
The error appears to be in '/home/ansadmin/template1.yaml': line 7, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: user, template

The error appears to be in '/home/ansadmin/template1.yaml': line 9, column 7, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: template, src

The error appears to be in '/home/ansadmin/template1.yaml': line 10, column 7, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: template, src

The error appears to be in '/home/ansadmin/template1.yaml': line 10, column 7, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ sudo vim template.yaml
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! conflicting action statements: template, src
The error appears to be in '/home/ansadmin/template1.yaml': line 10, column 7, but
may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
        - name: creer user
            ^ here
ansadmin@svl200:~$ w
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-playbook template1.yaml
ERROR! A malformed block was encountered while loading tasks: {'template': None,
'src':                                                                               
'index.html1', 'dest': '/var/www/html/index.html1'} should be a list or None but is
<c                                                                                   
lass 'ansible.parsing.yaml.objects.AnsibleMapping'>

The error appears to be in '/home/ansadmin/template1.yaml': line 2, column 3, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: exemple avec template
    ^ here
ansadmin@svl200:~$ wq
wq: command not found
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim template1.yaml
ansadmin@svl200:~$ ansible-vault create hello.yml
New Vault password:    [ERROR]: User interrupted execution
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-vault create hello.yaml
New Vault password:
Confirm New Vault password:
ansadmin@svl200:~$ cp
.ansible/                    cible1.txt                  handler.yaml             
list.yaml
.bash_history            copie.yaml                  hello.yaml                 
nginx.yaml
.bash_logout              debug.yaml                  index.html                 
rep.yaml
.bashrc                        debug1.yaml                index.html.j2           
seq.yaml
.exo4.yaml.swp          exo2.yaml                    index.html1.j2         
shell.yml
.handler.yaml.swp    exo3.yaml                    ip.txt                         
template.yaml
.profile                      exo4.yaml                    item_users.yaml       
template1.yaml
.ssh/                            fact.yaml                    items.yaml             
when.yaml
.viminfo                      fact1.yaml                  items_users.yaml     
when1.yaml
ansadmin@svl200:~$ cat template1.yaml >> hello.yaml
ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$ ansible-playbook hello.yaml
ERROR! Syntax Error while loading YAML.
    found unexpected end of stream

The error appears to be in '/home/ansadmin/hello.yaml': line 15, column 1, but may


be elsewhere in the file depending on the exact syntax problem.

(specified line no longer in file, maybe it changed?)


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook hello.yaml --ask-vault-pass
Vault password:
ERROR! Syntax Error while loading YAML.
    found unexpected end of stream

The error appears to be in '/home/ansadmin/hello.yaml': line 15, column 1, but may


be elsewhere in the file depending on the exact syntax problem.

(specified line no longer in file, maybe it changed?)


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-vault edit
Vault password:
ansadmin@svl200:~$ ansible-vault create hello.yml
New Vault password:
Confirm New Vault password:
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$ ansible-playbook hello.yaml --ask-vault-pass
Vault password:
ERROR! Syntax Error while loading YAML.
    found unexpected end of stream

The error appears to be in '/home/ansadmin/hello.yaml': line 15, column 1, but may


be elsewhere in the file depending on the exact syntax problem.

(specified line no longer in file, maybe it changed?)


ansadmin@svl200:~$ sudo vim hello.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook hello.yaml --ask-vault-pass
Vault password:
[WARNING]: Found variable using reserved name: port

PLAY [play with vault]


*********************************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [echo variable]


***********************************************************************
ok: [146.59.158.16] => {
        "msg": "L'utilisateur ofi03 utilise le port 80 sur la machine master-wildfly"
}
ok: [141.95.160.133] => {
        "msg": "L'utilisateur ofi03 utilise le port 80 sur la machine slave1-wildfly"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
gnored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
gnored=0

ansadmin@svl200:~$ sudo vim hello.yaml


ansadmin@svl200:~$ ansible-vault encrypt when2.yaml
New Vault password:
Confirm New Vault password:
ERROR! Unable to read source file (/home/ansadmin/when2.yaml): [Errno 2] No such file
or dir                                                                               
/ansadmin/when2.yaml'
ansadmin@svl200:~$ ansible-vault encrypt hello.yaml
New Vault password:
Confirm New Vault password:
Encryption successful
ansadmin@svl200:~$
ansadmin@svl200:~$ cat hello.y
hello.yaml    hello.yml
ansadmin@svl200:~$ cat hello.yaml
$ANSIBLE_VAULT;1.1;AES256
36393466663530663832326138373032333162303465386232666666643638646130303137366137
6137666236326535653833333234373237343936613331340a383331316661363235323737336239
35313137363135336663326139383730336265613532353038303633346337313964643666346538
6363333135363636350a623231333466643832636463383635663564623636633931353861373938
31663065653239396361386539323035663065656332383738303733313365376234376532363235
64393030303066363362626234626334623062306632626231353965333361373036633463363432
62653336663163336666616566653065656236613736663736393530316263636638633130396264
35333465623035633165366131386230363137366537386534646334373537376563343662323134
37643633303237616466383633363338383831386136666231363332323334613061366230326430
31313661616266373233653461613237633934306363316664313365333937626163623764333039
63646336383939313362303630333863373630626361333135623137323463333431663366396565
34353865393865363737316233363131393432333363306365613037653736343433646561613937
64393663353432363736646535386263666266376231376532356430363761636266663332346530
65633634653730396639393933386434326130313165663437373939633132393031373661653530
33616464633335643666616465633964336461613436303231643636333035656366333931636365
31353261376431613431323563333137633165613033343937353162393161353433396137633232
3239
ansadmin@svl200:~$ ansible-vault decrypt hello.yaml
Vault password:
Decryption successful
ansadmin@svl200:~$ cat hello.yaml
---
- name: play with vault
    hosts: all
    become: true

    vars:
          - user: ofi03
          - port: 80

    tasks:
          - name: echo variable
              debug:
                  msg: "L'utilisateur {{user}} utilise le port {{port}} sur la
machine {{ansible_host

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim play-vars.yaml
ansadmin@svl200:~$ ansible-playbook play-vars.yaml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


****************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [141.95.160.133]
ok: [146.59.158.16]

TASK [Affichage nom distribution et version]


***********************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "template error while templating string:
expected                                                                             
int statement', got 'distribution'. String: Le nom de la distribution est {{ansible
distribu                                                                             
ion est {{ansible_version}}"}
fatal: [141.95.160.133]: FAILED! => {"msg": "template error while templating string:
expecte                                                                             
rint statement', got 'distribution'. String: Le nom de la distribution est {{ansible
distrib                                                                             
sion est {{ansible_version}}"}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
red=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
red=0

ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-vault create play-vars.yml
New Vault password:
Confirm New Vault password:
ansadmin@svl200:~$ cat play-vars.yaml >> play-vars.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim play-vars.yml
ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


****************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


***********************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "template error while templating string:
expected                                                                             
int statement', got 'distribution'. String: Le nom de la distribution est {{ansible
distribu                                                                             
ion est {{ansible_version}}"}
fatal: [141.95.160.133]: FAILED! => {"msg": "template error while templating string:
expecte                                                                             
rint statement', got 'distribution'. String: Le nom de la distribution est {{ansible
distrib                                                                             
sion est {{ansible_version}}"}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
red=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
red=0

ansadmin@svl200:~$ sudo vim play-vars.yml


ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


****************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


***********************************************
ok: [146.59.158.16] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full                                                                       
r': 2, 'minor': 9, 'revision': 6}"
}
ok: [141.95.160.133] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full                                                                       
r': 2, 'minor': 9, 'revision': 6}"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
red=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
red=0

ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


****************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


***********************************************
ok: [146.59.158.16] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full                                                                       
r': 2, 'minor': 9, 'revision': 6}"
}
ok: [141.95.160.133] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full                                                                       
r': 2, 'minor': 9, 'revision': 6}"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
red=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
red=0

ansadmin@svl200:~$ sudo vim play-vars.yml


ansadmin@svl200:~$ ansible ansiblecli -m setup | grep "version"
[WARNING]: Could not match supplied host pattern, ignoring: ansiblecli
[WARNING]: No hosts matched, nothing to do
ansadmin@svl200:~$ ansible ansiblecli -m setup | grep "version"
[WARNING]: Could not match supplied host pattern, ignoring: ansiblecli
[WARNING]: No hosts matched, nothing to do
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


****************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


***********************************************
ok: [146.59.158.16] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full                                                                       
r': 2, 'minor': 9, 'revision': 6}"
}
ok: [141.95.160.133] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est {'string':
'2.9.6', 'full                                                                       
r': 2, 'minor': 9, 'revision': 6}"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
red=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
red=0

ansadmin@svl200:~$ sudo vim play-vars.yml


ansadmin@svl200:~$ sudo vim play-vars.yml
ansadmin@svl200:~$ ansible-playbook play-vars.yml --ask-vault-pass
Vault password:

PLAY [Affichage d'une variable globale]


****************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [Affichage nom distribution et version]


***********************************************
ok: [146.59.158.16] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est 20"
}
ok: [141.95.160.133] => {
        "msg": "Le nom de la distribution est Ubuntu et la version est 20"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
red=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
red=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim locale.yml
ansadmin@svl200:~$ cat play-vars.yml >> locale.yml
-bash: locale.yml: Permission denied
ansadmin@svl200:~$ sudo cat play-vars.yml >> locale.yml
-bash: locale.yml: Permission denied
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim play-vars.yml
ansadmin@svl200:~$ sudo vim locale.yml
ansadmin@svl200:~$ ansible-playbook locale.yml
ERROR! Syntax Error while loading YAML.
    found unacceptable key (unhashable type: 'AnsibleMapping')

The error appears to be in '/home/ansadmin/locale.yml': line 12, column 15, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

            debug:
                msg: {{port_http}}
                            ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim locale.yml
ansadmin@svl200:~$ ansible-playbook locale.yml

PLAY [Affichage d'une variable locale]


*****************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [var locale port]


*********************************************************************
ok: [146.59.158.16] => {
        "msg": 8080
}
ok: [141.95.160.133] => {
        "msg": 8080
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
red=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
red=0

ansadmin@svl200:~$ sudo vim locale.yml


ansadmin@svl200:~$ sudo vim play-vars.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic.yml
ansadmin@svl200:~$ ansible-playbook var_dic.yml
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/var_dic.yml': line 13, column 32, but m   


ay
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                        debug:
                            msg: "{{service["name"]    {{service.rpm}}"
                                                              ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic.yml
ansadmin@svl200:~$ ansible-playbook var_dic.yml

PLAY [variable locale de type dictionnaire] **************************************

TASK [Gathering Facts] ***********************************************************


ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [var dict] ******************************************************************


ok: [146.59.158.16] => {
        "msg": "apache et httpd"
}
ok: [141.95.160.133] => {
        "msg": "apache et httpd"
}

PLAY RECAP ***********************************************************************


141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        ski                                                                 
pped=0        rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        ski                                                                 
pped=0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ cp var_dic.yml var_dic1.yml
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14, found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14, found a duplicate dict key (rpm). Using last defined value only.

PLAY [variable locale de type dictionnaire] **************************************

TASK [Gathering Facts] ***********************************************************


ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [var dict] ******************************************************************


fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an un   
defined variable. The error was: 'None' has no attribute 'name'\n\nThe error appea   
rs to be in '/home/ansadmin/var_dic1.yml': line 15, column 13, but may\nbe elsewhe   
re in the file depending on the exact syntax problem.\n\nThe offending line appear   
s to be:\n\n    tasks:\n                    - name: var dict\n                       
^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an u   
ndefined variable. The error was: 'None' has no attribute 'name'\n\nThe error appe   
ars to be in '/home/ansadmin/var_dic1.yml': line 15, column 13, but may\nbe elsewh   
ere in the file depending on the exact syntax problem.\n\nThe offending line appea   
rs to be:\n\n    tasks:\n                    - name: var dict\n                     
^ here\n"}

PLAY RECAP ***********************************************************************


141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        ski                                                                 
pped=0        rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        ski                                                                 
pped=0        rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    found unexpected end of stream

The error appears to be in '/home/ansadmin/var_dic1.yml': line 20, column 1, but m   


ay
be elsewhere in the file depending on the exact syntax problem.

(specified line no longer in file, maybe it changed?)


ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14, found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14, found a duplicate dict key (rpm). Using last defined value only.

PLAY [variable locale de type dictionnaire]


********************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [var dict]


************************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "template error while templating string:
unex                                                                                 
pected '}'. String: {{service[type]['name']}} et {{service[type]['rpm']}"}
fatal: [141.95.160.133]: FAILED! => {"msg": "template error while templating string:
une                                                                                 
xpected '}'. String: {{service[type]['name']}} et {{service[type]['rpm']}"}

PLAY RECAP
*****************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14,
found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column 14,
found a duplicate dict key (rpm). Using last defined value only.
ERROR! conflicting action statements: debug, msg

The error appears to be in '/home/ansadmin/var_dic1.yml': line 15, column 9, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


    tasks:
            - name: var dict
                ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column
14, found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic1.yml, line 8,
column
14, found a duplicate dict key (rpm). Using last defined value only.
ERROR! conflicting action statements: debug, msg

The error appears to be in '/home/ansadmin/var_dic1.yml': line 15, column 5, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
    - name: var dict
        ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/var_dic1.yml': line 13, column 14, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  name: mariadb
                    rpm: mariadb-server
                          ^ here
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/var_dic1.yml': line 13, column 14, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  name: mariadb
                    rpm: mariadb-server
                          ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context
The error appears to be in '/home/ansadmin/var_dic1.yml': line 13, column 14, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  name: mariadb
                    rpm: mariadb-server
                          ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/var_dic1.yml': line 13, column 14, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  name: mariadb
                    rpm: mariadb-server
                          ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service apache    httpd"
}
ok: [141.95.160.133] => {
        "msg": "Le service apache    httpd"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic1.yml


ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml
PLAY [variable locale de type dictionnaire]
************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service apache era installé par le paquethttpd"
}
ok: [141.95.160.133] => {
        "msg": "Le service apache era installé par le paquethttpd"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service mariadb era installé par le paquetmariadb-server"
}
ok: [141.95.160.133] => {
        "msg": "Le service mariadb era installé par le paquetmariadb-server"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic1.yml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire]


***************************************************************
ok: [146.59.158.16] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}
ok: [141.95.160.133] => {
        "msg": "Le service mariadb sera installé par le paquetmariadb-server"
}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2        changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2        changed=0        unreachable=0
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$ sudo vim var_dic1.yml


ansadmin@svl200:~$ ansible-playbook var_dic1.yml
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/var_dic1.yml': line 11, column 9, but may


be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                    rpm: httpd
                db:
                ^ here
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [variable dictionnaire]
***************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined va                                                                         
riable. The error was: 'list object' has no attribute 'db'\n\nThe error appears to be
in '/h                                                                               
ome/ansadmin/var_dic1.yml': line 16, column 5, but may\nbe elsewhere in the file
depending o                                                                         
n the exact syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n    -
name: vari                                                                           
able dictionnaire\n        ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefined v                                                                         
ariable. The error was: 'list object' has no attribute 'db'\n\nThe error appears to
be in '/                                                                             
home/ansadmin/var_dic1.yml': line 16, column 5, but may\nbe elsewhere in the file
depending                                                                           
on the exact syntax problem.\n\nThe offending line appears to be:\n\n    tasks:\n   
- name: var                                                                         
iable dictionnaire\n        ^ here\n"}

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=1        changed=0        unreachable=0 
failed=1        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=1        changed=0        unreachable=0
failed=1        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic1.yml
ansadmin@svl200:~$ ansible-playbook var_dic1.yml

PLAY [variable locale de type dictionnaire]


************************************************

TASK [Gathering Facts] **************************with_dict: "{{users}}"


ansadmin@svl200:~$ head var_dic_multi3.yml
---
- name: variable locale de type dictionnaire multi dimensions
    hosts: all
    become: true
    vars_files:
        - /home/ansadmin/vars_multi.yml

    tasks:
    - name: variable dictionnaire MultiDim
        user:
ansadmin@svl200:~$ head -n20 var_dic_multi3.yml
---
- name: variable locale de type dictionnaire multi dimensions
    hosts: all
    become: true
    vars_files:
        - /home/ansadmin/vars_multi.yml

    tasks:
    - name: variable dictionnaire MultiDim
        user:
                name: "{{item.key}}"
                group: "{{item.value.group}}"
                state: "{{item.value.state}}"
        [email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

ansadmin@svl200:~$ head -n30 var_dic_multi3.yml
---
- name: variable locale de type dictionnaire multi dimensions
    hosts: all
    become: true
    vars_files:
        - /home/ansadmin/vars_multi.yml

    tasks:
    - name: variable dictionnaire MultiDim
        user:
                name: "{{item.key}}"
                group: "{{item.value.group}}"
                state: "{{item.value.state}}"
        [email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ rm    var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml^C
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi3.yml

PLAY [variable locale de type dictionnaire multi dimensions]


*******************************

TASK [Gathering Facts]


*********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [variable dictionnaire MultiDim]


******************************************************
ok: [146.59.158.16] => (item={'key': 'antoine', 'value': {'group': 'users', 'state':
'presen                                                                             
t'}})
ok: [141.95.160.133] => (item={'key': 'antoine', 'value': {'group': 'users', 'state':
'prese                                                                               
nt'}})
ok: [146.59.158.16] => (item={'key': 'erwan', 'value': {'group': 'users', 'state':
'present'                                                                           
}})
ok: [141.95.160.133] => (item={'key': 'erwan', 'value': {'group': 'users', 'state':
'present                                                                             
'}})
ok: [146.59.158.16] => (item={'key': 'philippe', 'value': {'group': 'users', 'state':
'absen                                                                               
t'}})
ok: [141.95.160.133] => (item={'key': 'philippe', 'value': {'group': 'users',
'state': 'abse                                                                       
nt'}})

PLAY RECAP
*********************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim vars.yml
ansadmin@svl200:~$ cp vim vars.yml vars2.yml
cp: target 'vars2.yml' is not a directory
ansadmin@svl200:~$ sudo vim vars2.yml
ansadmin@svl200:~$ cp vars.yml vars2.yml
ansadmin@svl200:~$ sudo vim vars2.yml
ansadmin@svl200:~$ cp var_dic_multi3.yml var_dic_multi4.yml
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ls
cible1.txt      fact1.yaml            item_users.yaml      rep.yaml                 
var_dic_multi4.yml
copie.yaml      handler.yaml        items.yaml                seq.yaml               
vars.yml
debug.yaml      hello.yaml            items_users.yaml    shell.yml                 
vars2.yml
debug1.yaml    hello.yml              list.yaml                  template.yaml       
vars_multi.yml
exo2.yaml        index.html            locale.yml                template1.yaml     
when.yaml
exo3.yaml        index.html.j2      nginx.yaml                var_dic.yml           
when1.yaml
exo4.yaml        index.html1.j2    play-vars.yaml        var_dic2.yml
fact.yaml        ip.txt                    play-vars.yml          var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim var_dic.yml
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ sudo vim var_dic.yml
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ sudo vim var_dic.yml
ansadmin@svl200:~$ sudo vim var_dic2.yml
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was                                                   
: 'item' is undefined\n\nThe error appears to be in
'/home/ansadmin/var_dic_multi4.yml': line 9, column 5, but ma                       
y\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n    task                                                     
s:\n    - name: dictionnaire service\n        ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error wa                                                     
s: 'item' is undefined\n\nThe error appears to be in
'/home/ansadmin/var_dic_multi4.yml': line 9, column 5, but m                         
ay\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n    tas                                                       
ks:\n    - name: dictionnaire service\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ sudo vim vars2.yml
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/var_dic_multi4.yml': line 13, column 29,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

              state: latest
              when: "{{item.key}}" == "{{service[type]['name']}}"
                                                        ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was                                                   
: 'item' is undefined\n\nThe error appears to be in
'/home/ansadmin/var_dic_multi4.yml': line 9, column 5, but ma                       
y\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n    task                                                     
s:\n    - name: dictionnaire service\n        ^ here\n"}
fatal: [141.95.160.133]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error wa                                                     
s: 'item' is undefined\n\nThe error appears to be in
'/home/ansadmin/var_dic_multi4.yml': line 9, column 5, but m                         
ay\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n    tas                                                       
ks:\n    - name: dictionnaire service\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/var_dic_multi4.yml': line 13, column 26,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

              state: latest
              when: "type==web" and "ansible_os_family=Debian"
                                                  ^ here
We could be wrong, but this one looks like it might be an issue with
unbalanced quotes. If starting a value with a quote, make sure the
line ends with the same set of quotes. For instance this arbitrary
example:

        foo: "bad" "wolf"

Could be written as:

        foo: '"bad" "wolf"'


ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.
PLAY [variable locale de type dictionnaire (service) multi dimensions]
******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
PLAY [variable locale de type dictionnaire (service) multi dimensions]
******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ q

Command 'q' not found, but can be installed with:

snap install q                                              # version 1.6.3-1, or


apt    install python3-q-text-as-data    # version 1.7.4+2018.12.21+git+28f776ed46-2

See 'snap info q' for additional versions.

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Suppo                                                         
rted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, dp                                           
kg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_ca                                                 
che, upgrade"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt) module: when Supp                                                         
orted parameters include: allow_unauthenticated, autoclean, autoremove,
cache_valid_time, deb, default_release, d                                           
pkg_options, force, force_apt_get, install_recommends, only_upgrade, package,
policy_rc_d, purge, state, update_c                                                 
ache, upgrade"}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim vars2.yml


ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim var_dic_multi4.yml
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (when). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml --extra-vars "type=web"
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (when). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0

ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml --extra-vars "type=db"


[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (apt). Using last defined value only.
[WARNING]: While constructing a mapping from /home/ansadmin/var_dic_multi4.yml, line
9, column 5, found a
duplicate dict key (when). Using last defined value only.

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [dictionnaire service]


*************************************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml --extra-vars "type=db"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install webserver]


*************************************************************************************
***
skipping: [146.59.158.16]
skipping: [141.95.160.133]
TASK [install dbserver]
*************************************************************************************
****
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=0        skipped=2      rescued=0        ignored=                           
0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=0        skipped=2      rescued=0        ignored=                           
0

ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml --extra-vars "type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install webserver]


*************************************************************************************
***
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install dbserver]


*************************************************************************************
****
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim var_dic_multi4.yml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook var_dic_multi4.yml --extra-vars "type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install webserver]


*************************************************************************************
***
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install dbserver]


*************************************************************************************
****
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0

ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim group.yml
ansadmin@svl200:~$ mv vim group.yml inventory.yaml
mv: target 'inventory.yaml' is not a directory
ansadmin@svl200:~$ mv group.yml inventory.yaml
ansadmin@svl200:~$ sudo vim inventory.yaml
ansadmin@svl200:~$ ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"
[WARNING]: Skipping key (ansible_port) in group (vars) as it is not a mapping, it is
a <class 'int'>

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: ssh: co                                                         
nnect to host 146.59.158.16 port 22: Connection refused", "unreachable": true}
fatal: [141.95.160.133]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: ssh: c                                                         
onnect to host 141.95.160.133 port 22: Connection refused", "unreachable": true}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim inventory.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"
[WARNING]: Skipping key (ansible_port) in group (vars) as it is not a mapping, it is
a <class 'int'>

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: ssh: co                                                         
nnect to host 146.59.158.16 port 22: Connection refused", "unreachable": true}
fatal: [141.95.160.133]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: ssh: c                                                         
onnect to host 141.95.160.133 port 22: Connection refused", "unreachable": true}

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=                           
0
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0        rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim inventory.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


******************************************

TASK [Gathering Facts]


*************************************************************************************
*****
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install webserver]


*************************************************************************************
***
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install dbserver]


*************************************************************************************
****
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
*****************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=                           
0

ansadmin@svl200:~$ sudo vim inventory.yaml


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


*************************************************************************************
************

TASK [Gathering Facts]


*************************************************************************************
************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install webserver]


*************************************************************************************
**********************************************************
ok: [141.95.160.133]
ok: [146.59.158.16]

TASK [install dbserver]


*************************************************************************************
***********************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=0
ansadmin@svl200:~$ sudo vim inventory.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ tree
.
├── cible1.txt
├── copie.yaml
├── debug.yaml
├── debug1.yaml
├── exo2.yaml
├── exo3.yaml
├── exo4.yaml
├── fact.yaml
├── fact1.yaml
├── handler.yaml
├── hello.yaml
├── hello.yml
├── index.html
├── index.html.j2
├── index.html1.j2
├── inventory.yaml
├── ip.txt
├── item_users.yaml
├── items.yaml
├── items_users.yaml
├── list.yaml
├── locale.yml
├── nginx.yaml
├── play-vars.yaml
├── play-vars.yml
├── rep.yaml
├── seq.yaml
├── shell.yml
├── snap
│   └── tree
│            ├── 18
│            ├── common
│            └── current -> 18
├── template.yaml
├── template1.yaml
├── var_dic.yml
├── var_dic2.yml
├── var_dic_multi3.yml
├── var_dic_multi4.yml
├── vars.yml
├── vars2.yml
├── vars_multi.yml
├── when.yaml
└── when1.yaml

5 directories, 39 files
ansadmin@svl200:~$
ansadmin@svl200:~$ mkdir host_vars
ansadmin@svl200:~$ mkdir group_vars
ansadmin@svl200:~$ mkdir projet
ansadmin@svl200:~$ mv inventory.yaml var_dic_multi4.yml host_vars group_vars projet/
ansadmin@svl200:~$ cd projet/
ansadmin@svl200:~/projet$ ls
group_vars    host_vars    inventory.yaml    var_dic_multi4.yml
ansadmin@svl200:~/projet$ cd
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim vars2.yml
ansadmin@svl200:~$ cp vars2.yml projet/
ansadmin@svl200:~$
ansadmin@svl200:~$ cd projet/
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ls -lrt
total 20
-rw-r--r-- 1 ansadmin ansadmin    617 Oct    5 09:45 var_dic_multi4.yml
-rw-r--r-- 1 root          root            159 Oct    5 10:20 inventory.yaml
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:21 host_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:21 group_vars
-rw-r--r-- 1 ansadmin ansadmin    149 Oct    5 10:26 vars2.yml
ansadmin@svl200:~/projet$ mv var_dic_multi4.yml install.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ls -lrt
total 20
-rw-r--r-- 1 ansadmin ansadmin    617 Oct    5 09:45 install.yaml
-rw-r--r-- 1 root          root            159 Oct    5 10:20 inventory.yaml
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:21 host_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:21 group_vars
-rw-r--r-- 1 ansadmin ansadmin    149 Oct    5 10:26 vars2.yml
ansadmin@svl200:~/projet$ mv vars2.yml vars_install.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ls -lrt
total 20
-rw-r--r-- 1 ansadmin ansadmin    617 Oct    5 09:45 install.yaml
-rw-r--r-- 1 root          root            159 Oct    5 10:20 inventory.yaml
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:21 host_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:21 group_vars
-rw-r--r-- 1 ansadmin ansadmin    149 Oct    5 10:26 vars_install.yaml
ansadmin@svl200:~/projet$ sudo vim inventory.yaml
ansadmin@svl200:~/projet$ sudo vim inventory.yaml
ansadmin@svl200:~/projet$ cd group_vars/
ansadmin@svl200:~/projet/group_vars$ sudo vim port.yaml
ansadmin@svl200:~/projet/group_vars$ mv port.yaml cible1.yaml
ansadmin@svl200:~/projet/group_vars$ cp cible1.yaml cible2.yaml
ansadmin@svl200:~/projet/group_vars$
ansadmin@svl200:~/projet/group_vars$ cd ..
ansadmin@svl200:~/projet$ tree
.
├── group_vars
│   ├── cible1.yaml
│   └── cible2.yaml
├── host_vars
├── install.yaml
├── inventory.yaml
└── vars_install.yaml

2 directories, 5 files
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml var_dic_multi4.yml --
extra-vars "type=web"
ERROR! the playbook: var_dic_multi4.yml could not be found
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


*************************************************************************************
************

TASK [Gathering Facts]


*************************************************************************************
************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install webserver]


*************************************************************************************
**********************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install dbserver]


*************************************************************************************
***********************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
************************************************************************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        ignored=0

ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ sudo vim
group_vars/                host_vars/                  install.yaml             
inventory.yaml          vars_install.yaml
ansadmin@svl200:~/projet$ sudo vim inventory.yaml
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ls -lrt
total 20
-rw-r--r-- 1 ansadmin ansadmin    617 Oct    5 09:45 install.yaml
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:21 host_vars
-rw-r--r-- 1 ansadmin ansadmin    149 Oct    5 10:26 vars_install.yaml
-rw-r--r-- 1 root          root            171 Oct    5 10:30 inventory.yaml
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:32 group_vars
ansadmin@svl200:~/projet$ cd group_vars/
ansadmin@svl200:~/projet/group_vars$ ls
cible1.yaml    cible2.yaml
ansadmin@svl200:~/projet/group_vars$ sudo vim cible1.yaml
ansadmin@svl200:~/projet/group_vars$ sudo vim cible2.yaml
ansadmin@svl200:~/projet/group_vars$ ls -lrt
ansadmin@svl200:~/projet/group_vars$ ansible-playbook -i inventory.yaml install.yaml
--extra-vars "type=web"                                                             
ERROR! the playbook: install.yaml could not be found
ansadmin@svl200:~/projet/group_vars$ cd
ansadmin@svl200:~$ cd projet/
ansadmin@svl200:~/projet$ ls
group_vars    host_vars    install.yaml    inventory.yaml    vars_install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


**************************************

TASK [Gathering Facts]


*************************************************************************************
*
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: ssh                                                             
: connect to host 146.59.158.16 port 2222: Connection refused", "unreachable": true}
fatal: [141.95.160.133]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: ss                                                             
h: connect to host 141.95.160.133 port 2222: Connection refused", "unreachable":
true}

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        igno                               
red=0
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0        rescued=0        igno                               
red=0

ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ cd projet/
-bash: cd: projet/: No such file or directory
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ cd group_vars/
ansadmin@svl200:~/projet/group_vars$ sudo vim cible1.yaml
ansadmin@svl200:~/projet/group_vars$ sudo vim cible2.yaml
ansadmin@svl200:~/projet/group_vars$ cd ..
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


**************************************

TASK [Gathering Facts]


*************************************************************************************
*
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install webserver]


************************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [install dbserver]


*************************************************************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

PLAY RECAP
*************************************************************************************
*************
141.95.160.133                          : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        igno                               
red=0
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=1      rescued=0        igno                               
red=0

ansadmin@svl200:~/projet$ cd host_vars/
ansadmin@svl200:~/projet/host_vars$ sudo vim client1.yaml
ansadmin@svl200:~/projet/host_vars$ sudo vim client2.yaml
ansadmin@svl200:~/projet/host_vars$ cd ..
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ cd host_vars/
ansadmin@svl200:~/projet/host_vars$ ls
client1.yaml    client2.yaml
ansadmin@svl200:~/projet/host_vars$ cd ..
ansadmin@svl200:~/projet$ sudo vim inventory.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/projet/install.yaml': line 26, column 18,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

              msg: " var est {{vars5}}


              #              ("{{item.key}}" == "{{service[type]['name']}}")
                                  ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 16, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

              #              ("{{item.key}}" == "{{service[type]['name']}}")
    - name: install dbserver
        ^ here
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ cd host_vars/
ansadmin@svl200:~/projet/host_vars$ sudo vim client1.yaml
ansadmin@svl200:~/projet/host_vars$ sudo vim client2.yaml
ansadmin@svl200:~/projet/host_vars$ cd ..
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 16, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

              #              ("{{item.key}}" == "{{service[type]['name']}}")
    - name: install dbserver
        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 16, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

              #              ("{{item.key}}" == "{{service[type]['name']}}")
    - name: install dbserver
        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ cd host_vars/
ansadmin@svl200:~/projet/host_vars$ ls
client1.yaml    client2.yaml
ansadmin@svl200:~/projet/host_vars$ ll
total 16
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 10:49 ./
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    5 10:51 ../
-rw-r--r-- 1 root          root              13 Oct    5 10:49 client1.yaml
-rw-r--r-- 1 root          root              12 Oct    5 10:49 client2.yaml
ansadmin@svl200:~/projet/host_vars$ cd ..
ansadmin@svl200:~/projet$ cd
group_vars/ host_vars/
ansadmin@svl200:~/projet$ cd group_vars/
ansadmin@svl200:~/projet/group_vars$ ls
cible1.yaml    cible2.yaml
ansadmin@svl200:~/projet/group_vars$ sudo vim cible1.yaml
ansadmin@svl200:~/projet/group_vars$
ansadmin@svl200:~/projet/group_vars$ cd ..
ansadmin@svl200:~/projet$ cd host_vars/
ansadmin@svl200:~/projet/host_vars$ ls
client1.yaml    client2.yaml
ansadmin@svl200:~/projet/host_vars$ sudo vim client1.yaml
ansadmin@svl200:~/projet/host_vars$ sudo vim client2.yaml
ansadmin@svl200:~/projet/host_vars$ cd ..
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 16, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

              #              ("{{item.key}}" == "{{service[type]['name']}}")
    - name: install dbserver
        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 16, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

              #              ("{{item.key}}" == "{{service[type]['name']}}")
    - name: install dbserver
        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 15, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


    - name: install dbserver
        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! 'debug' is not a valid attribute for a Play

The error appears to be in '/home/ansadmin/projet/install.yaml': line 2, column 3,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: variable locale de type dictionnaire (service) multi dimensions
    ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 15, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: install dbserver


        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/projet/install.yaml': line 23, column 6,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

          debug:
          ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ cd
ansadmin@svl200:~$ sudo vim
.ansible/                      copie.yaml                    hello.yml               
nginx.yaml                    var_dic.yml
.bash_history              debug.yaml                    index.html                 
play-vars.yaml            var_dic2.yml
.bash_logout                debug1.yaml                  index.html.j2             
play-vars.yml              var_dic_multi3.yml
.bashrc                          exo2.yaml                      index.html1.j2       
projet/                          vars.yml
.exo4.yaml.swp            exo3.yaml                      ip.txt                     
rep.yaml                        vars2.yml
.handler.yaml.swp      exo4.yaml                      item_users.yaml         
seq.yaml                        vars_multi.yml
.profile                        fact.yaml                      items.yaml           
shell.yml                      when.yaml
.ssh/                              fact1.yaml                    items_users.yaml   
snap/                              when1.yaml
.viminfo                        handler.yaml                list.yaml               
template.yaml
cible1.txt                    hello.yaml                    locale.yml               
template1.yaml
ansadmin@svl200:~$ sudo vim debug.yaml
ansadmin@svl200:~$ cd projet/
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 15, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: install dbserver


        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 15, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: install dbserver


        ^ here
ansadmin@svl200:~/projet$ sudo vim
group_vars/                host_vars/                  install.yaml             
inventory.yaml          vars_install.yaml
ansadmin@svl200:~/projet$ sudo vim inventory.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ cd
group_vars/ host_vars/
ansadmin@svl200:~/projet$ cd group_vars/
ansadmin@svl200:~/projet/group_vars$ ls
cible1.yaml    cible2.yaml
ansadmin@svl200:~/projet/group_vars$ sudo vim cible1.yaml
ansadmin@svl200:~/projet/group_vars$ sudo vim cible2.yaml
ansadmin@svl200:~/projet/group_vars$ ansible-playbook -i inventory.yaml install.yaml
--extra-vars "type=web"
ERROR! the playbook: install.yaml could not be found
ansadmin@svl200:~/projet/group_vars$ cd ..
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 15, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: install dbserver


        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ cd host_vars/
ansadmin@svl200:~/projet/host_vars$ ls
client1.yaml    client2.yaml
ansadmin@svl200:~/projet/host_vars$ sudo vim client1.yaml
ansadmin@svl200:~/projet/host_vars$ sudo vim client2.yaml
ansadmin@svl200:~/projet/host_vars$ ansible-playbook -i inventory.yaml install.yaml
--extra-vars "type=web"
ERROR! the playbook: install.yaml could not be found
ansadmin@svl200:~/projet/host_vars$ cd ..
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 15, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: install dbserver


        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet/install.yaml': line 16, column 9,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


    - name: install dbserver
          apt:
                ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


**************************************

TASK [Gathering Facts]


*************************************************************************************
*
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: Coul                                                             
d not resolve hostname client1: Temporary failure in name resolution", "unreachable":
true}
fatal: [client2]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: Coul                                                             
d not resolve hostname client2: Temporary failure in name resolution", "unreachable":
true}

PLAY RECAP
*************************************************************************************
*************
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        igno           
red=0
client2                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        igno           
red=0

ansadmin@svl200:~/projet$ cd host_vars/
ansadmin@svl200:~/projet/host_vars$ ls
client1.yaml    client2.yaml
ansadmin@svl200:~/projet/host_vars$ sudo vim client1.yaml
ansadmin@svl200:~/projet/host_vars$ sudo vim client2.yaml
ansadmin@svl200:~/projet/host_vars$ cd ..
ansadmin@svl200:~/projet$ cd group_vars/
ansadmin@svl200:~/projet/group_vars$ ls
cible1.yaml    cible2.yaml
ansadmin@svl200:~/projet/group_vars$ sudo vim cible1.yaml
ansadmin@svl200:~/projet/group_vars$ sudo vim cible2.yaml
ansadmin@svl200:~/projet/group_vars$
ansadmin@svl200:~/projet/group_vars$ cd ..
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


**************************************

TASK [Gathering Facts]


*************************************************************************************
*
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: Coul                                                             
d not resolve hostname client1: Temporary failure in name resolution", "unreachable":
true}
fatal: [client2]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: Coul                                                             
d not resolve hostname client2: Temporary failure in name resolution", "unreachable":
true}

PLAY RECAP
*************************************************************************************
*************
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        igno           
red=0
client2                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        igno           
red=0

ansadmin@svl200:~/projet$ sudo vim install.yaml


ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! conflicting action statements: apt, debug

The error appears to be in '/home/ansadmin/projet/install.yaml': line 15, column 5,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: install dbserver


        ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/projet/install.yaml': line 23, column 4,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

      debug:
      ^ here
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context
The error appears to be in '/home/ansadmin/projet/install.yaml': line 23, column 15,
but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

                  debug:
                            ^ here
ansadmin@svl200:~/projet$ sudo vim install.yaml
ansadmin@svl200:~/projet$ ansible-playbook -i inventory.yaml install.yaml --extra-
vars "type=web"

PLAY [variable locale de type dictionnaire (service) multi dimensions]


**************************************

TASK [Gathering Facts]


*************************************************************************************
*
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: Coul                                                             
d not resolve hostname client1: Temporary failure in name resolution", "unreachable":
true}
fatal: [client2]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: Coul                                                             
d not resolve hostname client2: Temporary failure in name resolution", "unreachable":
true}

PLAY RECAP
*************************************************************************************
*************
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        igno           
red=0
client2                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        igno           
red=0

ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ ll
total 28
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    5 11:47 ./
drwxr-xr-x 6 ansadmin ansadmin 4096 Oct    5 11:29 ../
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 11:43 group_vars/
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 11:40 host_vars/
-rw-r--r-- 1 ansadmin ansadmin    563 Oct    5 11:47 install.yaml
-rw-r--r-- 1 root          root            158 Oct    5 11:31 inventory.yaml
-rw-r--r-- 1 ansadmin ansadmin    149 Oct    5 10:26 vars_install.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ tree
.
├── group_vars
│   ├── cible1.yaml
│   └── cible2.yaml
├── host_vars
│   ├── client1.yaml
│   └── client2.yaml
├── install.yaml
├── inventory.yaml
└── vars_install.yaml

2 directories, 7 files
ansadmin@svl200:~/projet$ cd
ansadmin@svl200:~$
ansadmin@svl200:~$ mkdir projet1
ansadmin@svl200:~$ cd projet1
ansadmin@svl200:~/projet1$ mkdir roles
ansadmin@svl200:~/projet1$ cd roles/
ansadmin@svl200:~/projet1/roles$ mkdir apache
ansadmin@svl200:~/projet1/roles$ cd apache/
ansadmin@svl200:~/projet1/roles/apache$ tree
.

0 directories, 0 files
ansadmin@svl200:~/projet1/roles/apache$ pwd
/home/ansadmin/projet1/roles/apache
ansadmin@svl200:~/projet1/roles/apache$ mkdir tasks vars templates handlers
ansadmin@svl200:~/projet1/roles/apache$ tree
.
├── handlers
├── tasks
├── templates
└── vars

4 directories, 0 files
ansadmin@svl200:~/projet1/roles/apache$ touch tasks/main.yml
ansadmin@svl200:~/projet1/roles/apache$ touch vars/main.yml
ansadmin@svl200:~/projet1/roles/apache$ touch handlers/main.yml
ansadmin@svl200:~/projet1/roles/apache$ tree
.
├── handlers
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
└── vars
        └── main.yml

4 directories, 3 files
ansadmin@svl200:~/projet1/roles/apache$ sudo vim tasks/main.yml
ansadmin@svl200:~/projet1/roles/apache$ sudo vim handlers/main.yml
ansadmin@svl200:~/projet1/roles/apache$ sudo vim vars/main.yml
ansadmin@svl200:~/projet1/roles/apache$ sudo vim t
tasks/          templates/
ansadmin@svl200:~/projet1/roles/apache$ sudo vim templates/index.html.j2
ansadmin@svl200:~/projet1/roles/apache$ cd ..
ansadmin@svl200:~/projet1/roles$ cd ..
ansadmin@svl200:~/projet1$ sudo vim hosts.yml
ansadmin@svl200:~/projet1$ sudo vim site.yml
ansadmin@svl200:~/projet1$ sudo vim templates/index.html.j2
ansadmin@svl200:~/projet1$ cd roles/apache
ansadmin@svl200:~/projet1/roles/apache$ sudo vim templates/index.html.j2
ansadmin@svl200:~/projet1/roles/apache$ sudo vim vars/main.yml
ansadmin@svl200:~/projet1/roles/apache$
ansadmin@svl200:~/projet1/roles/apache$ cd ..
ansadmin@svl200:~/projet1/roles$ cd ..
ansadmin@svl200:~/projet1$ ansible-playbook -i
hosts.yml    roles/          site.yml
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
[WARNING]: provided hosts list is empty, only localhost is available. Note that the
implicit localhost does not match 'all'

PLAY [install apache]


*************************************************************************************
*************************
skipping: no hosts matched

PLAY RECAP
*************************************************************************************
************************************

ansadmin@svl200:~/projet1$ sudo vim hosts.yml


ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml

PLAY [install apache]


*************************************************************************************
*************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: Could not resolve hostname                                        
client1: Temporary failure in name resolution", "unreachable": true}

PLAY RECAP
*************************************************************************************
************************************
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/projet1$ tree
.
├── hosts.yml
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml
6 directories, 6 files
ansadmin@svl200:~/projet1$ curl client1
curl: (6) Could not resolve host: client1
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ tree
.
├── hosts.yml
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

6 directories, 6 files
ansadmin@svl200:~/projet1$ mkdir group_vars
ansadmin@svl200:~/projet1$ mkdir hosts_vars
ansadmin@svl200:~/projet1$ cat roles/apache/tasks/main.yml
---
- name: install apache
    apt:
      name: apache2
      state: latest

- name: copy index


    template:
              src: index.html.j2
              dest: /var/www/html/index.html
    notify: restart_apache
ansadmin@svl200:~/projet1$ cat roles/apache/handlers/main.yml
---
- name: restart_apache
    systemd:
          name: apache2
          state: restarted

ansadmin@svl200:~/projet1$ cat roles/apache/vars/main.yml


---
- file_version: 5
ansadmin@svl200:~/projet1$ cat roles/apache/templates/index.html.j2
Je suis un fichier de test
Je suis deploye sur le serveur {{ansible_hostname}} avec apache version
{{file_version}}
ansadmin@svl200:~/projet1$ sudo vim site.yml
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
ERROR! failed to combine variables, expected dicts but got a 'dict' and a
'AnsibleSequence':
{}
[{"file_version": 5}]
ansadmin@svl200:~/projet1$ sudo vim roles/apache/vars/main.yml
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
ERROR! failed to combine variables, expected dicts but got a 'dict' and a
'AnsibleSequence':
{}
[{"file_version": 4.42}]
ansadmin@svl200:~/projet1$ sudo vim roles/apache/vars/main.yml
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
ERROR! failed to combine variables, expected dicts but got a 'dict' and a
'AnsibleSequence':
{}
[{"file_version": 4.42}]
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ tree
.
├── group_vars
├── hosts.yml
├── hosts_vars
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 6 files
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
ERROR! failed to combine variables, expected dicts but got a 'dict' and a
'AnsibleSequence':
{}
[{"file_version": 4.42}]
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
ERROR! failed to combine variables, expected dicts but got a 'dict' and a
'AnsibleSequence':
{}
[{"file_version": 4.42}]
ansadmin@svl200:~/projet1$ cat roles/apache/templates/index.html.j2
Je suis un fichier de test
Je suis deploye sur le serveur {{ansible_hostname}} avec apache version
{{file_version}}
ansadmin@svl200:~/projet1$ sudo vim roles/apache/vars/main.yml
ansadmin@svl200:~/projet1$ cat roles/apache/templates/index.html.j2
Je suis un fichier de test
Je suis deploye sur le serveur {{ansible_hostname}} avec apache version
{{file_version}}
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
ERROR! failed to combine variables, expected dicts but got a 'dict' and a
'AnsibleSequence':
{}
[{"file_version": 4.42}]
ansadmin@svl200:~/projet1$ sudo vim roles/apache/
handlers/    tasks/          templates/ vars/
ansadmin@svl200:~/projet1$ sudo vim roles/apache/tasks/main.yml
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
ERROR! failed to combine variables, expected dicts but got a 'dict' and a
'AnsibleSequence':
{}
[{"file_version": 4.42}]
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ tree
.
├── group_vars
├── hosts.yml
├── hosts_vars
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 6 files
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml
ERROR! failed to combine variables, expected dicts but got a 'dict' and a
'AnsibleSequence':
{}
[{"file_version": 4.42}]
ansadmin@svl200:~/projet1$ sudo vim roles/apache/vars/main.yml
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml

PLAY [install apache]


*************************************************************************************
*************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: Could not resolve hostname                                        
client1: Temporary failure in name resolution", "unreachable": true}

PLAY RECAP
*************************************************************************************
************************************
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/projet1$ cd
ansadmin@svl200:~$ sudo vim /etc/hosts
ansadmin@svl200:~$
ansadmin@svl200:~$ cd projet1/
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml

PLAY [install apache]


*************************************************************************************
*************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: connect to host client1 por                                       
t 22: Connection refused", "unreachable": true}

PLAY RECAP
*************************************************************************************
************************************
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/projet1$ tree
.
├── group_vars
├── hosts.yml
├── hosts_vars
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 6 files
ansadmin@svl200:~/projet1$ cat hosts
hosts.yml      hosts_vars/
ansadmin@svl200:~/projet1$ cat hosts
hosts.yml      hosts_vars/
ansadmin@svl200:~/projet1$ cat hosts.yml
all:
      children:
                cible1:
                      hosts:
                        client1:
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml

PLAY [install apache]


*************************************************************************************
*************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: connect to host client1 por                                       
t 22: Connection refused", "unreachable": true}

PLAY RECAP
*************************************************************************************
************************************
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/projet1$ cd
ansadmin@svl200:~$ sudo vim /etc/hosts
ansadmin@svl200:~$ cd projet1/
ansadmin@svl200:~/projet1$ ansible -i
group_vars/ hosts.yml      hosts_vars/ roles/            site.yml
ansadmin@svl200:~/projet1$ ansible -i hosts.yml client1 -m ping
client1 | UNREACHABLE! => {
        "changed": false,
        "msg": "Failed to connect to the host via ssh: ssh: connect to host client1
port 22: Connection refused",
        "unreachable": true
}
ansadmin@svl200:~/projet1$ cd roles/
ansadmin@svl200:~/projet1/roles$ ls
apache
ansadmin@svl200:~/projet1/roles$ cd apache/
ansadmin@svl200:~/projet1/roles/apache$ ls
handlers    tasks    templates    vars
ansadmin@svl200:~/projet1/roles/apache$ sudo vim vars/main.yml
ansadmin@svl200:~/projet1/roles/apache$ sudo vim
handlers/    tasks/          templates/ vars/
ansadmin@svl200:~/projet1/roles/apache$ sudo vim handlers/main.yml
ansadmin@svl200:~/projet1/roles/apache$ sudo vim templates/
ansadmin@svl200:~/projet1/roles/apache$ sudo vim templates/index.html.j2
ansadmin@svl200:~/projet1/roles/apache$
ansadmin@svl200:~/projet1/roles/apache$ sudo vim
handlers/    tasks/          templates/ vars/
ansadmin@svl200:~/projet1/roles/apache$ sudo vim
handlers/    tasks/          templates/ vars/
ansadmin@svl200:~/projet1/roles/apache$ cd ..
ansadmin@svl200:~/projet1/roles$ ll
total 12
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    5 12:14 ./
drwxrwxr-x 5 ansadmin ansadmin 4096 Oct    5 12:39 ../
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    5 12:15 apache/
ansadmin@svl200:~/projet1/roles$ cd ..
ansadmin@svl200:~/projet1$ ll
total 28
drwxrwxr-x 5 ansadmin ansadmin 4096 Oct    5 12:39 ./
drwxr-xr-x 7 ansadmin ansadmin 4096 Oct    5 12:13 ../
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 12:37 group_vars/
-rw-r--r-- 1 root          root              73 Oct    5 12:33 hosts.yml
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 12:37 hosts_vars/
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    5 12:14 roles/
-rw-r--r-- 1 root          root              80 Oct    5 12:39 site.yml
ansadmin@svl200:~/projet1$ sudo vim site.yml
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml

PLAY [install apache]


*************************************************************************************
*************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: ssh: connect to host client1 por                                       
t 22: Connection refused", "unreachable": true}

PLAY RECAP
*************************************************************************************
************************************
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ ansible -i hosts.yml client1 -m ping
client1 | UNREACHABLE! => {
        "changed": false,
        "msg": "Failed to connect to the host via ssh: ssh: connect to host client1
port 22: Connection refused",
        "unreachable": true
}
ansadmin@svl200:~/projet1$ tree
.
├── group_vars
├── hosts.yml
├── hosts_vars
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 6 files
ansadmin@svl200:~/projet1$ cd group_vars/
ansadmin@svl200:~/projet1/group_vars$ ls
ansadmin@svl200:~/projet1/group_vars$ sudo vim all.yml
ansadmin@svl200:~/projet1/group_vars$ cd ..
ansadmin@svl200:~/projet1$ ansible -i hosts.yml client1 -m ping
The authenticity of host '[client1]:55600 ([146.59.158.16]:55600)' can't be
established.
ECDSA key fingerprint is SHA256:aQH+1UeVJklKq8A45Soa63iOGGkNRC/op7o5MgPiJtc.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
client1 | SUCCESS => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false,
        "ping": "pong"
}
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ ansible -i hosts.yml client1 -m ping
client1 | SUCCESS => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": false,
        "ping": "pong"
}
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml

PLAY [install apache]


*************************************************************************************
*************************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [client1]

TASK [apache : install apache]


*************************************************************************************
****************
ok: [client1]

TASK [apache : copy index]


*************************************************************************************
********************
changed: [client1]

RUNNING HANDLER [apache : restart_apache]


*************************************************************************************
*****
fatal: [client1]: FAILED! => {"changed": false, "msg": "Unable to start service
apache2: Job for apache2.service failed because the                                  
control process exited with error code.\nSee \"systemctl status apache2.service\" and
\"journalctl -xe\" for details.\n"}

NO MORE HOSTS LEFT


*************************************************************************************
****************************
PLAY RECAP
*************************************************************************************
************************************
client1                                        : ok=3      changed=1     
unreachable=0        failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/projet1$ cd
ansadmin@svl200:~$ ansible all -m service -a "name=nginx state= stopped"
ERROR! this task 'service' has extra params, which is only allowed in the following
mo                                                                                   
dules: include_role, import_tasks, win_command, add_host, include_vars, group_by,
set_                                                                                 
fact, win_shell, script, include_tasks, command, import_role, raw, meta, include,
shel                                                                                 
l
ansadmin@svl200:~$ cd projet/
group_vars/ host_vars/
ansadmin@svl200:~$ cd projet1/
group_vars/ hosts_vars/ roles/
ansadmin@svl200:~$ cd projet1/roles/apache/
handlers/    tasks/          templates/ vars/
ansadmin@svl200:~$ sudo vim projet1/roles/apache/vars/
ansadmin@svl200:~$ sudo vim projet1/roles/apache/vars/main.yml
ansadmin@svl200:~$ cd projet1
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet1$ cd group_vars/
ansadmin@svl200:~/projet1/group_vars$ sudo vim all.yml
ansadmin@svl200:~/projet1/group_vars$
ansadmin@svl200:~/projet1/group_vars$ cd ..
ansadmin@svl200:~/projet1$ ansible all -bm service -a "name=nginx state=stopped"
146.59.158.16 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "name": "nginx",
        "state": "stopped",
        "status": {
                "ActiveEnterTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "ActiveEnterTimestampMonotonic": "3302273985318",
                "ActiveExitTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "ActiveExitTimestampMonotonic": "3302273891667",
                "ActiveState": "active",
                "After": "basic.target systemd-journald.socket system.slice
network.target sys                                                                   
init.target",
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "AssertTimestampMonotonic": "3302273921869",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "yes",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_f                                                           
owner cap_fsetid cap_kill cap_setgid cap_setuid cap_setpcap cap_linux_immutable
cap_ne                                                                               
t_bind_service cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner
cap_sys_module cap_sys_rawio cap_sys_chroot cap_sys_ptrace cap_sys_pacct
cap_sys_admin                                                                       
cap_sys_boot cap_sys_nice cap_sys_resource cap_sys_time cap_sys_tty_config cap_mknod
cap_lease cap_audit_write cap_audit_control cap_setfcap cap_mac_override
cap_mac_admin                                                                       
cap_syslog cap_wake_alarm cap_block_suspend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "ConditionTimestampMonotonic": "3302273921868",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlGroup": "/system.slice/nginx.service",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "A high performance web server and a reverse proxy
server",
                "DevicePolicy": "auto",
                "Documentation": "man:nginx(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "ExecMainCode": "0",
                "ExecMainExitTimestampMonotonic": "0",
                "ExecMainPID": "259389",
                "ExecMainStartTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "ExecMainStartTimestampMonotonic": "3302273985272",
                "ExecMainStatus": "0",
                "ExecReload": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -g
daemon on; m                                                                         
aster_process on; -s reload ; ignore_errors=no ; start_time=[n/a] ; stop_time=[n/a] ;
pid=0 ; code=(null) ; status=0/0 }",
                "ExecReloadEx": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -g
daemon on;                                                                           
master_process on; -s reload ; flags= ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
code=(null) ; status=0/0 }",
                "ExecStart": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -g
daemon on; ma                                                                       
ster_process on; ; ignore_errors=no ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
cod                                                                                 
e=(null) ; status=0/0 }",
                "ExecStartEx": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -g
daemon on;                                                                          
master_process on; ; flags= ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
code=(null)                                                                         
; status=0/0 }",
                "ExecStartPre": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -t -
q -g daem                                                                           
on on; master_process on; ; ignore_errors=no ; start_time=[n/a] ; stop_time=[n/a] ;
pi                                                                                   
d=0 ; code=(null) ; status=0/0 }",
                "ExecStartPreEx": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -t
-q -g da                                                                             
emon on; master_process on; ; flags= ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
co                                                                                   
de=(null) ; status=0/0 }",
                "ExecStop": "{ path=/sbin/start-stop-daemon ; argv[]=/sbin/start-
stop-daemon -                                                                       
-quiet --stop --retry QUIT/5 --pidfile /run/nginx.pid ; ignore_errors=yes ;
start_time                                                                           
=[n/a] ; stop_time=[n/a] ; pid=0 ; code=(null) ; status=0/0 }",
                "ExecStopEx": "{ path=/sbin/start-stop-daemon ; argv[]=/sbin/start-
stop-daemon                                                                         
--quiet --stop --retry QUIT/5 --pidfile /run/nginx.pid ; flags=ignore-failure ; start
_time=[n/a] ; stop_time=[n/a] ; pid=0 ; code=(null) ; status=0/0 }",
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/nginx.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "nginx.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "yes",
                "InactiveEnterTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "InactiveEnterTimestampMonotonic": "3302273920721",
                "InactiveExitTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "InactiveExitTimestampMonotonic": "3302273924890",
                "InvocationID": "ae99bd68c38e4f0888f4fcc0fdb6e604",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "mixed",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "259389",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "3936256",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "nginx.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "PIDFile": "/run/nginx.pid",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "system.slice sysinit.target",
                "Restart": "no",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "StateChangeTimestampMonotonic": "3302273985318",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "running",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "2",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "5s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "5s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "forking",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
141.95.160.133 | CHANGED => {
        "ansible_facts": {
                "discovered_interpreter_python": "/usr/bin/python3"
        },
        "changed": true,
        "name": "nginx",
        "state": "stopped",
        "status": {
                "ActiveEnterTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "ActiveEnterTimestampMonotonic": "1653327603774",
                "ActiveExitTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "ActiveExitTimestampMonotonic": "1653327512824",
                "ActiveState": "active",
                "After": "system.slice sysinit.target systemd-journald.socket
network.target b                                                                     
asic.target",
                "AllowIsolate": "no",
                "AllowedCPUs": "",
                "AllowedMemoryNodes": "",
                "AmbientCapabilities": "",
                "AssertResult": "yes",
                "AssertTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "AssertTimestampMonotonic": "1653327525041",
                "Before": "shutdown.target multi-user.target",
                "BlockIOAccounting": "no",
                "BlockIOWeight": "[not set]",
                "CPUAccounting": "no",
                "CPUAffinity": "",
                "CPUAffinityFromNUMA": "no",
                "CPUQuotaPerSecUSec": "infinity",
                "CPUQuotaPeriodUSec": "infinity",
                "CPUSchedulingPolicy": "0",
                "CPUSchedulingPriority": "0",
                "CPUSchedulingResetOnFork": "no",
                "CPUShares": "[not set]",
                "CPUUsageNSec": "[not set]",
                "CPUWeight": "[not set]",
                "CacheDirectoryMode": "0755",
                "CanIsolate": "no",
                "CanReload": "yes",
                "CanStart": "yes",
                "CanStop": "yes",
                "CapabilityBoundingSet": "cap_chown cap_dac_override
cap_dac_read_search cap_f                                                           
owner cap_fsetid cap_kill cap_setgid cap_setuid cap_setpcap cap_linux_immutable
cap_ne                                                                               
t_bind_service cap_net_broadcast cap_net_admin cap_net_raw cap_ipc_lock cap_ipc_owner
cap_sys_module cap_sys_rawio cap_sys_chroot cap_sys_ptrace cap_sys_pacct
cap_sys_admin                                                                       
cap_sys_boot cap_sys_nice cap_sys_resource cap_sys_time cap_sys_tty_config cap_mknod
cap_lease cap_audit_write cap_audit_control cap_setfcap cap_mac_override
cap_mac_admin                                                                       
cap_syslog cap_wake_alarm cap_block_suspend cap_audit_read",
                "CleanResult": "success",
                "CollectMode": "inactive",
                "ConditionResult": "yes",
                "ConditionTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "ConditionTimestampMonotonic": "1653327525041",
                "ConfigurationDirectoryMode": "0755",
                "Conflicts": "shutdown.target",
                "ControlGroup": "/system.slice/nginx.service",
                "ControlPID": "0",
                "DefaultDependencies": "yes",
                "DefaultMemoryLow": "0",
                "DefaultMemoryMin": "0",
                "Delegate": "no",
                "Description": "A high performance web server and a reverse proxy
server",
                "DevicePolicy": "auto",
                "Documentation": "man:nginx(8)",
                "DynamicUser": "no",
                "EffectiveCPUs": "",
                "EffectiveMemoryNodes": "",
                "ExecMainCode": "0",
                "ExecMainExitTimestampMonotonic": "0",
                "ExecMainPID": "168715",
                "ExecMainStartTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "ExecMainStartTimestampMonotonic": "1653327603733",
                "ExecMainStatus": "0",
                "ExecReload": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -g
daemon on; m                                                                         
aster_process on; -s reload ; ignore_errors=no ; start_time=[n/a] ; stop_time=[n/a] ;
pid=0 ; code=(null) ; status=0/0 }",
                "ExecReloadEx": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -g
daemon on;                                                                           
master_process on; -s reload ; flags= ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
code=(null) ; status=0/0 }",
                "ExecStart": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -g
daemon on; ma                                                                       
ster_process on; ; ignore_errors=no ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
cod                                                                                 
e=(null) ; status=0/0 }",
                "ExecStartEx": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -g
daemon on;                                                                          
master_process on; ; flags= ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
code=(null)                                                                         
; status=0/0 }",
                "ExecStartPre": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -t -
q -g daem                                                                           
on on; master_process on; ; ignore_errors=no ; start_time=[n/a] ; stop_time=[n/a] ;
pi                                                                                   
d=0 ; code=(null) ; status=0/0 }",
                "ExecStartPreEx": "{ path=/usr/sbin/nginx ; argv[]=/usr/sbin/nginx -t
-q -g da                                                                             
emon on; master_process on; ; flags= ; start_time=[n/a] ; stop_time=[n/a] ; pid=0 ;
co                                                                                   
de=(null) ; status=0/0 }",
                "ExecStop": "{ path=/sbin/start-stop-daemon ; argv[]=/sbin/start-
stop-daemon -                                                                       
-quiet --stop --retry QUIT/5 --pidfile /run/nginx.pid ; ignore_errors=yes ;
start_time                                                                           
=[n/a] ; stop_time=[n/a] ; pid=0 ; code=(null) ; status=0/0 }",
                "ExecStopEx": "{ path=/sbin/start-stop-daemon ; argv[]=/sbin/start-
stop-daemon                                                                         
--quiet --stop --retry QUIT/5 --pidfile /run/nginx.pid ; flags=ignore-failure ; start
_time=[n/a] ; stop_time=[n/a] ; pid=0 ; code=(null) ; status=0/0 }",
                "FailureAction": "none",
                "FileDescriptorStoreMax": "0",
                "FinalKillSignal": "9",
                "FragmentPath": "/lib/systemd/system/nginx.service",
                "GID": "[not set]",
                "GuessMainPID": "yes",
                "IOAccounting": "no",
                "IOReadBytes": "18446744073709551615",
                "IOReadOperations": "18446744073709551615",
                "IOSchedulingClass": "0",
                "IOSchedulingPriority": "0",
                "IOWeight": "[not set]",
                "IOWriteBytes": "18446744073709551615",
                "IOWriteOperations": "18446744073709551615",
                "IPAccounting": "no",
                "IPEgressBytes": "[no data]",
                "IPEgressPackets": "[no data]",
                "IPIngressBytes": "[no data]",
                "IPIngressPackets": "[no data]",
                "Id": "nginx.service",
                "IgnoreOnIsolate": "no",
                "IgnoreSIGPIPE": "yes",
                "InactiveEnterTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "InactiveEnterTimestampMonotonic": "1653327524043",
                "InactiveExitTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "InactiveExitTimestampMonotonic": "1653327527139",
                "InvocationID": "d47d8efaef624bfd94ed882646996bd0",
                "JobRunningTimeoutUSec": "infinity",
                "JobTimeoutAction": "none",
                "JobTimeoutUSec": "infinity",
                "KeyringMode": "private",
                "KillMode": "mixed",
                "KillSignal": "15",
                "LimitAS": "infinity",
                "LimitASSoft": "infinity",
                "LimitCORE": "infinity",
                "LimitCORESoft": "0",
                "LimitCPU": "infinity",
                "LimitCPUSoft": "infinity",
                "LimitDATA": "infinity",
                "LimitDATASoft": "infinity",
                "LimitFSIZE": "infinity",
                "LimitFSIZESoft": "infinity",
                "LimitLOCKS": "infinity",
                "LimitLOCKSSoft": "infinity",
                "LimitMEMLOCK": "65536",
                "LimitMEMLOCKSoft": "65536",
                "LimitMSGQUEUE": "819200",
                "LimitMSGQUEUESoft": "819200",
                "LimitNICE": "0",
                "LimitNICESoft": "0",
                "LimitNOFILE": "524288",
                "LimitNOFILESoft": "1024",
                "LimitNPROC": "7606",
                "LimitNPROCSoft": "7606",
                "LimitRSS": "infinity",
                "LimitRSSSoft": "infinity",
                "LimitRTPRIO": "0",
                "LimitRTPRIOSoft": "0",
                "LimitRTTIME": "infinity",
                "LimitRTTIMESoft": "infinity",
                "LimitSIGPENDING": "7606",
                "LimitSIGPENDINGSoft": "7606",
                "LimitSTACK": "infinity",
                "LimitSTACKSoft": "8388608",
                "LoadState": "loaded",
                "LockPersonality": "no",
                "LogLevelMax": "-1",
                "LogRateLimitBurst": "0",
                "LogRateLimitIntervalUSec": "0",
                "LogsDirectoryMode": "0755",
                "MainPID": "168715",
                "MemoryAccounting": "yes",
                "MemoryCurrent": "3080192",
                "MemoryDenyWriteExecute": "no",
                "MemoryHigh": "infinity",
                "MemoryLimit": "infinity",
                "MemoryLow": "0",
                "MemoryMax": "infinity",
                "MemoryMin": "0",
                "MemorySwapMax": "infinity",
                "MountAPIVFS": "no",
                "MountFlags": "",
                "NFileDescriptorStore": "0",
                "NRestarts": "0",
                "NUMAMask": "",
                "NUMAPolicy": "n/a",
                "Names": "nginx.service",
                "NeedDaemonReload": "no",
                "Nice": "0",
                "NoNewPrivileges": "no",
                "NonBlocking": "no",
                "NotifyAccess": "none",
                "OOMPolicy": "stop",
                "OOMScoreAdjust": "0",
                "OnFailureJobMode": "replace",
                "PIDFile": "/run/nginx.pid",
                "Perpetual": "no",
                "PrivateDevices": "no",
                "PrivateMounts": "no",
                "PrivateNetwork": "no",
                "PrivateTmp": "no",
                "PrivateUsers": "no",
                "ProtectControlGroups": "no",
                "ProtectHome": "no",
                "ProtectHostname": "no",
                "ProtectKernelLogs": "no",
                "ProtectKernelModules": "no",
                "ProtectKernelTunables": "no",
                "ProtectSystem": "no",
                "RefuseManualStart": "no",
                "RefuseManualStop": "no",
                "ReloadResult": "success",
                "RemainAfterExit": "no",
                "RemoveIPC": "no",
                "Requires": "system.slice sysinit.target",
                "Restart": "no",
                "RestartKillSignal": "15",
                "RestartUSec": "100ms",
                "RestrictNamespaces": "no",
                "RestrictRealtime": "no",
                "RestrictSUIDSGID": "no",
                "Result": "success",
                "RootDirectoryStartOnly": "no",
                "RuntimeDirectoryMode": "0755",
                "RuntimeDirectoryPreserve": "no",
                "RuntimeMaxUSec": "infinity",
                "SameProcessGroup": "no",
                "SecureBits": "0",
                "SendSIGHUP": "no",
                "SendSIGKILL": "yes",
                "Slice": "system.slice",
                "StandardError": "inherit",
                "StandardInput": "null",
                "StandardInputData": "",
                "StandardOutput": "journal",
                "StartLimitAction": "none",
                "StartLimitBurst": "5",
                "StartLimitIntervalUSec": "10s",
                "StartupBlockIOWeight": "[not set]",
                "StartupCPUShares": "[not set]",
                "StartupCPUWeight": "[not set]",
                "StartupIOWeight": "[not set]",
                "StateChangeTimestamp": "Mon 2022-10-03 13:38:38 UTC",
                "StateChangeTimestampMonotonic": "1653327603774",
                "StateDirectoryMode": "0755",
                "StatusErrno": "0",
                "StopWhenUnneeded": "no",
                "SubState": "running",
                "SuccessAction": "none",
                "SyslogFacility": "3",
                "SyslogLevel": "6",
                "SyslogLevelPrefix": "yes",
                "SyslogPriority": "30",
                "SystemCallErrorNumber": "0",
                "TTYReset": "no",
                "TTYVHangup": "no",
                "TTYVTDisallocate": "no",
                "TasksAccounting": "yes",
                "TasksCurrent": "2",
                "TasksMax": "2281",
                "TimeoutAbortUSec": "5s",
                "TimeoutCleanUSec": "infinity",
                "TimeoutStartUSec": "1min 30s",
                "TimeoutStopUSec": "5s",
                "TimerSlackNSec": "50000",
                "Transient": "no",
                "Type": "forking",
                "UID": "[not set]",
                "UMask": "0022",
                "UnitFilePreset": "enabled",
                "UnitFileState": "enabled",
                "UtmpMode": "init",
                "WantedBy": "multi-user.target",
                "WatchdogSignal": "6",
                "WatchdogTimestampMonotonic": "0",
                "WatchdogUSec": "0"
        }
}
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml

PLAY [install apache]


****************************************************************

TASK [Gathering Facts]


***************************************************************
ok: [client1]

TASK [apache : install apache]


*******************************************************
ok: [client1]

TASK [apache : copy index]


***********************************************************
ok: [client1]

PLAY RECAP
***************************************************************************
client1                                        : ok=3      changed=0       
unreachable=0        failed=0        skipped                                         
=0        rescued=0        ignored=0

ansadmin@svl200:~/projet1$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet1$ sudo vim hosts.yml
ansadmin@svl200:~/projet1$ curl client1
curl: (7) Failed to connect to client1 port 80: Connection refused
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ cd roles/
ansadmin@svl200:~/projet1/roles$ ls
apache
ansadmin@svl200:~/projet1/roles$ cp -r apache users
ansadmin@svl200:~/projet1/roles$
ansadmin@svl200:~/projet1/roles$ ls
apache    users
ansadmin@svl200:~/projet1/roles$ cd users
ansadmin@svl200:~/projet1/roles/users$ ls -lrt
total 16
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 13:16 vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 13:16 templates
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 13:16 tasks
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 13:16 handlers
ansadmin@svl200:~/projet1/roles/users$ tree
.
├── handlers
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
│   └── index.html.j2
└── vars
        └── main.yml

4 directories, 4 files
ansadmin@svl200:~/projet1/roles/users$ cd ..
ansadmin@svl200:~/projet1/roles$ tree
.
├── apache
│   ├── handlers
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   │   └── index.html.j2
│   └── vars
│            └── main.yml
└── users
        ├── handlers
        │   └── main.yml
        ├── tasks
        │   └── main.yml
        ├── templates
        │   └── index.html.j2
        └── vars
                └── main.yml

10 directories, 8 files
ansadmin@svl200:~/projet1/roles$
ansadmin@svl200:~/projet1/roles$ ll
total 16
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    5 13:16 ./
drwxrwxr-x 5 ansadmin ansadmin 4096 Oct    5 13:14 ../
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    5 12:15 apache/
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    5 13:16 users/
ansadmin@svl200:~/projet1/roles$ cd users/
ansadmin@svl200:~/projet1/roles/users$ ls
handlers    tasks    templates    vars
ansadmin@svl200:~/projet1/roles/users$
ansadmin@svl200:~/projet1/roles/users$ ls -lrt
total 16
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 13:16 vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 13:16 templates
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 13:16 tasks
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 13:16 handlers
ansadmin@svl200:~/projet1/roles/users$ sudo vim vars/main.yml
ansadmin@svl200:~/projet1/roles/users$ sudo vim templates/index.html.j2
ansadmin@svl200:~/projet1/roles/users$ sudo vim tasks/main.yml
ansadmin@svl200:~/projet1/roles/users$ cd
ansadmin@svl200:~$ ls
cible1.txt      exo4.yaml          index.html              items_users.yaml    projet
template.yaml              vars2.yml
copie.yaml      fact.yaml          index.html.j2        list.yaml                 
projet1        template1.yaml            vars_multi.yml
debug.yaml      fact1.yaml        index.html1.j2      locale.yml               
rep.yaml      var_dic.yml                  when.yaml
debug1.yaml    handler.yaml    ip.txt                      nginx.yaml               
seq.yaml      var_dic2.yml                when1.yaml
exo2.yaml        hello.yaml        item_users.yaml    play-vars.yaml        shell.yml
var_dic_multi3.yml
exo3.yaml        hello.yml          items.yaml              play-vars.yml         
snap              vars.yml
ansadmin@svl200:~$ sudo vim item_users.yaml
ansadmin@svl200:~$ cd projet1/roles/users/
ansadmin@svl200:~/projet1/roles/users$ sudo vim tasks/main.yml
ansadmin@svl200:~/projet1/roles/users$
ansadmin@svl200:~/projet1/roles/users$ tree
.
├── handlers
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
│   └── index.html.j2
└── vars
        └── main.yml

4 directories, 4 files
ansadmin@svl200:~/projet1/roles/users$ sudo vim vars/main.yml
ansadmin@svl200:~/projet1/roles/users$ cd ..
ansadmin@svl200:~/projet1/roles$ cd ..
ansadmin@svl200:~/projet1$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   ├── apache
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── tasks
│   │   │   └── main.yml
│   │   ├── templates
│   │   │   └── index.html.j2
│   │   └── vars
│   │            └── main.yml
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

13 directories, 11 files
ansadmin@svl200:~/projet1$ cd roles/
ansadmin@svl200:~/projet1/roles$ cd users/
ansadmin@svl200:~/projet1/roles/users$ sudo vim vars/main.yml
ansadmin@svl200:~/projet1/roles/users$
ansadmin@svl200:~/projet1/roles/users$ cd
ansadmin@svl200:~$ ls
cible1.txt      exo4.yaml          index.html              items_users.yaml    projet
template.yaml              vars2.yml
copie.yaml      fact.yaml          index.html.j2        list.yaml                 
projet1        template1.yaml            vars_multi.yml
debug.yaml      fact1.yaml        index.html1.j2      locale.yml               
rep.yaml      var_dic.yml                  when.yaml
debug1.yaml    handler.yaml    ip.txt                      nginx.yaml               
seq.yaml      var_dic2.yml                when1.yaml
exo2.yaml        hello.yaml        item_users.yaml    play-vars.yaml        shell.yml
var_dic_multi3.yml
exo3.yaml        hello.yml          items.yaml              play-vars.yml         
snap              vars.yml
ansadmin@svl200:~$ cd projet
ansadmin@svl200:~/projet$ ls
group_vars    host_vars    install.yaml    inventory.yaml    vars_install.yaml
ansadmin@svl200:~/projet$ sudo vim vars_install.yaml
ansadmin@svl200:~/projet$
ansadmin@svl200:~/projet$ cd
ansadmin@svl200:~$ cd projet1/
group_vars/ hosts_vars/ roles/
ansadmin@svl200:~$ cd projet1/roles/
apache/ users/
ansadmin@svl200:~$ cd projet1/roles/users/
handlers/    tasks/          templates/ vars/
ansadmin@svl200:~$ cd projet1/roles/users/vars/
ansadmin@svl200:~/projet1/roles/users/vars$ sudo vim vars/main.yml
ansadmin@svl200:~/projet1/roles/users/vars$ sudo main.yml
sudo: main.yml: command not found
ansadmin@svl200:~/projet1/roles/users/vars$ sudo vim main.yml
ansadmin@svl200:~/projet1/roles/users/vars$ cd ..
ansadmin@svl200:~/projet1/roles/users$ ansible-playbook -i hosts.yml site.yml
ERROR! the playbook: site.yml could not be found
ansadmin@svl200:~/projet1/roles/users$ cd ..
ansadmin@svl200:~/projet1/roles$ cd ..
ansadmin@svl200:~/projet1$ ansible-playbook -i hosts.yml site.yml

PLAY [install apache]


*************************************************************************************
**

TASK [Gathering Facts]


*************************************************************************************
*
ok: [client1]

TASK [apache : install apache]


******************************************************************************
ok: [client1]

TASK [apache : copy index]


**********************************************************************************
ok: [client1]

PLAY RECAP
*************************************************************************************
*************
client1                                        : ok=3      changed=0       
unreachable=0        failed=0        skipped=0        rescued=0        igno         
red=0

ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ cd roles/
ansadmin@svl200:~/projet1/roles$ ansible-playbook -i hosts.yml site.yml
ERROR! the playbook: site.yml could not be found
ansadmin@svl200:~/projet1/roles$
ansadmin@svl200:~/projet1/roles$ ls
apache    users
ansadmin@svl200:~/projet1/roles$ mv users /home/ansadmin/
ansadmin@svl200:~/projet1/roles$ cd
ansadmin@svl200:~$ ls
cible1.txt      exo4.yaml          index.html              items_users.yaml    projet
template.yaml              vars.yml
copie.yaml      fact.yaml          index.html.j2        list.yaml                 
projet1        template1.yaml            vars2.yml
debug.yaml      fact1.yaml        index.html1.j2      locale.yml               
rep.yaml      users                              vars_multi.yml
debug1.yaml    handler.yaml    ip.txt                      nginx.yaml               
seq.yaml      var_dic.yml                  when.yaml
exo2.yaml        hello.yaml        item_users.yaml    play-vars.yaml        shell.yml
var_dic2.yml                when1.yaml
exo3.yaml        hello.yml          items.yaml              play-vars.yml         
snap              var_dic_multi3.yml
ansadmin@svl200:~$ mv users projet2
ansadmin@svl200:~$
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ ls
handlers    tasks    templates    vars
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ tree
.
├── handlers
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
│   └── index.html.j2
└── vars
        └── main.yml

4 directories, 4 files
ansadmin@svl200:~/projet2$ mkdir roles
ansadmin@svl200:~/projet2$ cd ..
ansadmin@svl200:~$ ls
cible1.txt      exo4.yaml          index.html              items_users.yaml    projet
snap                                vars.yml
copie.yaml      fact.yaml          index.html.j2        list.yaml                 
projet1        template.yaml              vars2.yml
debug.yaml      fact1.yaml        index.html1.j2      locale.yml               
projet2        template1.yaml            vars_multi.yml
debug1.yaml    handler.yaml    ip.txt                      nginx.yaml               
rep.yaml      var_dic.yml                  when.yaml
exo2.yaml        hello.yaml        item_users.yaml    play-vars.yaml        seq.yaml 
var_dic2.yml                when1.yaml
exo3.yaml        hello.yml          items.yaml              play-vars.yml         
shell.yml    var_dic_multi3.yml
ansadmin@svl200:~$ cd projet
projet/    projet1/ projet2/
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ ls
handlers    roles    tasks    templates    vars
ansadmin@svl200:~/projet2$ mv handlers tasks templates vars roles/
ansadmin@svl200:~/projet2$ ls
roles
ansadmin@svl200:~/projet2$ cd roles/
ansadmin@svl200:~/projet2/roles$ ls
handlers    tasks    templates    vars
ansadmin@svl200:~/projet2/roles$ mkdir user
ansadmin@svl200:~/projet2/roles$ ls
handlers    tasks    templates    user    vars
ansadmin@svl200:~/projet2/roles$ mv handlers tasks templates vars user/
ansadmin@svl200:~/projet2/roles$ cd user/
handlers/    tasks/          templates/ vars/
ansadmin@svl200:~/projet2/roles$ cd ..
ansadmin@svl200:~/projet2$ tree
.
└── roles
        └── user
                ├── handlers
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                └── vars
                        └── main.yml

6 directories, 4 files
ansadmin@svl200:~/projet2$ sudo vim roles/user/handlers/main.yml
ansadmin@svl200:~/projet2$ cd
ansadmin@svl200:~$ cd projet1/
ansadmin@svl200:~/projet1$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/projet1$ cp group_vars hosts_vars hosts.yml site.yml ../projet
projet/    projet1/ projet2/
ansadmin@svl200:~/projet1$ cp group_vars hosts_vars hosts.yml site.yml ../projet2
cp: -r not specified; omitting directory 'group_vars'
cp: -r not specified; omitting directory 'hosts_vars'
ansadmin@svl200:~/projet1$ cp -r group_vars hosts_vars hosts.yml site.yml ../projet2
ansadmin@svl200:~/projet1$ cd ..
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── user
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! the role 'apache' was not found in
/home/ansadmin/projet2/roles:/home/ansadmin/.ansible/roles:/usr/sha                 
re/ansible/roles:/etc/ansible/roles:/home/ansadmin/projet2

The error appears to be in '/home/ansadmin/projet2/site.yml': line 6, column 10, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    roles:
              - apache
                  ^ here
ansadmin@svl200:~/projet2$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── user
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet2$ sudo vim site.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


3, column 9, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


- name: creation d'utilisateurs
        user:
                ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


3, column 9, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: creation d'utilisateurs


        user:
                ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ cd
ansadmin@svl200:~$ ls
cible1.txt      exo4.yaml          index.html              items_users.yaml    projet
snap                                vars.yml
copie.yaml      fact.yaml          index.html.j2        list.yaml                 
projet1        template.yaml              vars2.yml
debug.yaml      fact1.yaml        index.html1.j2      locale.yml               
projet2        template1.yaml            vars_multi.yml
debug1.yaml    handler.yaml    ip.txt                      nginx.yaml               
rep.yaml      var_dic.yml                  when.yaml
exo2.yaml        hello.yaml        item_users.yaml    play-vars.yaml        seq.yaml 
var_dic2.yml                when1.yaml
exo3.yaml        hello.yml          items.yaml              play-vars.yml         
shell.yml    var_dic_multi3.yml
ansadmin@svl200:~$ sudo vim var_dic_multi3.yml
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


3, column 9, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: creation d'utilisateurs


        user:
                ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── user
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet2$ sudo vim roles/user/vars/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


3, column 9, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: creation d'utilisateurs


        user:
                ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


3, column 9, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: creation d'utilisateurs


        user:
                ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


3, column 9, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: creation d'utilisateurs


        user:
                ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


3, column 9, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: creation d'utilisateurs


        user:
                ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from
/home/ansadmin/projet2/roles/user/tasks/main.yml, line 8,
column 3, found a duplicate dict key (when). Using last defined value only.
[WARNING]: While constructing a mapping from
/home/ansadmin/projet2/roles/user/tasks/main.yml, line 10,
column 4, found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from
/home/ansadmin/projet2/roles/user/tasks/main.yml, line 10,
column 4, found a duplicate dict key (state). Using last defined value only.
[WARNING]: While constructing a mapping from
/home/ansadmin/projet2/roles/user/tasks/main.yml, line 19,
column 4, found a duplicate dict key (name). Using last defined value only.
[WARNING]: While constructing a mapping from
/home/ansadmin/projet2/roles/user/tasks/main.yml, line 19,
column 4, found a duplicate dict key (state). Using last defined value only.
ERROR! conflicting action statements: apt, yum

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


8, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: installation packages


    ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


9, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


- name: installation packages
      apt:
            ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


9, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: installation packages


      apt:
            ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


9, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: installation packages


      apt:
            ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── user
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet2$ sudo vim site.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/user/tasks/main.yml': line


9, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: installation packages


      apt:
            ^ here
ansadmin@svl200:~/projet2$ sudo vim hosts.yml
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── user
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet2$ cd roles
ansadmin@svl200:~/projet2/roles$ mv user/ users/
ansadmin@svl200:~/projet2/roles$
ansadmin@svl200:~/projet2/roles$ cd ..
ansadmin@svl200:~/projet2$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml
8 directories, 7 files
ansadmin@svl200:~/projet2$ sudo vim site.yml
ansadmin@svl200:~/projet2$ sudo vim roles/user/tasks/main.yml
ansadmin@svl200:~/projet2$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/projet2$ sudo vim roles/users/templates/index.html.j2
ansadmin@svl200:~/projet2$ sudo vim hosts.yml
ansadmin@svl200:~/projet2$ sudo vim site.yml
ansadmin@svl200:~/projet2$ sudo vim roles/users/vars/main.yml
*ansadmin@svl200:~/projet2$ansible-playbook -i hosts.yml site.yml
usage: ansible-playbook [-h] [--version] [-v] [-k] [--private-key PRIVATE_KEY_FILE]
[-u REMOTE_USER]
                                                [-c CONNECTION] [-T TIMEOUT] [--ssh-
common-args SSH_COMMON_ARGS]
                                                [--sftp-extra-args SFTP_EXTRA_ARGS]
[--scp-extra-args SCP_EXTRA_ARGS]
                                                [--ssh-extra-args SSH_EXTRA_ARGS] [--
force-handlers] [--flush-cache] [-b]
                                                [--become-method BECOME_METHOD] [--
become-user BECOME_USER] [-K] [-t TAGS]
                                                [--skip-tags SKIP_TAGS] [-C] [--
syntax-check] [-D] [-i INVENTORY] [--list-hosts]
                                                [-l SUBSET] [-e EXTRA_VARS] [--vault-
id VAULT_IDS]
                                                [--ask-vault-pass | --vault-password-
file VAULT_PASSWORD_FILES] [-f FORKS]
                                                [-M MODULE_PATH] [--list-tasks] [--
list-tags] [--step]
                                                [--start-at-task START_AT_TASK]
                                                playbook [playbook ...]
ansible-playbook: error: the following arguments are required: playbook
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.ymlsite.yml
usage: ansible-playbook [-h] [--version] [-v] [-k] [--private-key PRIVATE_KEY_FILE]
[-u REMOTE_USER]
                                                [-c CONNECTION] [-T TIMEOUT] [--ssh-
common-args SSH_COMMON_ARGS]
                                                [--sftp-extra-args SFTP_EXTRA_ARGS]
[--scp-extra-args SCP_EXTRA_ARGS]
                                                [--ssh-extra-args SSH_EXTRA_ARGS] [--
force-handlers] [--flush-cache] [-b]
                                                [--become-method BECOME_METHOD] [--
become-user BECOME_USER] [-K] [-t TAGS]
                                                [--skip-tags SKIP_TAGS] [-C] [--
syntax-check] [-D] [-i INVENTORY] [--list-hosts]
                                                [-l SUBSET] [-e EXTRA_VARS] [--vault-
id VAULT_IDS]
                                                [--ask-vault-pass | --vault-password-
file VAULT_PASSWORD_FILES] [-f FORKS]
                                                [-M MODULE_PATH] [--list-tasks] [--
list-tags] [--step]
                                                [--start-at-task START_AT_TASK]
                                                playbook [playbook ...]
ansible-playbook: error: the following arguments are required: playbook
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet2/hosts.yml, line
3, column 7, found a
duplicate dict key (cible1). Using last defined value only.
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/users/tasks/main.yml': line


9, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: installation packages


      apt:
            ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet2/hosts.yml, line
3, column 7, found a
duplicate dict key (cible1). Using last defined value only.
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/projet2/roles/users/tasks/main.yml': line


9, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: installation packages


      apt:
            ^ here
ansadmin@svl200:~/projet2$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet2/hosts.yml, line
3, column 7, found a
duplicate dict key (cible1). Using last defined value only.

PLAY [install apache]


*************************************************************************************
**

TASK [Gathering Facts]


*************************************************************************************
*
The authenticity of host '[client2]:55600 ([141.95.160.133]:55600)' can't be
established.
ECDSA key fingerprint is SHA256:XtY+kTiWN4Ohe3xBY3YAQ9YLSSuP7bbmxZjN/R9SBcs.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
ok: [client2]

TASK [users : creation d'utilisateurs]


**********************************************************************
changed: [client2] => (item=1)
changed: [client2] => (item=2)
changed: [client2] => (item=3)
changed: [client2] => (item=4)
changed: [client2] => (item=5)

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
changed: [client2] => (item=['tree', 'curl', 'zip'])

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "yum" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
fatal: [client2]: FAILED! => {"msg": "The conditional check 'distribution
== \"Centos\"' failed. The error wa                                                 
s: error while evaluating conditional (distribution == \"Centos\"): 'distribution' is
undefined\n\nThe error                                                              
appears to be in '/home/ansadmin/projet2/roles/users/tasks/main.yml': line 15, column
3, but may\nbe elsewher                                                             
e in the file depending on the exact syntax problem.\n\nThe offending line appears to
be:\n\n\n- name: instal                                                             
lation packages\n    ^ here\n"}

PLAY RECAP
*************************************************************************************
*************
client2                                        : ok=3      changed=2     
unreachable=0        failed=1      skipped=0        rescued=0        igno           
red=0

ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet2/hosts.yml, line
3, column 7, found a
duplicate dict key (cible1). Using last defined value only.

PLAY [install apache]


*************************************************************************************
**

TASK [Gathering Facts]


*************************************************************************************
*
ok: [client2]

TASK [users : creation d'utilisateurs]


**********************************************************************
ok: [client2] => (item=1)
ok: [client2] => (item=2)
ok: [client2] => (item=3)
ok: [client2] => (item=4)
ok: [client2] => (item=5)

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [client2] => (item=['tree', 'curl', 'zip'])

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "yum" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
fatal: [client2]: FAILED! => {"msg": "The conditional check 'distribution
== \"Centos\"' failed. The error wa                                                 
s: error while evaluating conditional (distribution == \"Centos\"): 'distribution' is
undefined\n\nThe error                                                              
appears to be in '/home/ansadmin/projet2/roles/users/tasks/main.yml': line 15, column
3, but may\nbe elsewher                                                             
e in the file depending on the exact syntax problem.\n\nThe offending line appears to
be:\n\n\n- name: instal                                                             
lation packages\n    ^ here\n"}

PLAY RECAP
*************************************************************************************
*************
client2                                        : ok=3      changed=0       
unreachable=0        failed=1      skipped=0        rescued=0        igno           
red=0

ansadmin@svl200:~/projet2$ sudo vim roles/users/vars/main.yml


ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ sudo vim roles/users/templates/index.html.j2
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet2/hosts.yml, line
3, column 7, found a
duplicate dict key (cible1). Using last defined value only.

PLAY [install apache]


*************************************************************************************
**

TASK [Gathering Facts]


*************************************************************************************
*
ok: [client2]

TASK [users : creation d'utilisateurs]


**********************************************************************
ok: [client2] => (item=1)
ok: [client2] => (item=2)
ok: [client2] => (item=3)
ok: [client2] => (item=4)
ok: [client2] => (item=5)

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [client2] => (item=['tree', 'curl', 'zip'])

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "yum" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
fatal: [client2]: FAILED! => {"msg": "The conditional check 'distribution
== \"Centos\"' failed. The error wa                                                 
s: error while evaluating conditional (distribution == \"Centos\"): 'distribution' is
undefined\n\nThe error                                                              
appears to be in '/home/ansadmin/projet2/roles/users/tasks/main.yml': line 15, column
3, but may\nbe elsewher                                                             
e in the file depending on the exact syntax problem.\n\nThe offending line appears to
be:\n\n\n- name: instal                                                             
lation packages\n    ^ here\n"}

PLAY RECAP
*************************************************************************************
*************
client2                                        : ok=3      changed=0       
unreachable=0        failed=1      skipped=0        rescued=0        igno           
red=0

ansadmin@svl200:~/projet2$ sudo vim roles/users/tasks/main.yml


ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet2/hosts.yml, line
3, column 7, found a
duplicate dict key (cible1). Using last defined value only.

PLAY [install apache]


*************************************************************************************
**

TASK [Gathering Facts]


*************************************************************************************
*
ok: [client2]

TASK [users : creation d'utilisateurs]


**********************************************************************
ok: [client2] => (item=1)
ok: [client2] => (item=2)
ok: [client2] => (item=3)
ok: [client2] => (item=4)
ok: [client2] => (item=5)

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [client2] => (item=['tree', 'curl', 'zip'])

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "yum" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
fatal: [client2]: FAILED! => {"msg": "The conditional check 'distribution
== \"Ubuntu\"' failed. The error wa                                                 
s: error while evaluating conditional (distribution == \"Ubuntu\"): 'distribution' is
undefined\n\nThe error                                                              
appears to be in '/home/ansadmin/projet2/roles/users/tasks/main.yml': line 15, column
3, but may\nbe elsewher                                                             
e in the file depending on the exact syntax problem.\n\nThe offending line appears to
be:\n\n\n- name: instal                                                             
lation packages\n    ^ here\n"}

PLAY RECAP
*************************************************************************************
*************
client2                                        : ok=3      changed=0       
unreachable=0        failed=1      skipped=0        rescued=0        igno           
red=0

ansadmin@svl200:~/projet2$ sudo vim roles/users/tasks/main.yml


ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet2/hosts.yml, line
3, column 7, found a
duplicate dict key (cible1). Using last defined value only.

PLAY [install apache]


*************************************************************************************
**

TASK [Gathering Facts]


*************************************************************************************
*
ok: [client2]

TASK [users : creation d'utilisateurs]


**********************************************************************
ok: [client2] => (item=1)
ok: [client2] => (item=2)
ok: [client2] => (item=3)
ok: [client2] => (item=4)
ok: [client2] => (item=5)

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [client2] => (item=['tree', 'curl', 'zip'])

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "yum" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
fatal: [client2]: FAILED! => {"msg": "The conditional check 'dnsible_distribution
== \"Centos\"' failed. The                                                          
error was: error while evaluating conditional (dnsible_distribution == \"Centos\"):
'dnsible_distribution' is                                                           
undefined\n\nThe error appears to be in
'/home/ansadmin/projet2/roles/users/tasks/main.yml': line 15, column                 
3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe
offending line appears to                                                           
be:\n\n\n- name: installation packages\n    ^ here\n"}

PLAY RECAP
*************************************************************************************
*************
client2                                        : ok=3      changed=0       
unreachable=0        failed=1      skipped=0        rescued=0        igno           
red=0

ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/projet2$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet2/hosts.yml, line
3, column 7, found a
duplicate dict key (cible1). Using last defined value only.

PLAY [install apache]


*************************************************************************************
**

TASK [Gathering Facts]


*************************************************************************************
*
ok: [client2]

TASK [users : creation d'utilisateurs]


**********************************************************************
ok: [client2] => (item=1)
ok: [client2] => (item=2)
ok: [client2] => (item=3)
ok: [client2] => (item=4)
ok: [client2] => (item=5)

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [client2] => (item=['tree', 'curl', 'zip'])

TASK [users : installation packages]


************************************************************************
[DEPRECATION WARNING]: Invoking "yum" only once while using a loop via squash_actions
is deprecated. Instead
of using a loop to supply multiple items and specifying `name: "{{item}}"`, please
use `name:
'{{packages}}'` and remove the loop. This feature will be removed in version 2.11.
Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
skipping: [client2] => (item=[])

TASK [users : copy index]


***********************************************************************************
changed: [client2]

RUNNING HANDLER [users : restart_apache]


********************************************************************
changed: [client2]

PLAY RECAP
*************************************************************************************
*************
client2                                        : ok=5      changed=2     
unreachable=0        failed=0        skipped=1      rescued=0        igno           
red=0

ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ cd
ansadmin@svl200:~$ ansible-galaxy init projet
projet/    projet1/ projet2/
ansadmin@svl200:~$ ansible-galaxy init projet3
- Role projet3 was created successfully
ansadmin@svl200:~$ cd projet3
ansadmin@svl200:~/projet3$ tree
.
├── README.md
├── defaults
│   └── main.yml
├── files
├── handlers
│   └── main.yml
├── meta
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
        └── main.yml

8 directories, 8 files
ansadmin@svl200:~/projet3$
ansadmin@svl200:~/projet3$ cd
ansadmin@svl200:~$ ansible-galaxy install projet3 geerlingguy.apache
- downloading role 'projet3', owned by
[WARNING]: - projet3 was NOT installed successfully: None (HTTP Code: 400, Message:
Bad Request)
ERROR! - you can use --ignore-errors to skip failed roles and finish processing the
list.
ansadmin@svl200:~$ ansible-galaxy install geerlingguy.apache
- downloading role 'apache', owned by geerlingguy
- downloading role from
https://github.com/geerlingguy/ansible-role-apache/archive/3.3.0.tar.gz
- extracting geerlingguy.apache to /home/ansadmin/.ansible/roles/geerlingguy.apache
- geerlingguy.apache (3.3.0) was installed successfully
ansadmin@svl200:~$ mkdir projet4
ansadmin@svl200:~$ ansible-galaxy install geerlingguy.apache -p projet4
- downloading role 'apache', owned by geerlingguy
- downloading role from
https://github.com/geerlingguy/ansible-role-apache/archive/3.3.0.tar.gz
- extracting geerlingguy.apache to /home/ansadmin/projet4/geerlingguy.apache
- geerlingguy.apache (3.3.0) was installed successfully
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ tree
.
└── geerlingguy.apache
        ├── LICENSE
        ├── README.md
        ├── defaults
        │   └── main.yml
        ├── handlers
        │   └── main.yml
        ├── meta
        │   └── main.yml
        ├── molecule
        │   └── default
        │            ├── converge.yml
        │            └── molecule.yml
        ├── tasks
        │   ├── configure-Debian.yml
        │   ├── configure-RedHat.yml
        │   ├── configure-Solaris.yml
        │   ├── configure-Suse.yml
        │   ├── main.yml
        │   ├── setup-Debian.yml
        │   ├── setup-RedHat.yml
        │   ├── setup-Solaris.yml
        │   └── setup-Suse.yml
        ├── templates
        │   └── vhosts.conf.j2
        └── vars
                ├── AmazonLinux.yml
                ├── Debian.yml
                ├── RedHat.yml
                ├── Solaris.yml
                ├── Suse.yml
                ├── apache-22.yml
                └── apache-24.yml

9 directories, 24 files
ansadmin@svl200:~/projet4$
ansadmin@svl200:~/projet4$ cd geerlingguy.apache/
.github/      defaults/    handlers/    meta/            molecule/    tasks/         
templates/ vars/
ansadmin@svl200:~/projet4$ cd geerlingguy.apache
ansadmin@svl200:~/projet4/geerlingguy.apache$ ls -lrt
total 44
-rw-rw-r-- 1 ansadmin ansadmin 8359 May 23 05:41 README.md
-rw-rw-r-- 1 ansadmin ansadmin 1080 May 23 05:41 LICENSE
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    5 14:52 molecule
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 14:52 handlers
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 14:52 defaults
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 14:52 vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 14:52 templates
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 14:52 tasks
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    5 14:52 meta
ansadmin@svl200:~/projet4/geerlingguy.apache$ cd tasks/
ansadmin@svl200:~/projet4/geerlingguy.apache/tasks$ ls
configure-Debian.yml    configure-Solaris.yml    main.yml                    setup-
RedHat.yml      setup-Suse.yml
configure-RedHat.yml    configure-Suse.yml          setup-Debian.yml    setup-
Solaris.yml
ansadmin@svl200:~/projet4/geerlingguy.apache/tasks$ sudo vim main.yml
ansadmin@svl200:~/projet4/geerlingguy.apache/tasks$ sudo vim main.yml
ansadmin@svl200:~/projet4/geerlingguy.apache/tasks$ cd ..
ansadmin@svl200:~/projet4/geerlingguy.apache$ cd ..
ansadmin@svl200:~/projet4$ tree
.
└── geerlingguy.apache
        ├── LICENSE
        ├── README.md
        ├── defaults
        │   └── main.yml
        ├── handlers
        │   └── main.yml
        ├── meta
        │   └── main.yml
        ├── molecule
        │   └── default
        │            ├── converge.yml
        │            └── molecule.yml
        ├── tasks
        │   ├── configure-Debian.yml
        │   ├── configure-RedHat.yml
        │   ├── configure-Solaris.yml
        │   ├── configure-Suse.yml
        │   ├── main.yml
        │   ├── setup-Debian.yml
        │   ├── setup-RedHat.yml
        │   ├── setup-Solaris.yml
        │   └── setup-Suse.yml
        ├── templates
        │   └── vhosts.conf.j2
        └── vars
                ├── AmazonLinux.yml
                ├── Debian.yml
                ├── RedHat.yml
                ├── Solaris.yml
                ├── Suse.yml
                ├── apache-22.yml
                └── apache-24.yml

9 directories, 24 files
ansadmin@svl200:~/projet4$ cd
ansadmin@svl200:~$ tree
.
├── cible1.txt
├── copie.yaml
├── debug.yaml
├── debug1.yaml
├── exo2.yaml
├── exo3.yaml
├── exo4.yaml
├── fact.yaml
├── fact1.yaml
├── handler.yaml
├── hello.yaml
├── hello.yml
├── index.html
├── index.html.j2
├── index.html1.j2
├── ip.txt
├── item_users.yaml
├── items.yaml
├── items_users.yaml
├── list.yaml
├── locale.yml
├── nginx.yaml
├── play-vars.yaml
├── play-vars.yml
├── projet
│   ├── group_vars
│   │   ├── cible1.yaml
│   │   └── cible2.yaml
│   ├── host_vars
│   │   ├── client1.yaml
│   │   └── client2.yaml
│   ├── install.yaml
│   ├── inventory.yaml
│   └── vars_install.yaml
├── projet1
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   ├── roles
│   │   └── apache
│   │            ├── handlers
│   │            │   └── main.yml
│   │            ├── tasks
│   │            │   └── main.yml
│   │            ├── templates
│   │            │   └── index.html.j2
│   │            └── vars
│   │                    └── main.yml
│   └── site.yml
├── projet2
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   ├── roles
│   │   └── users
│   │            ├── handlers
│   │            │   └── main.yml
│   │            ├── tasks
│   │            │   └── main.yml
│   │            ├── templates
│   │            │   └── index.html.j2
│   │            └── vars
│   │                    └── main.yml
│   └── site.yml
├── projet3
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
├── projet4
│   └── geerlingguy.apache
│            ├── LICENSE
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── handlers
│            │   └── main.yml
│            ├── meta
│            │   └── main.yml
│            ├── molecule
│            │   └── default
│            │            ├── converge.yml
│            │            └── molecule.yml
│            ├── tasks
│            │   ├── configure-Debian.yml
│            │   ├── configure-RedHat.yml
│            │   ├── configure-Solaris.yml
│            │   ├── configure-Suse.yml
│            │   ├── main.yml
│            │   ├── setup-Debian.yml
│            │   ├── setup-RedHat.yml
│            │   ├── setup-Solaris.yml
│            │   └── setup-Suse.yml
│            ├── templates
│            │   └── vhosts.conf.j2
│            └── vars
│                    ├── AmazonLinux.yml
│                    ├── Debian.yml
│                    ├── RedHat.yml
│                    ├── Solaris.yml
│                    ├── Suse.yml
│                    ├── apache-22.yml
│                    └── apache-24.yml
├── rep.yaml
├── seq.yaml
├── shell.yml
├── snap
│   └── tree
│            ├── 18
│            ├── common
│            └── current -> 18
├── template.yaml
├── template1.yaml
├── var_dic.yml
├── var_dic2.yml
├── var_dic_multi3.yml
├── vars.yml
├── vars2.yml
├── vars_multi.yml
├── when.yaml
└── when1.yaml

45 directories, 90 files
ansadmin@svl200:~$ ansible-playbook -i projet4
usage: ansible-playbook [-h] [--version] [-v] [-k] [--private-key PRIVATE_KEY_FILE]
                                                [-u REMOTE_USER] [-c CONNECTION] [-T
TIMEOUT]
                                                [--ssh-common-args SSH_COMMON_ARGS]
[--sftp-extra-args SFTP_EXTRA_ARGS]
                                                [--scp-extra-args SCP_EXTRA_ARGS] [--
ssh-extra-args SSH_EXTRA_ARGS]
                                                [--force-handlers] [--flush-cache] [-
b] [--become-method BECOME_METHOD]
                                                [--become-user BECOME_USER] [-K] [-t
TAGS] [--skip-tags SKIP_TAGS] [-C]
                                                [--syntax-check] [-D] [-i INVENTORY]
[--list-hosts] [-l SUBSET]
                                                [-e EXTRA_VARS] [--vault-id
VAULT_IDS]
                                                [--ask-vault-pass | --vault-password-
file VAULT_PASSWORD_FILES] [-f FORKS]
                                                [-M MODULE_PATH] [--list-tasks] [--
list-tags] [--step]
                                                [--start-at-task START_AT_TASK]
                                                playbook [playbook ...]
ansible-playbook: error: the following arguments are required: playbook
ansadmin@svl200:~$
ansadmin@svl200:~$ cd projet4/geerlingguy.apache/
ansadmin@svl200:~/projet4/geerlingguy.apache$ sudo vim site.yml
ansadmin@svl200:~/projet4/geerlingguy.apache$ cd
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/projet2$ cp hosts.yml ../projet
projet/    projet1/ projet2/ projet3/ projet4/
ansadmin@svl200:~/projet2$ cp hosts.yml ../projet4/
ansadmin@svl200:~/projet2$ cd
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ansible-playbook -i hosts.yml site.yml
ERROR! the playbook: site.yml could not be found
ansadmin@svl200:~/projet4$ tree
.
├── geerlingguy.apache
│   ├── LICENSE
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── molecule
│   │   └── default
│   │            ├── converge.yml
│   │            └── molecule.yml
│   ├── site.yml
│   ├── tasks
│   │   ├── configure-Debian.yml
│   │   ├── configure-RedHat.yml
│   │   ├── configure-Solaris.yml
│   │   ├── configure-Suse.yml
│   │   ├── main.yml
│   │   ├── setup-Debian.yml
│   │   ├── setup-RedHat.yml
│   │   ├── setup-Solaris.yml
│   │   └── setup-Suse.yml
│   ├── templates
│   │   └── vhosts.conf.j2
│   └── vars
│            ├── AmazonLinux.yml
│            ├── Debian.yml
│            ├── RedHat.yml
│            ├── Solaris.yml
│            ├── Suse.yml
│            ├── apache-22.yml
│            └── apache-24.yml
└── hosts.yml

9 directories, 26 files
ansadmin@svl200:~/projet4$ :q
:q: command not found
ansadmin@svl200:~/projet4$
ansadmin@svl200:~/projet4$ cd
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ cp site.yml ../projet4/
ansadmin@svl200:~/projet2$ cd
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet4/hosts.yml,
line 3, column 7, found a duplicate dict key (cible1). Using last defined value
only.
ERROR! the role 'users' was not found in /home/ansadmin/projet4/roles:/home/ansa     
dmin/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:/home/ansadmin/p     
rojet4

The error appears to be in '/home/ansadmin/projet4/site.yml': line 6, column 9,      


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    roles:
            - users
                ^ here
ansadmin@svl200:~/projet4$ tree
.
├── geerlingguy.apache
│   ├── LICENSE
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── molecule
│   │   └── default
│   │            ├── converge.yml
│   │            └── molecule.yml
│   ├── site.yml
│   ├── tasks
│   │   ├── configure-Debian.yml
│   │   ├── configure-RedHat.yml
│   │   ├── configure-Solaris.yml
│   │   ├── configure-Suse.yml
│   │   ├── main.yml
│   │   ├── setup-Debian.yml
│   │   ├── setup-RedHat.yml
│   │   ├── setup-Solaris.yml
│   │   └── setup-Suse.yml
│   ├── templates
│   │   └── vhosts.conf.j2
│   └── vars
│            ├── AmazonLinux.yml
│            ├── Debian.yml
│            ├── RedHat.yml
│            ├── Solaris.yml
│            ├── Suse.yml
│            ├── apache-22.yml
│            └── apache-24.yml
├── hosts.yml
└── site.yml

9 directories, 27 files
ansadmin@svl200:~/projet4$ sudo vim site.yml
ansadmin@svl200:~/projet4$ geerlingguy.apache^C
ansadmin@svl200:~/projet4$ sudo vim site.yml
ansadmin@svl200:~/projet4$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet4/hosts.yml,
line 3, column 7, found a duplicate dict key (cible1). Using last defined value
only.

PLAY [install apache] **********************************************************

TASK [Gathering Facts] *********************************************************


fatal: [client2]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect t     
o the host via ssh: ssh: connect to host client2 port 22: Connection refused", "     
unreachable": true}

PLAY RECAP *********************************************************************


client2                                        : ok=0        changed=0       
unreachable=1      failed=0        s                                               
kipped=0        rescued=0        ignored=0

ansadmin@svl200:~/projet4$ tree
.
├── geerlingguy.apache
│   ├── LICENSE
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── molecule
│   │   └── default
│   │            ├── converge.yml
│   │            └── molecule.yml
│   ├── site.yml
│   ├── tasks
│   │   ├── configure-Debian.yml
│   │   ├── configure-RedHat.yml
│   │   ├── configure-Solaris.yml
│   │   ├── configure-Suse.yml
│   │   ├── main.yml
│   │   ├── setup-Debian.yml
│   │   ├── setup-RedHat.yml
│   │   ├── setup-Solaris.yml
│   │   └── setup-Suse.yml
│   ├── templates
│   │   └── vhosts.conf.j2
│   └── vars
│            ├── AmazonLinux.yml
│            ├── Debian.yml
│            ├── RedHat.yml
│            ├── Solaris.yml
│            ├── Suse.yml
│            ├── apache-22.yml
│            └── apache-24.yml
├── hosts.yml
└── site.yml

9 directories, 27 files
ansadmin@svl200:~/projet4$ sudo vim site.yml
ansadmin@svl200:~/projet4$ sudo vim hosts.yml
ansadmin@svl200:~/projet4$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet4/hosts.yml,
line 3, column 7, found a duplicate dict key (cible1). Using last defined value
only.

PLAY [install apache] **********************************************************

TASK [Gathering Facts] *********************************************************


fatal: [client2]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect t     
o the host via ssh: ssh: connect to host client2 port 22: Connection refused", "     
unreachable": true}

PLAY RECAP *********************************************************************


client2                                        : ok=0        changed=0       
unreachable=1      failed=0        s                                               
kipped=0        rescued=0        ignored=0

ansadmin@svl200:~/projet4$ cd
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/projet2$ cp -r group_vars hosts_vars ../projet4/
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ cd
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet4/hosts.yml,
line 3, column 7, found a duplicate dict key (cible1). Using last defined value
only.

PLAY [install apache] **********************************************************

TASK [Gathering Facts] *********************************************************


ok: [client2]

TASK [geerlingguy.apache : Include OS-specific variables.] *********************


ok: [client2]

TASK [geerlingguy.apache : Include variables for Amazon Linux.] ****************


skipping: [client2]

TASK [geerlingguy.apache : Define apache_packages.] ****************************


ok: [client2]

TASK [geerlingguy.apache : include_tasks] **************************************


included: /home/ansadmin/.ansible/roles/geerlingguy.apache/tasks/setup-Debian.ym     
l for client2

TASK [geerlingguy.apache : Update apt cache.] **********************************


changed: [client2]

TASK [geerlingguy.apache : Ensure Apache is installed on Debian.] **************


ok: [client2]

TASK [geerlingguy.apache : Get installed version of Apache.] *******************


ok: [client2]

TASK [geerlingguy.apache : Create apache_version variable.] ********************


ok: [client2]

TASK [geerlingguy.apache : Include Apache 2.2 variables.] **********************


skipping: [client2]

TASK [geerlingguy.apache : Include Apache 2.4 variables.] **********************


ok: [client2]

TASK [geerlingguy.apache : Configure Apache.] **********************************


included: /home/ansadmin/.ansible/roles/geerlingguy.apache/tasks/configure-Debia     
n.yml for client2

TASK [geerlingguy.apache : Configure Apache.] **********************************


ok: [client2] => (item={'regexp': '^Listen ', 'line': 'Listen 80'})

TASK [geerlingguy.apache : Enable Apache mods.] ********************************


changed: [client2] => (item=rewrite)
changed: [client2] => (item=ssl)
TASK [geerlingguy.apache : Disable Apache mods.] *******************************

TASK [geerlingguy.apache : Check whether certificates defined in vhosts exist.]     


***

TASK [geerlingguy.apache : Add apache vhosts configuration.] *******************


changed: [client2]

TASK [geerlingguy.apache : Add vhost symlink in sites-enabled.] ****************


changed: [client2]

TASK [geerlingguy.apache : Remove default vhost in sites-enabled.] *************


skipping: [client2]

TASK [geerlingguy.apache : Ensure Apache has selected state and enabled on boot.     
] ***
ok: [client2]

RUNNING HANDLER [geerlingguy.apache : restart apache] **************************


changed: [client2]

PLAY RECAP *********************************************************************


client2                                        : ok=16    changed=5     
unreachable=0        failed=0        s                                               
kipped=5      rescued=0        ignored=0

ansadmin@svl200:~/projet4$ tree
.
├── geerlingguy.apache
│   ├── LICENSE
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── molecule
│   │   └── default
│   │            ├── converge.yml
│   │            └── molecule.yml
│   ├── site.yml
│   ├── tasks
│   │   ├── configure-Debian.yml
│   │   ├── configure-RedHat.yml
│   │   ├── configure-Solaris.yml
│   │   ├── configure-Suse.yml
│   │   ├── main.yml
│   │   ├── setup-Debian.yml
│   │   ├── setup-RedHat.yml
│   │   ├── setup-Solaris.yml
│   │   └── setup-Suse.yml
│   ├── templates
│   │   └── vhosts.conf.j2
│   └── vars
│            ├── AmazonLinux.yml
│            ├── Debian.yml
│            ├── RedHat.yml
│            ├── Solaris.yml
│            ├── Suse.yml
│            ├── apache-22.yml
│            └── apache-24.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
└── site.yml

11 directories, 28 files
ansadmin@svl200:~/projet4$
Network error: Software caused connection abort

────────────────────────────────────────────────────────────────────────────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0


* Super-optimized for small spaces - read how we shrank the memory
      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

10 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

*** System restart required ***


Last login: Wed Oct    5 07:39:52 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ tree
.
├── cible1.txt
├── copie.yaml
├── debug.yaml
├── debug1.yaml
├── exo2.yaml
├── exo3.yaml
├── exo4.yaml
├── fact.yaml
├── fact1.yaml
├── handler.yaml
├── hello.yaml
├── hello.yml
├── index.html
├── index.html.j2
├── index.html1.j2
├── ip.txt
├── item_users.yaml
├── items.yaml
├── items_users.yaml
├── list.yaml
├── locale.yml
├── nginx.yaml
├── play-vars.yaml
├── play-vars.yml
├── projet
│   ├── group_vars
│   │   ├── cible1.yaml
│   │   └── cible2.yaml
│   ├── host_vars
│   │   ├── client1.yaml
│   │   └── client2.yaml
│   ├── install.yaml
│   ├── inventory.yaml
│   └── vars_install.yaml
├── projet1
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   ├── roles
│   │   └── apache
│   │            ├── handlers
│   │            │   └── main.yml
│   │            ├── tasks
│   │            │   └── main.yml
│   │            ├── templates
│   │            │   └── index.html.j2
│   │            └── vars
│   │                    └── main.yml
│   └── site.yml
├── projet2
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   ├── roles
│   │   └── users
│   │            ├── handlers
│   │            │   └── main.yml
│   │            ├── tasks
│   │            │   └── main.yml
│   │            ├── templates
│   │            │   └── index.html.j2
│   │            └── vars
│   │                    └── main.yml
│   └── site.yml
├── projet3
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
├── projet4
│   ├── geerlingguy.apache
│   │   ├── LICENSE
│   │   ├── README.md
│   │   ├── defaults
│   │   │   └── main.yml
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── meta
│   │   │   └── main.yml
│   │   ├── molecule
│   │   │   └── default
│   │   │            ├── converge.yml
│   │   │            └── molecule.yml
│   │   ├── site.yml
│   │   ├── tasks
│   │   │   ├── configure-Debian.yml
│   │   │   ├── configure-RedHat.yml
│   │   │   ├── configure-Solaris.yml
│   │   │   ├── configure-Suse.yml
│   │   │   ├── main.yml
│   │   │   ├── setup-Debian.yml
│   │   │   ├── setup-RedHat.yml
│   │   │   ├── setup-Solaris.yml
│   │   │   └── setup-Suse.yml
│   │   ├── templates
│   │   │   └── vhosts.conf.j2
│   │   └── vars
│   │            ├── AmazonLinux.yml
│   │            ├── Debian.yml
│   │            ├── RedHat.yml
│   │            ├── Solaris.yml
│   │            ├── Suse.yml
│   │            ├── apache-22.yml
│   │            └── apache-24.yml
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   └── site.yml
├── rep.yaml
├── seq.yaml
├── shell.yml
├── snap
│   └── tree
│            ├── 18
│            ├── common
│            └── current -> 18
├── template.yaml
├── template1.yaml
├── var_dic.yml
├── var_dic2.yml
├── var_dic_multi3.yml
├── vars.yml
├── vars2.yml
├── vars_multi.yml
├── when.yaml
└── when1.yaml

47 directories, 94 files
ansadmin@svl200:~$
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet2$ sudo vim site.yml
ansadmin@svl200:~/projet2$ sudo vim roles/users/handlers/main.yml
ansadmin@svl200:~/projet2$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/projet2$ sudo vim roles/users/templates/index.html.j2
ansadmin@svl200:~/projet2$ sudo vim roles/users/vars/main.yml
ansadmin@svl200:~/projet2$ sudo vim site.yml
ansadmin@svl200:~/projet2$ sudo vim group_vars/all.yml
ansadmin@svl200:~/projet2$ sudo vim hosts.yml
ansadmin@svl200:~/projet2$
ansadmin@svl200:~/projet2$ cd
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo vim /etc/
Display all 201 possibilities? (y or n)
ansadmin@svl200:~$ sudo vim /etc/hosts
ansadmin@svl200:~$ sudo vim /etc/ansible/hosts
ansadmin@svl200:~$
ansadmin@svl200:~$ ssh
usage: ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bind_interface]
                      [-b bind_address] [-c cipher_spec] [-D [bind_address:]port]
                      [-E log_file] [-e escape_char] [-F configfile] [-I pkcs11]
                      [-i identity_file] [-J [user@]host[:port]] [-L address]
                      [-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p
port]
                      [-Q query_option] [-R address] [-S ctl_path] [-W host:port]
                      [-w local_tun[:remote_tun]] destination [command]
ansadmin@svl200:~$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/ansadmin/.ssh/id_rsa):
/home/ansadmin/.ssh/id_rsa already exists.
Overwrite (y/n)? y
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/ansadmin/.ssh/id_rsa
Your public key has been saved in /home/ansadmin/.ssh/id_rsa.pub
The key fingerprint is:
SHA256:JxwGhnJZfswUvx6gm7/XCGMXNUhKu+p80/p8jjTxJWw ansadmin@svl200
The key's randomart image is:
+---[RSA 3072]----+
|          ++ +o..          |
|    . +o * +. o        |
|      o    . X .. .      |
|              = +.o          |
|            . S =.E .    |
|              +++.= o      |
|            +. =+o.        |
|          o .oo+oo        |
|            o.+*+o.        |
+----[SHA256]-----+
ansadmin@svl200:~$ ssh
usage: ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bind_interface]
                      [-b bind_address] [-c cipher_spec] [-D [bind_address:]port]
                      [-E log_file] [-e escape_char] [-F configfile] [-I pkcs11]
                      [-i identity_file] [-J [user@]host[:port]] [-L address]
                      [-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p
port]
                      [-Q query_option] [-R address] [-S ctl_path] [-W host:port]
                      [-w local_tun[:remote_tun]] destination [command]
ansadmin@svl200:~$ copy id
ansadmin@svl200:~$ ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub
[email protected]                                                             
-p 55600
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed:
"/home/ansadmin/.ssh/id_rs                                                           
a.pub"
The authenticity of host '[141.95.160.128]:55600 ([141.95.160.128]:55600)' can't be
esta                                                                                 
blished.
ECDSA key fingerprint is SHA256:Asg9qJaW9YQpni0qR69B2dHbik3PNd4RsVKxzOkb1vo.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out
any                                                                                 
that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted
now i                                                                               
t is to install the new keys
[email protected]'s password:
Permission denied, please try again.
[email protected]'s password:
Permission denied, please try again.
[email protected]'s password:
[email protected]: Permission denied (publickey,password).
ansadmin@svl200:~$
ansadmin@svl200:~$ sudo mkdir TP3
ansadmin@svl200:~$ cd TP3/
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}

PLAY RECAP
*****************************************************************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                  
the host via ssh: [email protected]: Permission denied (publickey,password).",
"unr                                                                                 
eachable": true}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                  
the host via ssh: [email protected]: Permission denied (publickey,password).",
"unr                                                                                 
eachable": true}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                  
the host via ssh: [email protected]: Permission denied (publickey,password).",
"unr                                                                                 
eachable": true}
fatal: [141.95.160.133]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}

PLAY RECAP
*****************************************************************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
141.95.160.133                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                  
the host via ssh: [email protected]: Permission denied (publickey,password).",
"unr                                                                                 
eachable": true}
fatal: [141.95.160.133]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}

PLAY RECAP
*****************************************************************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
141.95.160.133                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                  
the host via ssh: [email protected]: Permission denied (publickey,password).",
"unr                                                                                 
eachable": true}
fatal: [141.95.160.133]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}

PLAY RECAP
*****************************************************************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
141.95.160.133                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub
[email protected]                                                                 
.16 -p 55600
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed:
"/home/ansadmin/.ssh/id_rs                                                           
a.pub"
^C
ansadmin@svl200:~/TP3$ ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub
[email protected]                                                                 
.133 -p 55600
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed:
"/home/ansadmin/.ssh/id_rs                                                           
a.pub"
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out
any                                                                                 
that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted
now i                                                                               
t is to install the new keys
[email protected]'s password:

Number of key(s) added: 1

Now try logging into the machine, with:      "ssh -p '55600'


'[email protected]'"
and check to make sure that only the key(s) you wanted were added.

ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml                                   


PLAY [creation de partition]
***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                  
the host via ssh: [email protected]: Permission denied (publickey,password).",
"unr                                                                                 
eachable": true}
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}
ok: [141.95.160.133]

TASK [partition]
***********************************************************************
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "missing required
argument                                                                             
s: device"}

PLAY RECAP
*****************************************************************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0                                                           
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub


[email protected]                                                                 
.16 -p 55600
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed:
"/home/ansadmin/.ssh/id_rs                                                           
a.pub"
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out
any                                                                                 
that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted
now i                                                                               
t is to install the new keys
[email protected]'s password:

Number of key(s) added: 1

Now try logging into the machine, with:      "ssh -p '55600'


'[email protected]'"
and check to make sure that only the key(s) you wanted were added.

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml                                   
PLAY [creation de partition]
***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "missing required
arguments                                                                           
: device"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "missing required
argument                                                                             
s: device"}

PLAY RECAP
*****************************************************************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml                                   
PLAY [creation de partition]
***********************************************************

TASK [Gathering Facts]


*****************************************************************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to                                                                                   
the host via ssh: [email protected]: Permission denied (publickey,password).",
"u                                                                                   
nreachable": true}
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [partition]
***********************************************************************
^Lfatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "missing required
argumen                                                                             
ts: device"}
fatal: [141.95.160.133]: FAILED! => {"changed": false, "msg": "missing required
argument                                                                             
s: device"}

PLAY RECAP
*****************************************************************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0                                                           
rescued=0        ignored=0
141.95.160.133                          : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml                                           
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "missing required
arguments                                                                           
: device"}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "state is present but
all o                                                                               
f the following are missing: number"}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": [250.0, "M"], "msg":
"The a                                                                               
rgument 'part_end' doesn't respect required format.The size unit is case sensitive."}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml
PLAY [creation de partition]
***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": [250.0, "m"], "msg":
"The a                                                                               
rgument 'part_end' doesn't respect required format.The size unit is case sensitive."}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": [250.0, "mb"], "msg":
"The                                                                                
argument 'part_end' doesn't respect required format.The size unit is case
sensitive."}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": "Error: Could not stat
devi                                                                                 
ce /tp3_ansible/exo1 - No such file or directory.\n", "msg": "Error while getting
device                                                                               
information with parted script: '/usr/sbin/parted -s -m /tp3_ansible/exo1 -- unit
'KiB'                                                                               
print'", "out": "", "rc": 1}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": [250.0, "M"], "msg":
"The a                                                                               
rgument 'part_end' doesn't respect required format.The size unit is case sensitive."}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ ^C
ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
[WARNING]: The value [250.0, 'M'] (type list) in a string field was converted to
"[250.0, 'M']" (type string). If this does not look like what you expect, quote the
entire value to ensure it does not change.
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Error interpreting
parted                                                                              
size output: '[250.0, 'M']'"}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": "Error: Could not stat
devi                                                                                 
ce /tp3_ansible/exo1 - No such file or directory.\n", "msg": "Error while getting
device                                                                               
information with parted script: '/usr/sbin/parted -s -m /tp3_ansible/exo1 -- unit
'KiB'                                                                               
print'", "out": "", "rc": 1}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": "Error: Could not stat
devi                                                                                 
ce /tp3_ansible/exo1 - No such file or directory.\n", "msg": "Error while getting
device                                                                               
information with parted script: '/usr/sbin/parted -s -m /tp3_ansible/exo1 -- unit
'KiB'                                                                               
print'", "out": "", "rc": 1}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": "Error: Could not stat
devi                                                                                 
ce /dev/aaw - No such file or directory.\n", "msg": "Error while getting device
informat                                                                             
ion with parted script: '/usr/sbin/parted -s -m /dev/aaw -- unit 'KiB' print'",
"out": "                                                                             
", "rc": 1}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ ^C
ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


***********************************************************

TASK [Gathering Facts]


*****************************************************************
ok: [146.59.158.16]

TASK [partition]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": "Warning: Unable to open
/u                                                                                   
sr/sbin/parted read-write (Text file busy).    /usr/sbin/parted has been opened read-
only.                                                                               
\nError: Can't write to /usr/sbin/parted, because it is opened read-only.\n", "msg":
"Er                                                                                 
ror while running parted script: /usr/sbin/parted -s -m -a optimal /usr/sbin/parted
-- u                                                                                 
nit KiB mklabel msdos mkpart primary 0% 100%", "out": "", "rc": 1}

PLAY RECAP
*****************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0                                                             
rescued=0        ignored=0

ansadmin@svl200:~/TP3$ ansible cible1 -bm shell -a "mkdir /tp3"


[WARNING]: Consider using the file module with state=directory rather than running
'mkdir'.    If you need to use command because file is insufficient you can add
'warn:
false' to this command task or set 'command_warnings=False' in ansible.cfg to get rid
of this message.
146.59.158.16 | CHANGED | rc=0 >>

ansadmin@svl200:~/TP3$ tree
ansadmin@svl200:~/TP3$ ansible cible1 -bm shell -a "mkdir tp3"
[WARNING]: Consider using the file module with state=directory rather than running
'mkdir'.    If you need to use command because file is insufficient you can add
'warn:
false' to this command task or set 'command_warnings=False' in ansible.cfg to get rid
of this message.
146.59.158.16 | CHANGED | rc=0 >>

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ansible cible1 -bm shell -a "mkdir /tp3"
[WARNING]: Consider using the file module with state=directory rather than running
'mkdir'.    If you need to use command because file is insufficient you can add
'warn:
false' to this command task or set 'command_warnings=False' in ansible.cfg to get rid
of this message.
146.59.158.16 | FAILED | rc=1 >>
mkdir: cannot create directory ‘/tp3’: File existsnon-zero return code
ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


*************************************************************************************
******************************************************

TASK [Gathering Facts]


*************************************************************************************
************************************************************
ok: [146.59.158.16]

TASK [partition]
*************************************************************************************
******************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": "Error: Could not stat
device /dev/aaw - No such file or directory.\n", "msg": "Error while getting device  
information with parted script: '/usr/sbin/parted -s -m /dev/aaw -- unit 'KiB'
print'", "out": "", "rc": 1}
PLAY RECAP
*************************************************************************************
************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TP3$ sudo vim exo1.yaml


ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ansible-playbook exo1.yaml

PLAY [creation de partition]


*************************************************************************************
******************************************************

TASK [Gathering Facts]


*************************************************************************************
************************************************************
ok: [146.59.158.16]

TASK [partition]
*************************************************************************************
******************************************************************
[WARNING]: The value 250 (type int) in a string field was converted to '250' (type
string). If this does not look like what you expect, quote the entire value to
ensure it does not change.
fatal: [146.59.158.16]: FAILED! => {"changed": false, "err": [250.0, ""], "msg": "The
argument 'part_end' doesn't respect required format.The size unit is case sensitiv   
e."}

PLAY RECAP
*************************************************************************************
************************************************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ sudo vim exo1.yaml
ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ls
exo1.yaml
ansadmin@svl200:~/TP3$ mkdir roles
mkdir: cannot create directory ‘roles’: Permission denied
ansadmin@svl200:~/TP3$ sudo mkdir roles
ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ ll
total 16
drwxr-xr-x    3 root          root          4096 Oct    6 09:27 ./
drwxr-xr-x 11 ansadmin ansadmin 4096 Oct    6 07:59 ../
-rw-r--r--    1 root          root            209 Oct    6 09:23 exo1.yaml
drwxr-xr-x    2 root          root          4096 Oct    6 09:27 roles/
ansadmin@svl200:~/TP3$ cd
ansadmin@svl200:~$
ansadmin@svl200:~$ cd projet2
ansadmin@svl200:~/projet2$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/projet2$ cd
ansadmin@svl200:~$ cp projet2 TPansible
cp: -r not specified; omitting directory 'projet2'
ansadmin@svl200:~$ cp -r projet2    TPansible
ansadmin@svl200:~$
ansadmin@svl200:~$ cd TP
TP3/              TPansible/
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/TPansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/TPansible$ cd
ansadmin@svl200:~$ cd TP3
ansadmin@svl200:~/TP3$ ls -lrt
total 8
-rw-r--r-- 1 root root    209 Oct    6 09:23 exo1.yaml
drwxr-xr-x 2 root root 4096 Oct    6 09:27 roles
ansadmin@svl200:~/TP3$
ansadmin@svl200:~/TP3$ cd
ansadmin@svl200:~$ cd TP
TP3/              TPansible/
ansadmin@svl200:~$ cd TPan
-bash: cd: TPan: No such file or directory
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/TPansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/TPansible$ sudo vim
group_vars/ hosts.yml      hosts_vars/ roles/            site.yml
ansadmin@svl200:~/TPansible$ sudo vim
group_vars/ hosts.yml      hosts_vars/ roles/            site.yml
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ sudo vim roles/users/templates/index.html.j2
ansadmin@svl200:~/TPansible$ sudo vim roles/users/vars/main.yml
ansadmin@svl200:~/TPansible$ sudo vim group_vars/all.yml
ansadmin@svl200:~/TPansible$ sudo vim site.yml
ansadmin@svl200:~/TPansible$ sudo vim group_vars/all.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/TPansible/hosts.yml, line
3, column 7, found a duplicate dict key
(cible1). Using last defined value only.
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: utilisation de LVM
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/TPansible/hosts.yml, line
3, column 7, found a duplicate dict key
(cible1). Using last defined value only.
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: utilisation de LVM
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/TPansible/hosts.yml, line
3, column 7, found a duplicate dict key
(cible1). Using last defined value only.
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: utilisation de LVM
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
[WARNING]: While constructing a mapping from /home/ansadmin/TPansible/hosts.yml, line
3, column 7, found a duplicate dict key
(cible1). Using last defined value only.
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
[WARNING]: While constructing a mapping from /home/ansadmin/TPansible/hosts.yml, line
3, column 7, found a duplicate dict key
(cible1). Using last defined value only.
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/TPansible$ sudo vim hosts.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim hosts.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ cd ..
ansadmin@svl200:~$ tree
.
├── TP3 [error opening dir]
├── TPansible
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   ├── roles
│   │   └── users
│   │            ├── handlers
│   │            │   └── main.yml
│   │            ├── tasks
│   │            │   └── main.yml
│   │            ├── templates
│   │            │   └── index.html.j2
│   │            └── vars
│   │                    └── main.yml
│   └── site.yml
├── cible1.txt
├── copie.yaml
├── debug.yaml
├── debug1.yaml
├── exo2.yaml
├── exo3.yaml
├── exo4.yaml
├── fact.yaml
├── fact1.yaml
├── handler.yaml
├── hello.yaml
├── hello.yml
├── index.html
├── index.html.j2
├── index.html1.j2
├── ip.txt
├── item_users.yaml
├── items.yaml
├── items_users.yaml
├── list.yaml
├── locale.yml
├── nginx.yaml
├── play-vars.yaml
├── play-vars.yml
├── projet
│   ├── group_vars
│   │   ├── cible1.yaml
│   │   └── cible2.yaml
│   ├── host_vars
│   │   ├── client1.yaml
│   │   └── client2.yaml
│   ├── install.yaml
│   ├── inventory.yaml
│   └── vars_install.yaml
├── projet1
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   ├── roles
│   │   └── apache
│   │            ├── handlers
│   │            │   └── main.yml
│   │            ├── tasks
│   │            │   └── main.yml
│   │            ├── templates
│   │            │   └── index.html.j2
│   │            └── vars
│   │                    └── main.yml
│   └── site.yml
├── projet2
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   ├── roles
│   │   └── users
│   │            ├── handlers
│   │            │   └── main.yml
│   │            ├── tasks
│   │            │   └── main.yml
│   │            ├── templates
│   │            │   └── index.html.j2
│   │            └── vars
│   │                    └── main.yml
│   └── site.yml
├── projet3
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
├── projet4
│   ├── geerlingguy.apache
│   │   ├── LICENSE
│   │   ├── README.md
│   │   ├── defaults
│   │   │   └── main.yml
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── meta
│   │   │   └── main.yml
│   │   ├── molecule
│   │   │   └── default
│   │   │            ├── converge.yml
│   │   │            └── molecule.yml
│   │   ├── site.yml
│   │   ├── tasks
│   │   │   ├── configure-Debian.yml
│   │   │   ├── configure-RedHat.yml
│   │   │   ├── configure-Solaris.yml
│   │   │   ├── configure-Suse.yml
│   │   │   ├── main.yml
│   │   │   ├── setup-Debian.yml
│   │   │   ├── setup-RedHat.yml
│   │   │   ├── setup-Solaris.yml
│   │   │   └── setup-Suse.yml
│   │   ├── templates
│   │   │   └── vhosts.conf.j2
│   │   └── vars
│   │            ├── AmazonLinux.yml
│   │            ├── Debian.yml
│   │            ├── RedHat.yml
│   │            ├── Solaris.yml
│   │            ├── Suse.yml
│   │            ├── apache-22.yml
│   │            └── apache-24.yml
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── hosts_vars
│   └── site.yml
├── rep.yaml
├── seq.yaml
├── shell.yml
├── snap
│   └── tree
│            ├── 18
│            ├── common
│            └── current -> 18
├── template.yaml
├── template1.yaml
├── var_dic.yml
├── var_dic2.yml
├── var_dic_multi3.yml
├── vars.yml
├── vars2.yml
├── vars_multi.yml
├── when.yaml
└── when1.yaml

57 directories, 101 files


ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
ERROR! the playbook: site.yml could not be found
ansadmin@svl200:~$ cd
.ansible/    .ssh/            TP3/              TPansible/ projet/        projet1/   
projet2/      projet3/      projet4/      snap/
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/TPansible$ sudo vim hosts.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim hosts.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
[DEPRECATION WARNING]: The TRANSFORM_INVALID_GROUP_CHARS settings is set to allow bad
characters in group names by default, this
will change, but still be user configurable on deprecation. This feature will be
removed in version 2.10. Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
[WARNING]: Invalid characters were found in group names but not replaced, use -vvvv
to see details
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
[DEPRECATION WARNING]: The TRANSFORM_INVALID_GROUP_CHARS settings is set to allow bad
characters in group names by default, this
will change, but still be user configurable on deprecation. This feature will be
removed in version 2.10. Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
[WARNING]: Invalid characters were found in group names but not replaced, use -vvvv
to see details
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ cd
ansadmin@svl200:~$
ansadmin@svl200:~$ cd
.ansible/    .ssh/            TP3/              TPansible/ projet/        projet1/   
projet2/      projet3/      projet4/      snap/
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/TPansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
[DEPRECATION WARNING]: The TRANSFORM_INVALID_GROUP_CHARS settings is set to allow bad
characters in group names by default, this
will change, but still be user configurable on deprecation. This feature will be
removed in version 2.10. Deprecation warnings can
be disabled by setting deprecation_warnings=False in ansible.cfg.
[WARNING]: Invalid characters were found in group names but not replaced, use -vvvv
to see details
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ sudo vim hosts.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28
SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/TPansible$ cd roles/
ansadmin@svl200:~/TPansible/roles$ ls
users
ansadmin@svl200:~/TPansible/roles$ cd users/$
-bash: cd: users/$: No such file or directory
ansadmin@svl200:~/TPansible/roles$ cd users/
ansadmin@svl200:~/TPansible/roles/users$ ls
handlers    tasks    templates    vars
ansadmin@svl200:~/TPansible/roles/users$ cp tasks/main.yml ../../
ansadmin@svl200:~/TPansible/roles/users$ cd ../../
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    main.yml    roles    site.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -kk -u apx28
SSH password:

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: apx28@client1: Permission denied                                       
(publickey,password).", "unreachable": true}
fatal: [client2]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: apx28@client2: Permission denied                                       
(publickey,password).", "unreachable": true}
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: [email protected]: Per                                       
mission denied (publickey,password).", "unreachable": true}

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=0
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0
client2                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub
[email protected] -p 55600
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed:
"/home/ansadmin/.ssh/id_rsa.pub"
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out
any that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted
now it is to install the new keys
[email protected]'s password:
Permission denied, please try again.
[email protected]'s password:

ansadmin@svl200:~/TPansible$ ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub


[email protected] -p 55600
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed:
"/home/ansadmin/.ssh/id_rsa.pub"
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out
any that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted
now it is to install the new keys
[email protected]'s password:
Number of key(s) added: 1

Now try logging into the machine, with:      "ssh -p '55600' '[email protected]'"
and check to make sure that only the key(s) you wanted were added.

ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml -kk -u apx28


SSH password:
ERROR! conflicting action statements: hosts, tasks

The error appears to be in '/home/ansadmin/TPansible/roles/users/tasks/main.yml':


line 2, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

---
- name: partition lvm
    ^ here
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -kk -u apx28
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -kk -u apx28
SSH password:

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: FAILED! => {"msg": "to use the 'ssh' connection type with
passwords, you must install the sshpass program"}
fatal: [client2]: FAILED! => {"msg": "to use the 'ssh' connection type with
passwords, you must install the sshpass program"}
fatal: [141.95.160.128]: FAILED! => {"msg": "to use the 'ssh' connection type with
passwords, you must install the sshpass program"}

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=0        changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0
client1                                        : ok=0        changed=0       
unreachable=0        failed=1      skipped=0        rescued=0        ignored=0
client2                                        : ok=0        changed=0       
unreachable=0        failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -u apx28

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: apx28@client1: Permission denied                                       
(publickey,password).", "unreachable": true}
fatal: [client2]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: apx28@client2: Permission denied                                       
(publickey,password).", "unreachable": true}
ok: [141.95.160.128]

TASK [partition1]
*************************************************************************************
*****************************
changed: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
changed: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
changed: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
changed: [141.95.160.128]

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=5      changed=4      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0
client2                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ ls
ansadmin@svl200:~/TPansible$ sudo vim hosts.yml
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -u apx28

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [client1]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: apx28@client1: Permission denied                                       
(publickey,password).", "unreachable": true}
fatal: [client2]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect to the
host via ssh: apx28@client2: Permission denied                                       
(publickey,password).", "unreachable": true}
ok: [141.95.160.128]

TASK [partition1]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
changed: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
ok: [141.95.160.128]

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=5      changed=1      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0
client1                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0
client2                                        : ok=0        changed=0       
unreachable=1      failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ sudo vim hosts.yml


ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -u apx28

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [141.95.160.128]

TASK [partition1]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
ok: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
ok: [141.95.160.128]

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=5      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml


ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -u apx28

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [141.95.160.128]

TASK [partition1]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
ok: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
ok: [141.95.160.128]

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=5      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ sudo vim roles/users/tasks/main.yml
ansadmin@svl200:~/TPansible$ cat roles/users/tasks/main.yml
---
- name: partition lvm
    hosts: 141.95.160.128
    become: true

    tasks:
        - name: partition1
            lvol:
                vg: datavg
                lv: ansible_lv1_aaw
                size: 250M
                force: yes

        - name: creation de fichier


            file:
                    path: /tp3_aaw
                    state: directory
                    mode: 755

        - name: filesystem
            filesystem:
                fstype: xfs
                dev: /dev/datavg/ansible_lv1_aaw

        - name: montage
            mount:
                  path: /tp3_aaw
                  src: /dev/datavg/ansible_lv1_aaw
                  fstype: xfs
                  state: mounted

        - name: partition1
            lvol:
                vg: datavg
                lv: ansible_lv2_aaw
                size: 250M
                force: yes

        - name: creation de fichier


            file:
                    path: /tp3_aaw
                    state: directory
                    mode: 755

        - name: filesystem
            filesystem:
                fstype: xfs
                dev: /dev/datavg/ansible_lv2_aaw
        - name: montage
            mount:
                  path: /tp3_aaw
                  src: /dev/datavg/ansible_lv2_aaw
                  fstype: xfs
                  state: mounted

ansadmin@svl200:~/TPansible$ ^C
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -u apx28

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [141.95.160.128]

TASK [partition1]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
ok: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
ok: [141.95.160.128]

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=5      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ cd
ansadmin@svl200:~$ ansible 141.95.160.128 -bm shell -a "df -h /dev/datavg"
141.95.160.128 | UNREACHABLE! => {
        "changed": false,
        "msg": "Failed to connect to the host via ssh: [email protected]:
Permission denied (publickey,password).",
        "unreachable": true
}
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── main.yml
├── roles
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 8 files
ansadmin@svl200:~/TPansible$ cd
ansadmin@svl200:~$ ls
TP3                    exo2.yaml          hello.yaml            item_users.yaml     
play-vars.yaml    projet4                template1.yaml            vars_multi.yml
TPansible        exo3.yaml          hello.yml              items.yaml               
play-vars.yml      rep.yaml              var_dic.yml                  when.yaml
cible1.txt      exo4.yaml          index.html            items_users.yaml    projet 
seq.yaml              var_dic2.yml                when1.yaml
copie.yaml      fact.yaml          index.html.j2      list.yaml                 
projet1                  shell.yml            var_dic_multi3.yml
debug.yaml      fact1.yaml        index.html1.j2    locale.yml                projet2
snap                      vars.yml
debug1.yaml    handler.yaml    ip.txt                    nginx.yaml               
projet3                  template.yaml    vars2.yml
ansadmin@svl200:~$
                lv: ansible_lv1_aaw
                size: 250M
                force: yes

        - name: creation de fichier


            file:
                    path: /tp3_aaw
                    state: directory
                    mode: 755

        - name: filesystem
            filesystem:
                fstype: xfs
                dev: /dev/datavg/ansible_lv1_aaw

        - name: montage
            mount:
                  path: /tp3_aaw
                  src: /dev/datavg/ansible_lv1_aaw
                  fstype: xfs
                  state: mounted

:
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
───────────────────────────────────────────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

10 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.
*** System restart required ***
Last login: Thu Oct    6 07:17:29 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$ history
        1    ssh-keygen -t rsa
        2    ssh
        3    ssh-copy-id [email protected] [email protected]
        4    sudo vim /etc/ssh/sshd_config
        5    ls -l .ssh/
        6    ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub [email protected] -p
55600
        7    ssh-copy-id -i /home/ansadmin/.ssh/id_rsa.pub [email protected] -p
55600
        8    sudo vim /etc/ansible/hosts
        9    ansible all -m ping
      10    sudo vim /etc/ansible/hosts
      11    ansible all -m ping
      12    ansible cible1 -m ping
      13    ansible cible2 -m ping
      14    ansible 146.59.158.16 -m ping
      15    ansible 141.95.160.133 -m ping
      16    sudo touch cible1.txt
      17    ansible cible1 -m copy -a "src=cible1.txt dest=/tmp"
      18    ansible cible1 -m ls -a "dest=/tmp"
      19    ansible cible1 -m shell -a "ls -lrt /tmp"
      20    ansible cible1 -m file -a "dest=/tmp/cible1.txt mode=777"
      21    ansible cible1 -m user -a "name=cible1 state=present"
      22    ansible cible1 -b -m user -a "name=cible1 state=present"
      23    ansible cible1 -m shell -a "cat /etc/passwd | grep cible1"
      24    ansible all -b -m apt -a "name=curl state=latest"
      25    ansible cible1 -m service -a "name=cron state=started"
      26    ansible cible1 -b -m service -a "name=cron state=started"
      27    ansible cible1 -b -m service -a "name=cron state=stopped"
      28    ansible cible1 -b -m systemd -a "name=cron state=started"
      29    ansible cible1 -b -m systemd -a "name=cron state=stopped"
      30    ansible cible1 -b -m systemd -a "name=cron state=restarted"
      31    ansible all -a 'whoami'
      32    ansible cible1 -a 'whoami'
      33    ansible cible2 -a 'whoami'
      34    ansible all -ab 'whoami'
      35    ansible all -b -a 'whoami'
      36    ansible all -ba 'whoami'
      37    sudo vim nginx.yaml
      38    ansible-playbook nginx.yml
      39    ansible-playbook nginx.yaml
      40    sudo vim nginx.yaml
      41    ansible all -m service -a "name=apache2 state=status"
      42    ansible cible1 -bm shell -a "systemctl status cron"
      43    uname -a
      44    uname -r
      45    cat /etc/os-release
      46    lsb_release
      47    ansible all -a "cat /ho
      48    sudo vim shell.yml
      49    ansible all -a "cat /home/ansadmin/resultat.txt"
      50    ansible-playbook resultat.txt
      51    sudo vim shell.yml
      52    ansible-playbook /home/ansadmin/resultat.txt
      53    sudo vim shell.yml
      54    ansible-playbook shell.yml
      55    ansible all -a "cat /home/ansadmin/resultat.txt"
      56    sudo vim shell.yml
      57    ansible-playbook shell.yml
      58    sudo vim shell.yml
      59    ansible-playbook shell.yml
      60    sudo vim shell.yml
      61    ansible-playbook shell.yml
      62    ansible-playbook -b shell.yml
      63    ansible all -a "cat /home/ansadmin/resultat.txt"
      64    sudo vim handler.yaml
      65    sudo vim handler.yaml
      66    vim handler.yaml
      67    sudo vim when.yml
      68    history
      69    ls
      70    sudo vim debug1.yaml
      71    ansible-playbook -b debug1.yaml
      72    sudo vim when.yaml
      73    ansible-playbook when.yaml
      74    sudo vim when1.yaml
      75    sudo rm when1.yaml
      76    ls
      77    sudo cp when.yaml when1.yaml
      78    sudo vim when1.yaml
      79    ansible-playbook when1.yaml
      80    sudo vim list.yaml
      81    ansible-playbook list.yaml
      82    sudo vim items.yaml
      83    ansible-playbook items.yaml
      84    ls
      85    ansible cible1 -bm shell -a "ls -lrt /home/ansadmin"
      86    ansible cible2 -bm shell -a "ls -lrt /home/ansadmin"
      87    ansible all -bm shell -a "ls -lrt /home/ansadmin"
      88    ansible all -bma "ls -lrt /home/ansadmin"
      89    ansible all -bm shell -a "ls -lrt /home/ansadmin"
      90    cp items.yaml seq.yaml
      91    sudo vim seq.yaml
      92    ansible-playbook seq.yaml
      93    ansible all -bm shell -a "ls -lrt /home/ansadmin"
      94    ansible all -bm shell -a "ls -lrt /home/ansadmin | grep Dev"
      95    ansible all -bm group -a "name=rennes"
      96    ansible all -bm group -a "name=lille"
      97    ansible all -bm group -a "name=paris"
      98    ansible all -bm user -a "name=core"
      99    ansible all -bm user -a "name=core uid=10000"
    100    ansible all -bm user -a "name=core groups=rennes"
    101    ansible all -bm apt -a "name=tree state=latest"
    102    ansible all -bm service -a "name=cron state=stopped"
    103    ansible all -bm service -a "name=cron state=disabled"
    104    ansible all -bm service -a "name=cron enabled=no"
    105    ansible all -m file -a "path=/tmp/test.txt state=touch mode=0644"
    106    ansible all -m shell -a "ls -lrt /tmp/test.txt | grep test"
    107    ansible all -m shell -a "ls -lrt /tmp | grep test"
    108    ansible all -m directory -a "path=/tmp/dir state= mode=755"
    109    ansible all -m dir -a "path=/tmp/dir state= mode=755"
    110    ansible all -m file -a "path=/tmp/dir state=directory    mode=755"
    111    ansible all -bm apt -a "name=* state=latest"
    112    sudo vim exo2.yaml
    113    sudo vim exo3.yaml
    114    ansible-playbook exo3.yaml
    115    sudo vim exo3.yaml
    116    ansible-playbook exo3.yaml
    117    ansible-playbook exo3.yaml
    118    sudo vim exo3.yaml
    119    ansible-playbook exo3.yaml
    120    ansible -bm shell -a "id supervision"
    121    ansible -bm shell -a "cat /etc/passwd | grep super"
    122    ansible -b -m shell -a "cat /etc/passwd | grep super"
    123    ansible all -b -m shell -a "cat /etc/passwd | grep super"
    124    sudo vim exo4.yaml
    125    sudo vim exo4.yaml
    126    ansible-playbook exo4.yaml
    127    sudo vim exo4.yaml
    128    ansible-playbook exo4.yaml
    129    sudo vim exo4.yaml
    130    ansible-playbook exo4.yaml
    131    sudo vim exo4.yaml
    132    ansible-playbook exo4.yaml
    133    sudo vim exo4.yaml
    134    sudo vim when1.yaml
    135    sudo vim when.yaml
    136    sudo vim when1.yaml
    137    ansible-playbook when1.yaml
    138    sudo vim when1.yaml
    139    sudo vim rep.yaml
    140    ansible-playbook rep.yaml
    141    sudo vim rep.yaml
    142    ansible all -bm shell -a "ls -lrt /etc"
    143    ansible all -bm shell -a "ls -lrt /tmp"
    144    ansible all -bm shell -a "ls -lrt /etc | grep Deb"
    145    ansible-playbook rep.yaml
    146    ansible all -bm shell -a "ls -lrt /etc | grep Deb"
    147    ansible all -bm shell -a "ls -lrt /etc | grep redhat"
    148    ansible-playbook rep.yaml
    149    sudo vim rep.yaml
    150    ansible-playbook rep.yaml
    151    ansible all -bm shell -a "ls -lrt /tmp/redhat | grep redhat"
    152    ansible all -bm shell -a "ls -lrt /tmp/redhat"
    153    ansible all -bm shell -a "ls -lrt /tmp/Redhat"
    154    ansible-playbook list.yaml
    155    sudo vim list.yaml
    156    ansible-playbook list.yaml
    157    sudo vim template.yaml
    158    sudo vim items.yaml
    159    ansible-playbook items.yaml
    160    sudo vim items.yaml
    161    ansible all -bm shell -a "ls -lrt /home/ansadmin"
    162    sudo vim items_users.yaml
    163    sudo -f items_users.yaml
    164    rm items_users.yaml
    165    cp items.yaml item_users.yaml
    166    sudo vim items_users.yaml
    167    ls
    168    sudo vim item_users.yaml
    169    ls
    170    sudo vim exo3.yaml
    171    sudo vim item_users.yaml
    172    ansible-playbook item_users.yaml
    173    sudo vim item_users.yaml
    174    sudo vim items.yaml
    175    sudo vim item_users.yaml
    176    ansible-playbook item_users.yaml
    177    sudo vim items.yaml
    178    sudo vim item_users.yaml
    179    ansible-playbook item_users.yaml
    180    sudo vim exo3.yaml
    181    sudo vim item_users.yaml
    182    ansible-playbook item_users.yaml
    183    sudo vim item_users.yaml
    184    ansible-playbook item_users.yaml
    185    sudo vim seq.yaml
    186    ansible-playbook seq.yaml
    187    sudo vim rep.yaml
    188    sudo vim seq.yaml
    189    ansible all -bm shell -a "ls -lrt /home/ansadmin | Dev"
    190    ansible all -bm shell -a "ls -lrt /home/ansadmin | grep Dev"
    191    sudo vim copie.yaml
    192    ls
    193    sudo vim copie.yaml
    194    ls
    195    sudo vim copie.yaml
    196    sudo vim template.yaml
    197    ansible-playbook template.yaml
    198    sudo vim index.html.j2
    199    ansible-playbook template.yaml
    200    sudo vim template.yaml
    201    sudo vim index.html.j2
    202    ansible-playbook template.yaml
    203    sudo vim index.html.j2
    204    ansible-playbook template.yaml
    205    sudo vim index.html.j2
    206    ansible-playbook template.yaml
    207    sudo vim index.html.j2
    208    ansible-playbook template.yaml
    209    cp index.html.j2 index.html1.j2
    210    sudo vim index.html1.j2
    211    sudo vim index.html.j2
    212    ansible-playbook template.yaml
    213    sudo vim index.html.j2
    214    ansible-playbook template.yaml
    215    sudo vim index.html.j2
    216    sudo vim index.html1.j2
    217    sudo vim index.html.j2
    218    sudo vim index.html1.j2
    219    sudo vim index.html.j2
    220    sudo vim index.html1.j2
    221    cp template.yaml template1.yaml
    222    sudo vim template1.yaml
    223    ansible-playbook template1.yaml
    224    sudo vim template1.yaml
    225    ls
    226    sudo vim exo4.yaml
    227    sudo vim exo3.yaml
    228    sudo vim template1.yaml
    229    ansible-playbook template1.yaml
    230    sudo vim template1.yaml
    231    ansible-playbook template1.yaml
    232    sudo vim template1.yaml
    233    ansible-playbook template1.yaml
    234    sudo vim template1.yaml
    235    ansible-playbook template1.yaml
    236    sudo vim template1.yaml
    237    sudo vim template.yaml
    238    sudo vim template1.yaml
    239    ansible-playbook template1.yaml
    240    sudo vim template1.yaml
    241    ansible-playbook template1.yaml
    242    wq
    243    sudo vim template1.yaml
    244    ansible-vault create hello.yml
    245    ansible-vahello.yaml
    246    cat template1.yaml >> hello.yaml
    247    ansible-playbook hello.yaml
    248    ansible-playbook hello.yaml --ask-vault-pass
    249    ansible-vault edit
    250    ansible-vault create hello.yml
    251    sudo vim hello.yaml
    252    ansible-playbook hello.yaml --ask-vault-pass
    253    sudo vim hello.yaml
    254    ansible-playbook hello.yaml --ask-vault-pass
    255    sudo vim hello.yaml
    256    ansible-vault encrypt when2.yaml
    257    ansible-vault encrypt hello.yaml
    258    cat hello.yaml
    259    cat hello.yaml
    260    sudo vim play-vars.yaml
    261    ansible-playbook play-vars.yaml --ask-vault-pass
    262    ansible-vault create play-vars.yml
    263    cat play-vars.yaml >> play-vars.yml
    264    sudo vim play-vars.yml
    265    ansible-playbook play-vars.yml --ask-vault-pass
    266    sudo vim play-vars.yml
    267    ansible-playbook play-vars.yml --ask-vault-pass
    268    sudo vim play-vars.yml
    269    ansible-playbook play-vars.yml --ask-vault-pass
    270    sudo vim play-vars.yml
    271    ansible-playbook play-vars.yml --ask-vault-pass
    272    sudo vim locale.yml
    273    cat play-vars.yml >> locale.yml
    274    sudo cat play-vars.yml >> locale.yml
    275    sudo vim play-vars.yml
    276    sudo vim locale.yml
    277    ansible-playbook locale.yml
    278    sudo vim locale.yml
    279    ansible-playbook locale.yml
    280    sudo vim locale.yml
    281    sudo vim play-vars.yml
    282    sudo vim var_dic.yml
    283    ansible-playbook var_dic.yml
    284    sudo vim var_dic.yml
    285    ansible-playbook var_dic.yml
    286    cp var_dic.yml var_dic1.yml
    287    sudo vim var_dic1.yml
    288    ansible-playbook var_dic1.yml
    289    sudo vim var_dic1.yml
    290    ansible-playbook var_dic1.yml
    291    sudo vim var_dic1.yml
    292    ansible-playbook var_dic1.yml
    293    sudo vim var_dic1.yml
    294    ansible-playbook var_dic1.yml
    295    sudo vim var_dic1.yml
    296    ansible-playbook var_dic1.yml
    297    sudo vim var_dic1.yml
    298    ansible-playbook var_dic1.yml
    299    sudo vim var_dic1.yml
    300    ansible-playbook var_dic1.yml
    301    sudo vim var_dic1.yml
    302    ansible-playbook var_dic1.yml
    303    sudo vim var_dic1.yml
    304    ansible-playbook var_dic1.yml
    305    sudo vim var_dic1.yml
    306    ansible-playbook var_dic1.yml
    307    sudo vim var_dic1.yml
    308    ansible-playbook var_dic1.yml
    309    sudo vim var_dic1.yml
    310    ansible-playbook var_dic1.yml
    311    sudo vim var_dic1.yml
    312    ansible-playbook var_dic1.yml
    313    sudo vim var_dic1.yml
    314    ansible-playbook var_dic1.yml
    315    sudo vim var_dic1.yml
    316    ansible-playbook var_dic1.yml
    317    ansible-playbook var_dic1.yml
    318    cp vim var_dic1.yml var_dic2.yml
    319    cp var_dic1.yml var_dic2.yml
    320    sudo vim var_dic2.yml
    321    mv var_dic2.yml vars.yml
    322    sudo vim vars.yml
    323    sudo vim vars_files.yml
    324    mv var_dic2.yml vars.yml
    325    sudo vim var_dic2.yml
    326    mv var_dic1.yml var_dic2.yml
    327    sudo vim var_dic2.yml
    328    ansible-playbook var_dic2.yml
    329    sudo vim var_dic2.yml
    330    ansible-playbook var_dic2.yml
    331    ansible-playbook var_dic2.yml --extra-vars="type=web"
    332    sudo vim var_dic2.yml
    333    ls
    334    cp var_dic2.yml var_dic_multi3.yml
    335    sudo vim var_dic_multi3.yml
    336    sudo vim vars_multi.yml
    337    sudo vim var_dic_multi3.yml
    338    sudo vim var_dic2.yml
    339    sudo vim var_dic1.yml
    340    sudo vim var_dic2.yml
    341    sudo vim var_dic_multi3.yml
    342    ansible-playbook var_dic_multi3.yml
    343    sudo vim var_dic_multi3.yml
    344    ansible-playbook var_dic_multi3.yml
    345    sudo vim var_dic_multi3.yml
    346    sudo vim var_dic2.yml
    347    sudo vim var_dic_multi3.yml
    348    ansible-playbook var_dic_multi3.yml
    349    sudo vim var_dic_multi3.yml
    350    sudo vim vars_multi.yml
    351    sudo vim var_dic_multi3.yml
    352    ansible-playbook var_dic_multi3.yml
    353    sudo vim var_dic_multi3.yml
    354    ansible-playbook var_dic_multi3.yml
    355    sudo vim var_dic_multi3.yml
    356    ansible-playbook var_dic_multi3.yml
    357    sudo vim var_dic_multi3.yml
    358    cat var_dic_multi3.yml
    359    head var_dic_multi3.yml
    360    head -n20 var_dic_multi3.yml
    361    head -n30 var_dic_multi3.yml
    362    sudo vim var_dic_multi3.yml
    363    rm    var_dic_multi3.yml
    364    sudo vim var_dic_multi3.yml
    365    ansible-playbook var_dic_multi3.yml
    366    sudo vim vars.yml
    367    cp vim vars.yml vars2.yml
    368    sudo vim vars2.yml
    369    cp vars.yml vars2.yml
    370    sudo vim vars2.yml
    371    cp var_dic_multi3.yml var_dic_multi4.yml
    372    sudo vim var_dic_multi4.yml
    373    ls
    374    sudo vim var_dic.yml
    375    sudo vim var_dic2.yml
    376    sudo vim var_dic_multi4.yml
    377    sudo vim var_dic.yml
    378    sudo vim var_dic_multi4.yml
    379    sudo vim var_dic.yml
    380    sudo vim var_dic2.yml
    381    sudo vim var_dic_multi4.yml
    382    ansible-playbook var_dic_multi4.yml
    383    sudo vim var_dic_multi4.yml
    384    ansible-playbook var_dic_multi4.yml
    385    sudo vim var_dic_multi4.yml
    386    ansible-playbook var_dic_multi4.yml
    387    sudo vim var_dic_multi4.yml
    388    sudo vim vars2.yml
    389    sudo vim var_dic_multi4.yml
    390    ansible-playbook var_dic_multi4.yml
    391    sudo vim var_dic_multi4.yml
    392    ansible-playbook var_dic_multi4.yml
    393    sudo vim var_dic_multi4.yml
    394    ansible-playbook var_dic_multi4.yml
    395    sudo vim var_dic_multi4.yml
    396    ansible-playbook var_dic_multi4.yml
    397    sudo vim var_dic_multi4.yml
    398    ansible-playbook var_dic_multi4.yml
    399    sudo vim var_dic_multi4.yml
    400    ansible-playbook var_dic_multi4.yml
    401    sudo vim var_dic_multi4.yml
    402    ansible-playbook var_dic_multi4.yml
    403    sudo vim var_dic_multi4.yml
    404    ansible-playbook var_dic_multi4.yml
    405    sudo vim var_dic_multi4.yml
    406    ansible-playbook var_dic_multi4.yml
    407    sudo vim var_dic_multi4.yml
    408    ansible-playbook var_dic_multi4.yml
    409    q
    410    sudo vim var_dic_multi4.yml
    411    ansible-playbook var_dic_multi4.yml
    412    sudo vim var_dic_multi4.yml
    413    ansible-playbook var_dic_multi4.yml
    414    sudo vim var_dic_multi4.yml
    415    ansible-playbook var_dic_multi4.yml
    416    sudo vim var_dic_multi4.yml
    417    ansible-playbook var_dic_multi4.yml
    418    sudo vim vars2.yml
    419    sudo vim var_dic_multi4.yml
    420    ansible-playbook var_dic_multi4.yml
    421    sudo vim var_dic_multi4.yml
    422    ansible-playbook var_dic_multi4.yml --extra-vars "type=web"
    423    ansible-playbook var_dic_multi4.yml --extra-vars "type=db"
    424    sudo vim var_dic_multi4.yml
    425    ansible-playbook var_dic_multi4.yml --extra-vars "type=db"
    426    ansible-playbook var_dic_multi4.yml --extra-vars "type=web"
    427    sudo vim var_dic_multi4.yml
    428    ansible-playbook var_dic_multi4.yml --extra-vars "type=web"
    429    sudo vim group.yml
    430    mv vim group.yml inventory.yaml
    431    mv group.yml inventory.yaml
    432    ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"
    433    ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"
    434    sudo vim inventory.yaml
    435    ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"
    436    sudo vim inventory.yaml
    437    ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"
    438    sudo vim inventory.yaml
    439    tree
    440    mkdir host_vars
    441    mkdir group_vars
    442    mkdir projet
    443    mv inventory.yaml var_dic_multi4.yml host_vars group_vars projet/
    444    cd projet/
    445    cd
    446    sudo vim vars2.yml
    447    cp vars2.yml projet/
    448    cd projet/
    449    ls -lrt
    450    mv var_dic_multi4.yml install.yaml
    451    ls -lrt
    452    mv vars2.yml vars_install.yaml
    453    ls -lrt
    454    sudo vim inventory.yaml
    455    cd group_vars/
    456    sudo vim port.yaml
    457    mv port.yaml cible1.yaml
    458    cp cible1.yaml cible2.yaml
    459    cd ..
    460    tree
    461    ansible-playbook -i inventory.yaml var_dic_multi4.yml --extra-vars
"type=web"
    462    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    463    sudo vim inventory.yaml
    464    sudo vim install.yaml
    465    ls -lrt
    466    cd group_vars/
    467    ls
    468    sudo vim cible1.yaml
    469    sudo vim cible2.yaml
    470    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    471    cd
    472    cd projet/
    473    ls
    474    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    475    cd projet/
    476    cd group_vars/
    477    sudo vim cible1.yaml
    478    sudo vim cible2.yaml
    479    cd ..
    480    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    481    cd host_vars/
    482    sudo vim client1.yaml
    483    sudo vim client2.yaml
    484    cd ..
    485    sudo vim install.yaml
    486    cd host_vars/
    487    ls
    488    cd ..
    489    sudo vim inventory.yaml
    490    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    491    sudo vim install.yaml
    492    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    493    cd host_vars/
    494    sudo vim client1.yaml
    495    sudo vim client2.yaml
    496    cd ..
    497    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    498    sudo vim install.yaml
    499    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    500    sudo vim install.yaml
    501    cd host_vars/
    502    ls
    503    ll
    504    cd ..
    505    cd group_vars/
    506    ls
    507    sudo vim cible1.yaml
    508    cd ..
    509    cd host_vars/
    510    ls
    511    sudo vim client1.yaml
    512    sudo vim client2.yaml
    513    cd ..
    514    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    515    sudo vim install.yaml
    516    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    517    sudo vim install.yaml
    518    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    519    sudo vim install.yaml
    520    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    521    sudo vim install.yaml
    522    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    523    sudo vim install.yaml
    524    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    525    sudo vim install.yaml
    526    cd
    527    sudo vim debug.yaml
    528    cd projet/
    529    sudo vim install.yaml
    530    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    531    sudo vim install.yaml
    532    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    533    sudo vim inventory.yaml
    534    cd group_vars/
    535    ls
    536    sudo vim cible1.yaml
    537    sudo vim cible2.yaml
    538    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    539    cd ..
    540    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    541    sudo vim install.yaml
    542    cd host_vars/
    543    ls
    544    sudo vim client1.yaml
    545    sudo vim client2.yaml
    546    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    547    cd ..
    548    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    549    sudo vim install.yaml
    550    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    551    sudo vim install.yaml
    552    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    553    cd host_vars/
    554    ls
    555    sudo vim client1.yaml
    556    sudo vim client2.yaml
    557    cd ..
    558    cd group_vars/
    559    ls
    560    sudo vim cible1.yaml
    561    sudo vim cible2.yaml
    562    cd ..
    563    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    564    sudo vim install.yaml
    565    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    566    sudo vim install.yaml
    567    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    568    sudo vim install.yaml
    569    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    570    sudo vim install.yaml
    571    ansible-playbook -i inventory.yaml install.yaml --extra-vars "type=web"
    572    ll
    573    tree
    574    cd
    575    mkdir projet1
    576    cd projet1
    577    mkdir roles
    578    cd roles/
    579    mkdir apache
    580    cd apache/
    581    tree
    582    pwd
    583    mkdir tasks vars templates handlers
    584    tree
    585    touch tasks/main.yml
    586    touch vars/main.yml
    587    touch handlers/main.yml
    588    tree
    589    sudo vim tasks/main.yml
    590    sudo vim vars/main.yml
    591    sudo vim templates/index.html.j2
    592    cd ..
    593    sudo vim hosts.yml
    594    sudo vim templates/index.html.j2
    595    cd roles/apache
    596    sudo vim templates/index.html.j2
    597    sudo vim vars/main.yml
    598    cd ..
    599    ansible-playbook -i hosts.yml site.yml
    600    sudo vim hosts.yml
    601    ansible-playbook -i hosts.yml site.yml
    602    tree
    603    curl client1
    604    tree
    605    mkdir group_vars
    606    mkdir hosts_vars
    607    cat roles/apache/tasks/main.yml
    608    cat roles/apache/handlers/main.yml
    609    cat roles/apache/vars/main.yml
    610    cat roles/apache/templates/index.html.j2
    611    sudo vim site.yml
    612    ansible-playbook -i hosts.yml site.yml
    613    sudo vim roles/apache/vars/main.yml
    614    ansible-playbook -i hosts.yml site.yml
    615    sudo vim roles/apache/vars/main.yml
    616    tree
    617    ansible-playbook -i hosts.yml site.yml
    618    cat roles/apache/templates/index.html.j2
    619    sudo vim roles/apache/vars/main.yml
    620    cat roles/apache/templates/index.html.j2
    621    ansible-playbook -i hosts.yml site.yml
    622    sudo vim roles/apache/tasks/main.yml
    623    ansible-playbook -i hosts.yml site.yml
    624    tree
    625    ansible-playbook -i hosts.yml site.yml
    626    sudo vim roles/apache/vars/main.yml
    627    ansible-playbook -i hosts.yml site.yml
    628    cd
    629    sudo vim /etc/hosts
    630    cd projet1/
    631    ansible-playbook -i hosts.yml site.yml
    632    tree
    633    cat hosts.yml
    634    ansible-playbook -i hosts.yml site.yml
    635    cd
    636    sudo vim /etc/hosts
    637    cd projet1/
    638    ansible -i hosts.yml client1 -m ping
    639    cd roles/
    640    ls
    641    cd apache/
    642    ls
    643    sudo vim vars/main.yml
    644    sudo vim handlers/main.yml
    645    sudo vim templates/index.html.j2
    646    cd ..
    647    ll
    648    cd ..
    649    ll
    650    sudo vim site.yml
    651    ansible-playbook -i hosts.yml site.yml
    652    ansible -i hosts.yml client1 -m ping
    653    tree
    654    cd group_vars/
    655    ls
    656    sudo vim all.yml
    657    cd ..
    658    ansible -i hosts.yml client1 -m ping
    659    ansible-playbook -i hosts.yml site.yml
    660    cd
    661    ansible all -m service -a "name=nginx state= stopped"
    662    sudo vim projet1/roles/apache/vars/
    663    sudo vim projet1/roles/apache/vars/main.yml
    664    cd projet1
    665    tree
    666    cd group_vars/
    667    sudo vim all.yml
    668    cd ..
    669    ansible all -bm service -a "name=nginx state=stopped"
    670    ansible-playbook -i hosts.yml site.yml
    671    tree
    672    sudo vim hosts.yml
    673    curl client1
    674    cd roles/
    675    ls
    676    cp -r apache users
    677    ls
    678    cd users
    679    ls -lrt
    680    tree
    681    cd ..
    682    tree
    683    ll
    684    cd users/
    685    ls
    686    ls -lrt
    687    sudo vim vars/main.yml
    688    sudo vim templates/index.html.j2
    689    sudo vim tasks/main.yml
    690    cd
    691    ls
    692    sudo vim item_users.yaml
    693    cd projet1/roles/users/
    694    sudo vim tasks/main.yml
    695    tree
    696    sudo vim vars/main.yml
    697    cd ..
    698    tree
    699    cd roles/
    700    cd users/
    701    sudo vim vars/main.yml
    702    cd
    703    ls
    704    cd projet
    705    ls
    706    sudo vim vars_install.yaml
    707    cd
    708    cd projet1/roles/users/vars/
    709    sudo vim vars/main.yml
    710    sudo main.yml
    711    sudo vim main.yml
    712    cd ..
    713    ansible-playbook -i hosts.yml site.yml
    714    cd ..
    715    ansible-playbook -i hosts.yml site.yml
    716    cd roles/
    717    ansible-playbook -i hosts.yml site.yml
    718    ls
    719    mv users /home/ansadmin/
    720    cd
    721    ls
    722    mv users projet2
    723    cd projet2
    724    ls
    725    tree
    726    mkdir roles
    727    cd ..
    728    ls
    729    cd projet2
    730    ls
    731    mv handlers tasks templates vars roles/
    732    ls
    733    cd roles/
    734    ls
    735    mkdir user
    736    ls
    737    mv handlers tasks templates vars user/
    738    cd ..
    739    tree
    740    sudo vim roles/user/handlers/main.yml
    741    cd
    742    cd projet1/
    743    ls
    744    cp group_vars hosts_vars hosts.yml site.yml ../projet2
    745    cp -r group_vars hosts_vars hosts.yml site.yml ../projet2
    746    cd ..
    747    cd projet2
    748    tree
    749    ansible-playbook -i hosts.yml site.yml
    750    tree
    751    sudo vim site.yml
    752    ansible-playbook -i hosts.yml site.yml
    753    sudo vim roles/user/tasks/main.yml
    754    ansible-playbook -i hosts.yml site.yml
    755    sudo vim roles/user/tasks/main.yml
    756    cd
    757    ls
    758    sudo vim var_dic_multi3.yml
    759    cd projet2
    760    sudo vim roles/user/tasks/main.yml
    761    ansible-playbook -i hosts.yml site.yml
    762    sudo vim roles/user/tasks/main.yml
    763    tree
    764    sudo vim roles/user/vars/main.yml
    765    ansible-playbook -i hosts.yml site.yml
    766    sudo vim roles/user/tasks/main.yml
    767    ansible-playbook -i hosts.yml site.yml
    768    sudo vim roles/user/tasks/main.yml
    769    ansible-playbook -i hosts.yml site.yml
    770    sudo vim roles/user/tasks/main.yml
    771    ansible-playbook -i hosts.yml site.yml
    772    sudo vim roles/user/tasks/main.yml
    773    ansible-playbook -i hosts.yml site.yml
    774    sudo vim roles/user/tasks/main.yml
    775    ansible-playbook -i hosts.yml site.yml
    776    sudo vim roles/user/tasks/main.yml
    777    ansible-playbook -i hosts.yml site.yml
    778    sudo vim roles/user/tasks/main.yml
    779    ansible-playbook -i hosts.yml site.yml
    780    sudo vim roles/user/tasks/main.yml
    781    tree
    782    sudo vim site.yml
    783    ansible-playbook -i hosts.yml site.yml
    784    sudo vim hosts.yml
    785    tree
    786    cd roles
    787    mv user/ users/
    788    cd ..
    789    tree
    790    sudo vim site.yml
    791    sudo vim roles/user/tasks/main.yml
    792    sudo vim roles/users/tasks/main.yml
    793    sudo vim roles/users/templates/index.html.j2
    794    sudo vim hosts.yml
    795    sudo vim site.yml
    796    sudo vim roles/users/vars/main.yml
    797    ansible-playbook -i hosts.ymlsite.yml
    798    ansible-playbook -i hosts.yml site.yml
    799    sudo vim roles/users/tasks/main.yml
    800    ansible-playbook -i hosts.yml site.yml
    801    sudo vim roles/users/tasks/main.yml
    802    ansible-playbook -i hosts.yml site.yml
    803    tree
    804    ansible-playbook -i hosts.yml site.yml
    805    sudo vim roles/users/vars/main.yml
    806    sudo vim roles/users/templates/index.html.j2
    807    ansible-playbook -i hosts.yml site.yml
    808    sudo vim roles/users/tasks/main.yml
    809    ansible-playbook -i hosts.yml site.yml
    810    sudo vim roles/users/tasks/main.yml
    811    ansible-playbook -i hosts.yml site.yml
    812    sudo vim roles/users/tasks/main.yml
    813    ansible-playbook -i hosts.yml site.yml
    814    cd
    815    ansible-galaxy init projet3
    816    cd projet3
    817    tree
    818    cd
    819    ansible-galaxy install projet3 geerlingguy.apache
    820    ansible-galaxy install geerlingguy.apache
    821    mkdir projet4
    822    ansible-galaxy install geerlingguy.apache -p projet4
    823    cd projet4
    824    tree
    825    cd geerlingguy.apache
    826    ls -lrt
    827    cd tasks/
    828    ls
    829    sudo vim main.yml
    830    cd ..
    831    tree
    832    cd
    833    tree
    834    ansible-playbook -i projet
    835    cd projet4/geerlingguy.apache/
    836    sudo vim site.yml
    837    cd
    838    cd projet2
    839    ls
    840    cp hosts.yml ../projet4/
    841    cd
    842    cd projet4
    843    ansible-playbook -i hosts.yml site.yml
    844    tree
    845    :q
    846    cd
    847    cd projet2
    848    cp site.yml ../projet4/
    849    cd
    850    cd projet4
    851    ansible-playbook -i hosts.yml site.yml
    852    tree
    853    sudo vim site.yml
    854    ansible-playbook -i hosts.yml site.yml
    855    tree
    856    sudo vim site.yml
    857    sudo vim hosts.yml
    858    ansible-playbook -i hosts.yml site.yml
    859    cd
    860    cd projet2
    861    ls
    862    cp -r group_vars hosts_vars ../projet4/
    863    cd
    864    cd projet4
    865    ansible-playbook -i hosts.yml site.yml
    866    tree
    867    history
ansadmin@svl200:~$
ansadmin@svl200:~$ ansible-playbook -i hosts.yml .yml
.ansible/                      TP3/                                fact.yaml         
item_users.yaml          projet1/                        template1.yaml
.bash_history              TPansible/                    fact1.yaml                 
items.yaml                    projet2/                        var_dic.yml
.bash_logout                cible1.txt                    handler.yaml               
items_users.yaml        projet3/                        var_dic2.yml
.bashrc                          copie.yaml                    hello.yaml           
list.yaml                      projet4/                        var_dic_multi3.yml
.exo4.yaml.swp            debug.yaml                    hello.yml                   
locale.yml                    rep.yaml                        vars.yml
.handler.yaml.swp      debug1.yaml                  index.html                   
nginx.yaml                    seq.yaml                        vars2.yml
.profile                        exo2.yaml                      index.html.j2         
play-vars.yaml            shell.yml                      vars_multi.yml
.ssh/                              exo3.yaml                      index.html1.j2     
play-vars.yml              snap/                              when.yaml
.viminfo                        exo4.yaml                      ip.txt               
projet/                          template.yaml              when1.yaml
ansadmin@svl200:~$ ansible-playbook -i hosts.yml main.yml -u apx28
ERROR! the playbook: main.yml could not be found
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -u apx28

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [141.95.160.128]

TASK [partition1]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
ok: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
ok: [141.95.160.128]
PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=5      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ sudo vim main.yml


ansadmin@svl200:~/TPansible$ sudo vim main.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -u apx28

PLAY [partition lvm]


*************************************************************************************
**************************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [141.95.160.128]

TASK [partition1]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
ok: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
ok: [141.95.160.128]

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=5      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    main.yml    roles    site.yml
ansadmin@svl200:~/TPansible$ sudo vim main.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main.yml -u apx28

PLAY [partition lvm]


*************************************************************************************
**************************
TASK [Gathering Facts]
*************************************************************************************
************************
ok: [141.95.160.128]

TASK [partition1]
*************************************************************************************
*****************************
ok: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
ok: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
changed: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
changed: [141.95.160.128]

TASK [partition2]
*************************************************************************************
*****************************
changed: [141.95.160.128]

TASK [creation de fichier]


*************************************************************************************
********************
ok: [141.95.160.128]

TASK [filesystem]
*************************************************************************************
*****************************
changed: [141.95.160.128]

TASK [montage]
*************************************************************************************
********************************
changed: [141.95.160.128]

PLAY RECAP
*************************************************************************************
************************************
141.95.160.128                          : ok=9      changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    main.yml    roles    site.yml
ansadmin@svl200:~/TPansible$ sudo vim main_base.yml
ansadmin@svl200:~/TPansible$ cat main.yml
---
- name: partition lvm
    hosts: all
    become: true

    tasks:
        - name: partition1
            lvol:
                vg: datavg
                lv: ansible_lv1_aaw
                size: 250M
                force: yes

        - name: creation de fichier


            file:
                    path: /tp3_aaw
                    state: directory
                    mode: 755

        - name: filesystem
            filesystem:
                fstype: xfs
                dev: /dev/datavg/ansible_lv1_aaw

        - name: montage
            mount:
                  path: /tp3_aaw
                  src: /dev/datavg/ansible_lv1_aaw
                  fstype: xfs
                  state: mounted

        - name: partition2
            lvol:
                vg: datavg
                lv: ansible_lv2_aaw
                size: 250M
                force: yes

        - name: creation de fichier


            file:
                    path: /tp3_aaw
                    state: directory
                    mode: 755

        - name: filesystem
            filesystem:
                fstype: xfs
                dev: /dev/datavg/ansible_lv2_aaw

        - name: montage
            mount:
                  path: /tp3_aaw
                  src: /dev/datavg/ansible_lv2_aaw
                  fstype: xfs
                  state: mounted

ansadmin@svl200:~/TPansible$ ^C
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_base.yml
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ sudo vim hosts.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_.yml -u apx28
main_base.yml            main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml -u apx28

PLAY [install postgresql on Ubuntu or Debian]


*************************************************************************************
*

TASK [Gathering Facts]


*************************************************************************************
************************
fatal: [146.59.158.16]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: [email protected]: Permi                                     
ssion denied (publickey,password).", "unreachable": true}

PLAY RECAP
*************************************************************************************
************************************
146.59.158.16                            : ok=0        changed=0        unreachable=1
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql on Ubuntu or Debian]


*************************************************************************************
*

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [debug]
*************************************************************************************
**********************************
ok: [146.59.158.16] => {
        "msg": "play_hosts=['146.59.158.16']"
}

TASK [debug]
*************************************************************************************
**********************************
ok: [146.59.158.16] => {
        "msg": "ansible_distribution=Ubuntu"
}
TASK [postgresql key]
*************************************************************************************
*************************
changed: [146.59.158.16]

TASK [create variable]


*************************************************************************************
************************
changed: [146.59.158.16]

TASK [debug]
*************************************************************************************
**********************************
ok: [146.59.158.16] => {
        "msg": "deb http://apt.postgresql.org/pub/repos/apt/ focal-pgdg main"
}

TASK [add postgresql repo]


*************************************************************************************
********************
changed: [146.59.158.16]

TASK [install postgresql]


*************************************************************************************
*********************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was: 'postgresql_versi                                 
on' is undefined\n\nThe error appears to be in
'/home/ansadmin/TPansible/main_postgres.yml': line 30, column 5, but may\nbe elsewher
e in the file depending on the exact syntax problem.\n\nThe offending line appears to
be:\n\n\n    - name: install postgresql\n        ^ h                                 
ere\n"}

PLAY RECAP
*************************************************************************************
************************************
146.59.158.16                            : ok=7      changed=3      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ sudo vim main_base.yml
ansadmin@svl200:~/TPansible$ ls
group_vars    hosts.yml    hosts_vars    main.yml    main_base.yml   
main_postgres.yml    roles    site.yml
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql on Ubuntu or Debian]


*************************************************************************************
*

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [installation postgresql]


*************************************************************************************
****************
ok: [146.59.158.16]

PLAY RECAP
*************************************************************************************
************************************
146.59.158.16                            : ok=2      changed=0        unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*************************************************************************************
**************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [installation postgresql]


*************************************************************************************
****************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "No package matching
'posgresql' is available"}

PLAY RECAP
*************************************************************************************
************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*************************************************************************************
**************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [installation postgresql]


*************************************************************************************
****************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Unsupported parameters
for (apt_key) module: name Supported parameters                                     
include: data, file, id, key, keyring, keyserver, state, url, validate_certs"}

PLAY RECAP
*************************************************************************************
************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*************************************************************************************
**************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [installation postgresql]


*************************************************************************************
****************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "No package matching
'posgresql' is available"}

PLAY RECAP
*************************************************************************************
************************************
146.59.158.16                            : ok=1      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*************************************************************************************
**************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


*************************************************************************************
********
changed: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*************************
changed: [146.59.158.16]
TASK [acl]
*************************************************************************************
************************************
changed: [146.59.158.16]

TASK [installation postgresql]


*************************************************************************************
****************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "No package matching
'posgresql' is available"}

PLAY RECAP
*************************************************************************************
************************************
146.59.158.16                            : ok=4      changed=3      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*************************************************************************************
**************

TASK [Gathering Facts]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


*************************************************************************************
********
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*************************
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
************************************
ok: [146.59.158.16]

TASK [installation postgresql]


*************************************************************************************
****************
changed: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*************************
ok: [146.59.158.16]
PLAY RECAP
*************************************************************************************
************************************
146.59.158.16                            : ok=6      changed=1      unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ sudo vim main_houcem.yml
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
changed: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=2      unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0                         

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ cp /home/ofi03/psql.yml /home/ofi03/dump.sql .
ansadmin@svl200:~/TPansible$ ls
dump.sql        hosts.yml      main.yml              main_houcem.yml        psql.yml 
site.yml
group_vars    hosts_vars    main_base.yml    main_postgres.yml    roles
ansadmin@svl200:~/TPansible$ sudo vim psql.yml
ansadmin@svl200:~/TPansible$ sudo vim dump.sql
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml psql.yml
ERROR! Syntax Error while loading YAML.
    did not find expected key

The error appears to be in '/home/ansadmin/TPansible/psql.yml': line 3, column 6, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

        - name: Install dependencies for PostgreSQL


          apt: name={{ item }} update_cache=true state=latest
          ^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:

        with_items:
            - {{ foo }}

Should be written as:

        with_items:
            - "{{ foo }}"
ansadmin@svl200:~/TPansible$ sudo vim psql.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml psql.yml
ERROR! A playbook must be a list of plays, got a <class
'ansible.parsing.yaml.objects.AnsibleMapping'> instead

The error appears to be in '/home/ansadmin/TPansible/psql.yml': line 1, column 1, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

tasks:
^ here
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ sudo vim psql.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml psql.yml
PLAY [install postgresql and BD]
*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [Install dependencies for PostgreSQL]


***********************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['bash', 'openssl',
'libssl-dev', 'libssl-doc']` and remove the loop. This feature will be removed in
version 2.11. Deprecation
warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
changed: [146.59.158.16] => (item=['bash', 'openssl', 'libssl-dev', 'libssl-doc'])

TASK [Install PostgreSQL]


*************************************************************************************
***
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['postgresql',
'postgresql-contrib', 'libpq-dev', 'python3-psycopg2']` and remove the loop. This
feature will be removed in
version 2.11. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.
changed: [146.59.158.16] => (item=['postgresql', 'postgresql-contrib', 'libpq-dev',
'python3-psycopg2'])

TASK [Ensure the PostgreSQL service is running]


******************************************************************
ok: [146.59.158.16]

TASK [Create the database specified in vars]


*********************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was:                                                   
'db_name' is undefined\n\nThe error appears to be in
'/home/ansadmin/TPansible/psql.yml': line 27, column 5, but                          
may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n\n    -                                                       
name: Create the database specified in vars\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=4      changed=2      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$ sudo vim psql.yml


ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml psql.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [Install dependencies for PostgreSQL]


***********************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['bash', 'openssl',
'libssl-dev', 'libssl-doc']` and remove the loop. This feature will be removed in
version 2.11. Deprecation
warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [146.59.158.16] => (item=['bash', 'openssl', 'libssl-dev', 'libssl-doc'])

TASK [Install PostgreSQL]


*************************************************************************************
***
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['postgresql',
'postgresql-contrib', 'libpq-dev', 'python3-psycopg2']` and remove the loop. This
feature will be removed in
version 2.11. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.
ok: [146.59.158.16] => (item=['postgresql', 'postgresql-contrib', 'libpq-dev',
'python3-psycopg2'])

TASK [Ensure the PostgreSQL service is running]


******************************************************************
ok: [146.59.158.16]

TASK [Create the database specified in vars]


*********************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was:                                                   
'db_name' is undefined\n\nThe error appears to be in
'/home/ansadmin/TPansible/psql.yml': line 27, column 5, but                          
may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n\n    -                                                       
name: Create the database specified in vars\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=4      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           
ansadmin@svl200:~/TPansible$ sudo vim psql.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml psql.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [Install dependencies for PostgreSQL]


***********************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['bash', 'openssl',
'libssl-dev', 'libssl-doc']` and remove the loop. This feature will be removed in
version 2.11. Deprecation
warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [146.59.158.16] => (item=['bash', 'openssl', 'libssl-dev', 'libssl-doc'])

TASK [Install PostgreSQL]


*************************************************************************************
***
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['postgresql',
'postgresql-contrib', 'libpq-dev', 'python3-psycopg2']` and remove the loop. This
feature will be removed in
version 2.11. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.
ok: [146.59.158.16] => (item=['postgresql', 'postgresql-contrib', 'libpq-dev',
'python3-psycopg2'])

TASK [Ensure the PostgreSQL service is running]


******************************************************************
ok: [146.59.158.16]

TASK [Create the database specified in vars]


*********************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was:                                                   
'db_name' is undefined\n\nThe error appears to be in
'/home/ansadmin/TPansible/psql.yml': line 27, column 5, but                          
may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n\n    -                                                       
name: Create the database specified in vars\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=4      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$ sudo vim psql.yml


ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml psql.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [Install dependencies for PostgreSQL]


***********************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['bash', 'openssl',
'libssl-dev', 'libssl-doc']` and remove the loop. This feature will be removed in
version 2.11. Deprecation
warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [146.59.158.16] => (item=['bash', 'openssl', 'libssl-dev', 'libssl-doc'])

TASK [Install PostgreSQL]


*************************************************************************************
***
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['postgresql',
'postgresql-contrib', 'libpq-dev', 'python3-psycopg2']` and remove the loop. This
feature will be removed in
version 2.11. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.
ok: [146.59.158.16] => (item=['postgresql', 'postgresql-contrib', 'libpq-dev',
'python3-psycopg2'])

TASK [Ensure the PostgreSQL service is running]


******************************************************************
ok: [146.59.158.16]

TASK [Create the database specified in vars]


*********************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was:                                                   
'db_name' is undefined\n\nThe error appears to be in
'/home/ansadmin/TPansible/psql.yml': line 27, column 5, but                          
may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n\n    -                                                       
name: Create the database specified in vars\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=4      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml psql.yml dump.sql

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [Install dependencies for PostgreSQL]


***********************************************************************
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['bash', 'openssl',
'libssl-dev', 'libssl-doc']` and remove the loop. This feature will be removed in
version 2.11. Deprecation
warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
ok: [146.59.158.16] => (item=['bash', 'openssl', 'libssl-dev', 'libssl-doc'])

TASK [Install PostgreSQL]


*************************************************************************************
***
[DEPRECATION WARNING]: Invoking "apt" only once while using a loop via squash_actions
is deprecated. Instead of
using a loop to supply multiple items and specifying `name: "{{ item }}"`, please use
`name: ['postgresql',
'postgresql-contrib', 'libpq-dev', 'python3-psycopg2']` and remove the loop. This
feature will be removed in
version 2.11. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.
ok: [146.59.158.16] => (item=['postgresql', 'postgresql-contrib', 'libpq-dev',
'python3-psycopg2'])

TASK [Ensure the PostgreSQL service is running]


******************************************************************
ok: [146.59.158.16]

TASK [Create the database specified in vars]


*********************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was:                                                   
'db_name' is undefined\n\nThe error appears to be in
'/home/ansadmin/TPansible/psql.yml': line 27, column 5, but                          
may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending
line appears to be:\n\n\n    -                                                       
name: Create the database specified in vars\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=4      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0                         

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim psql.yml
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml dump.sql

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was:                                                   
'db_name' is undefined\n\nThe error appears to be in
'/home/ansadmin/TPansible/main_postgres.yml': line 47, colum                         
n 5, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe
offending line appears to be:                                                       
\n\n\n    - name: Add some dummy data to our database\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml dump.sql

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"msg": "The task includes an option with an
undefined variable. The error was:                                                   
'db_name' is undefined\n\nThe error appears to be in
'/home/ansadmin/TPansible/main_postgres.yml': line 47, colum                         
n 5, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe
offending line appears to be:                                                       
\n\n\n    - name: Add some dummy data to our database\n        ^ here\n"}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml dump.sql

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]
TASK [Add some dummy data to our database]
***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/tmp/dump.sql", "delta": "0:00:00.002988                                             
", "end": "2022-10-06 13:11:15.012221", "msg": "non-zero return code", "rc": 2,
"start": "2022-10-06 13:11:15.0092                                                   
33", "stderr": "/bin/sh: 1: cannot open /tmp/dump.sql: No such file", "stderr_lines":
["/bin/sh: 1: cannot open /t                                                         
mp/dump.sql: No such file"], "stdout": "", "stdout_lines": []}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]
TASK [start servicde]
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/tmp/dump.sql", "delta": "0:00:00.003017                                             
", "end": "2022-10-06 13:11:59.191666", "msg": "non-zero return code", "rc": 2,
"start": "2022-10-06 13:11:59.1886                                                   
49", "stderr": "/bin/sh: 1: cannot open /tmp/dump.sql: No such file", "stderr_lines":
["/bin/sh: 1: cannot open /t                                                         
mp/dump.sql: No such file"], "stdout": "", "stdout_lines": []}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": true, "cmd": "psql dbofi < dump.sql",
"delta": "0:00:00.003182", "e                                                       
nd": "2022-10-06 13:13:33.478163", "msg": "non-zero return code", "rc": 2, "start":
"2022-10-06 13:13:33.474981",                                                        
"stderr": "/bin/sh: 1: cannot open dump.sql: No such file", "stderr_lines":
["/bin/sh: 1: cannot open dump.sql: No                                               
such file"], "stdout": "", "stdout_lines": []}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ls
dump.sql        hosts.yml      main.yml              main_houcem.yml        psql.yml 
site.yml
group_vars    hosts_vars    main_base.yml    main_postgres.yml    roles
ansadmin@svl200:~/TPansible$ pwd
/home/ansadmin/TPansible
ansadmin@svl200:~/TPansible$ ^C
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/home/ansadmin/TPansible/dump.sql", "del                                             
ta": "0:00:00.003189", "end": "2022-10-06 13:15:23.043889", "msg": "non-zero return
code", "rc": 2, "start": "2022                                                       
-10-06 13:15:23.040700", "stderr": "/bin/sh: 1: cannot open
/home/ansadmin/TPansible/dump.sql: No such file", "std                               
err_lines": ["/bin/sh: 1: cannot open /home/ansadmin/TPansible/dump.sql: No such
file"], "stdout": "", "stdout_lin                                                   
es": []}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ls
dump.sql        hosts.yml      main.yml              main_houcem.yml        psql.yml 
site.yml
group_vars    hosts_vars    main_base.yml    main_postgres.yml    roles
ansadmin@svl200:~/TPansible$ mv dump.sql dump.yml
ansadmin@svl200:~/TPansible$ ls
dump.yml        hosts.yml      main.yml              main_houcem.yml        psql.yml 
site.yml
group_vars    hosts_vars    main_base.yml    main_postgres.yml    roles
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/home/ansadmin/TPansible/dump.yml", "del                                             
ta": "0:00:00.003190", "end": "2022-10-06 13:17:06.832266", "msg": "non-zero return
code", "rc": 2, "start": "2022                                                       
-10-06 13:17:06.829076", "stderr": "/bin/sh: 1: cannot open
/home/ansadmin/TPansible/dump.yml: No such file", "std                               
err_lines": ["/bin/sh: 1: cannot open /home/ansadmin/TPansible/dump.yml: No such
file"], "stdout": "", "stdout_lin                                                   
es": []}
PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$ ^C
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
fatal: [146.59.158.16]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/home/ansadmin/TPansible/dump.yml", "del                                             
ta": "0:00:00.003628", "end": "2022-10-06 13:22:28.446963", "msg": "non-zero return
code", "rc": 2, "start": "2022                                                       
-10-06 13:22:28.443335", "stderr": "/bin/sh: 1: cannot open
/home/ansadmin/TPansible/dump.yml: No such file", "std                               
err_lines": ["/bin/sh: 1: cannot open /home/ansadmin/TPansible/dump.yml: No such
file"], "stdout": "", "stdout_lin                                                   
es": []}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=8      changed=1      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ sudo vim /etc/ansible/ansible.cfg
ansadmin@svl200:~/TPansible$ sudo vim /etc/ansible/ansible.cfg
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=9      changed=2      unreachable=0 
failed=0        skipped=0        rescued=0        ignored=0                         

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]
TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]

TASK [sauvegarde]
*************************************************************************************
***********
fatal: [146.59.158.16]: FAILED! => {"changed": false, "cmd": "/usr/bin/pg_dump dbofi
--port=5432 --username=postgr                                                       
es > /tmp/dbofi.sql", "msg": "pg_dump: error: connection to server on socket
\"/var/run/postgresql/.s.PGSQL.5432\"                                               
failed: FATAL:    Peer authentication failed for user \"postgres\"\n", "rc": 1,
"stdout": "", "stdout_lines": []}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=9      changed=2      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml
ERROR! Syntax Error while loading YAML.
    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/TPansible/main_postgres.yml': line 57,


column 13, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: package_python
            target: /tmp/dbofi.sql
                        ^ here
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml
ERROR! this task 'target' has extra params, which is only allowed in the following
modules: include_tasks, script,                                                     
set_fact, raw, shell, include, add_host, import_role, win_command, meta,
include_vars, command, include_role, imp                                             
ort_tasks, win_shell, group_by

The error appears to be in '/home/ansadmin/TPansible/main_postgres.yml': line 56,


column 5, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

            state: pg_dump
    - name: package_python
        ^ here
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]
TASK [sauvegarde]
*************************************************************************************
***********
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "value of state must be
one of: absent, dump, present                                                       
, restore, got: pg_dump"}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=9      changed=2      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]

TASK [sauvegarde]
*************************************************************************************
***********
fatal: [146.59.158.16]: FAILED! => {"changed": false, "cmd": "/usr/bin/pg_dump dbofi
--port=5432 --username=postgr                                                       
es > /tmp/dbofi.sql", "msg": "pg_dump: error: connection to server on socket
\"/var/run/postgresql/.s.PGSQL.5432\"                                               
failed: FATAL:    Peer authentication failed for user \"postgres\"\n", "rc": 1,
"stdout": "", "stdout_lines": []}

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=9      changed=2      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0                           

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]

TASK [sauvegarde]
*************************************************************************************
***********
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=10    changed=3      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0                         

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ cat
dump.yml                      hosts_vars/                main_houcem.yml       
roles/
group_vars/                main.yml                      main_postgres.yml   
site.yml
hosts.yml                    main_base.yml            psql.yml
ansadmin@svl200:~/TPansible$ cat main_postgres.yml
- name: install postgresql and BD
    hosts: cible1
    become: yes
    become_method: sudo
    gather_facts: yes

    tasks:
    - name: installation postgresql-contrib
        apt:
            name: postgresql-contrib
            state: latest

    - name: package_python
        apt:
            name: python3-psycopg2
            state: latest

    - name: acl
        apt:
            name: acl
            state: latest

    - name: installation postgresql


        apt:
            name: postgresql
            state: present

    - name: start servicde


        service:
            name: postgresql
            state: started
            enabled: true

    - name: BD
        postgresql_db:
            state: present
            name: dbofi
        become: true
        become_user: postgres

    - name: start servicde


        service:
            name: postgresql
            state: restarted
            enabled: true

    - name: Add some dummy data to our database


        become: true
        become_user: postgres
        shell: psql dbofi < /home/ansadmin/dump.sql

    - name: sauvegarde
        postgresql_db:
            name: dbofi
            state: dump
            target: /tmp/dbofi_aaw.sql
        become: true
        become_user: postgres
        tags: dump
ansadmin@svl200:~/TPansible$ ^C
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]
TASK [installation postgresql-contrib]
***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]

TASK [sauvegarde]
*************************************************************************************
***********
changed: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=12    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0                         

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]

TASK [sauvegarde]
*************************************************************************************
***********
changed: [146.59.158.16]
TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [Import BD]


*************************************************************************************
************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=12    changed=4      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0                         

ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml


ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml main_postgres.yml

PLAY [install postgresql and BD]


*********************************************************************************

TASK [Gathering Facts]


*************************************************************************************
******
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


***************************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
*******
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
******************
ok: [146.59.158.16]

TASK [installation postgresql]


***********************************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
*******
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


***********************************************************************
changed: [146.59.158.16]

TASK [sauvegarde]
*************************************************************************************
***********
changed: [146.59.158.16]

TASK [BD]
*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [Import BD]


*************************************************************************************
************
changed: [146.59.158.16]

TASK [Add some dummy data to our database dbapx]


*****************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
******************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0                         

ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$ ls
dump.yml        hosts.yml      main.yml              main_houcem.yml        psql.yml 
site.yml
group_vars    hosts_vars    main_base.yml    main_postgres.yml    roles
ansadmin@svl200:~/TPansible$ cd roles
ansadmin@svl200:~/TPansible/roles$ ls
users
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$ ls
users
ansadmin@svl200:~/TPansible/roles$ cp -r users postgres
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$ ls
postgres    users
ansadmin@svl200:~/TPansible/roles$    - name: BD
    - name: Import BD
        become: true
        become_user: postgres
        shell: psql dbapx < /tmp/dbofi_aaw.sql

    - name: Add some dummy data to our database dbapx


        become: true
        become_user: postgres
        shell: psql dbapx < /home/ansadmin/dump.sql
-: command not found
ansadmin@svl200:~/TPansible/roles$          postgresql_db:
postgresql_db:: command not found
ansadmin@svl200:~/TPansible/roles$              state: present

Command 'state:' not found, did you mean:

    command 'states' from deb enscript (1.6.5.90-3)

Try: apt install <deb name>

ansadmin@svl200:~/TPansible/roles$              name: dbapx

Command 'name:' not found, did you mean:

    command 'named' from deb bind9 (1:9.16.1-0ubuntu2.11)


    command 'namei' from deb util-linux (2.34-0.1ubuntu9.3)

Try: apt install <deb name>

ansadmin@svl200:~/TPansible/roles$          become: true


become:: command not found
ansadmin@svl200:~/TPansible/roles$          become_user: postgres
become_user:: command not found
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$      - name: Import BD
-: command not found
ansadmin@svl200:~/TPansible/roles$          become: true
become:: command not found
ansadmin@svl200:~/TPansible/roles$          become_user: postgres
become_user:: command not found
ansadmin@svl200:~/TPansible/roles$          shell: psql dbapx < /tmp/dbofi_aaw.sql
-bash: /tmp/dbofi_aaw.sql: No such file or directory
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$      - name: Add some dummy data to our database
dbapx
-: command not found
ansadmin@svl200:~/TPansible/roles$          become: true
become:: command not found
ansadmin@svl200:~/TPansible/roles$          become_user: postgres
become_user:: command not found
ansadmin@svl200:~/TPansible/roles$          shell: psql dbapx <
/home/ansadmin/dump.sql
-bash: /home/ansadmin/dump.sql: No such file or directory
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$    - name: BD
    - name: Import BD
        become: true
        become_user: postgres
        shell: psql dbapx < /tmp/dbofi_aaw.sql

    - name: Add some dummy data to our database dbapx


        become: true
        become_user: postgres
        shell: psql dbapx < /home/ansadmin/dump.sql
-: command not found
ansadmin@svl200:~/TPansible/roles$          postgresql_db:
postgresql_db:: command not found
ansadmin@svl200:~/TPansible/roles$              state: present

Command 'state:' not found, did you mean:

    command 'states' from deb enscript (1.6.5.90-3)

Try: apt install <deb name>

ansadmin@svl200:~/TPansible/roles$              name: dbapx

Command 'name:' not found, did you mean:

    command 'namei' from deb util-linux (2.34-0.1ubuntu9.3)


    command 'named' from deb bind9 (1:9.16.1-0ubuntu2.11)

Try: apt install <deb name>

ansadmin@svl200:~/TPansible/roles$          become: true


become:: command not found
ansadmin@svl200:~/TPansible/roles$          become_user: postgres
become_user:: command not found
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$      - name: Import BD
-: command not found
ansadmin@svl200:~/TPansible/roles$          become: true
become:: command not found
ansadmin@svl200:~/TPansible/roles$          become_user: postgres
become_user:: command not found
ansadmin@svl200:~/TPansible/roles$          shell: psql dbapx < /tmp/dbofi_aaw.sql
-bash: /tmp/dbofi_aaw.sql: No such file or directory
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$      - name: Add some dummy data to our database
dbapx
-: command not found
ansadmin@svl200:~/TPansible/roles$          become: true
become:: command not found
ansadmin@svl200:~/TPansible/roles$          become_user: postgres
become_user:: command not found
ansadmin@svl200:~/TPansible/roles$          shell: psql dbapx <
/home/ansadmin/dump.sql
-bash: /home/ansadmin/dump.sql: No such file or directory
ansadmin@svl200:~/TPansible/roles$ ^C
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$ ansible-galaxy init TPpostgres
- Role TPpostgres was created successfully
ansadmin@svl200:~/TPansible/roles$ cd TPpostgres/
ansadmin@svl200:~/TPansible/roles/TPpostgres$ tree
.
├── README.md
├── defaults
│   └── main.yml
├── files
├── handlers
│   └── main.yml
├── meta
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
        └── main.yml

8 directories, 8 files
ansadmin@svl200:~/TPansible/roles/TPpostgres$ cd ..
ansadmin@svl200:~/TPansible/roles$ tree
.
├── TPpostgres
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
├── postgres
│   ├── handlers
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   │   └── index.html.j2
│   └── vars
│            └── main.yml
└── users
        ├── handlers
        │   └── main.yml
        ├── tasks
        │   └── main.yml
        ├── templates
        │   └── index.html.j2
        └── vars
                └── main.yml

19 directories, 16 files
ansadmin@svl200:~/TPansible/roles$ cd ..
ansadmin@svl200:~/TPansible$ tree
.
├── dump.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── main.yml
├── main_base.yml
├── main_houcem.yml
├── main_postgres.yml
├── psql.yml
├── roles
│   ├── TPpostgres
│   │   ├── README.md
│   │   ├── defaults
│   │   │   └── main.yml
│   │   ├── files
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── meta
│   │   │   └── main.yml
│   │   ├── tasks
│   │   │   └── main.yml
│   │   ├── templates
│   │   ├── tests
│   │   │   ├── inventory
│   │   │   └── test.yml
│   │   └── vars
│   │            └── main.yml
│   ├── postgres
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── tasks
│   │   │   └── main.yml
│   │   ├── templates
│   │   │   └── index.html.j2
│   │   └── vars
│   │            └── main.yml
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

22 directories, 25 files
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ls
dump.yml        hosts_vars          main_houcem.yml        roles
group_vars    main.yml              main_postgres.yml    site.yml
hosts.yml      main_base.yml    psql.yml
ansadmin@svl200:~/TPansible$ cd roles
ansadmin@svl200:~/TPansible/roles$ ls
TPpostgres    postgres    users
ansadmin@svl200:~/TPansible/roles$ mv TPpostgres/ ../
ansadmin@svl200:~/TPansible/roles$ cd..
cd..: command not found
ansadmin@svl200:~/TPansible/roles$ cd ..
ansadmin@svl200:~/TPansible$ ls
TPpostgres    hosts.yml      main_base.yml            psql.yml
dump.yml        hosts_vars    main_houcem.yml        roles
group_vars    main.yml        main_postgres.yml    site.yml
ansadmin@svl200:~/TPansible$ tree
.
├── TPpostgres
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
├── dump.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── main.yml
├── main_base.yml
├── main_houcem.yml
├── main_postgres.yml
├── psql.yml
├── roles
│   ├── postgres
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── tasks
│   │   │   └── main.yml
│   │   ├── templates
│   │   │   └── index.html.j2
│   │   └── vars
│   │            └── main.yml
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

22 directories, 25 files
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ cd TPpostgres/
ansadmin@svl200:~/TPansible/TPpostgres$ tree
.
├── README.md
├── defaults
│   └── main.yml
├── files
├── handlers
│   └── main.yml
├── meta
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
        └── main.yml

8 directories, 8 files
ansadmin@svl200:~/TPansible/TPpostgres$ cd ..
ansadmin@svl200:~/TPansible$ ls
TPpostgres    hosts.yml      main_base.yml            psql.yml
dump.yml        hosts_vars    main_houcem.yml        roles
group_vars    main.yml        main_postgres.yml    site.yml
ansadmin@svl200:~/TPansible$ cp main_postgres.yml ./
TPpostgres/                hosts_vars/                main_postgres.yml
dump.yml                      main.yml                      psql.yml
group_vars/                main_base.yml            roles/
hosts.yml                    main_houcem.yml        site.yml
ansadmin@svl200:~/TPansible$ cp main_postgres.yml ./TPpostgres/
.travis.yml    defaults/        handlers/        tasks/              tests/
README.md        files/              meta/                templates/      vars/
ansadmin@svl200:~/TPansible$ cp main_postgres.yml ./TPpostgres/tasks/mai             
n.yml
ansadmin@svl200:~/TPansible$ cd TPpostgres/
ansadmin@svl200:~/TPansible/TPpostgres$ tree
.
├── README.md
├── defaults
│   └── main.yml
├── files
├── handlers
│   └── main.yml
├── meta
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
        └── main.yml

8 directories, 8 files
ansadmin@svl200:~/TPansible/TPpostgres$ mkdir group_vars
ansadmin@svl200:~/TPansible/TPpostgres$ mkdir hosts_vars
ansadmin@svl200:~/TPansible/TPpostgres$ mkdir group_vars/all.yml
ansadmin@svl200:~/TPansible/TPpostgres$ cd
ansadmin@svl200:~$ ls
TP3                      hello.yaml                play-vars.yaml    template1.yaml
TPansible          hello.yml                  play-vars.yml      var_dic.yml
cible1.txt        index.html                projet                    var_dic2.yml
copie.yaml        index.html.j2          projet1                  var_dic_multi3.yml
debug.yaml        index.html1.j2        projet2                  vars.yml
debug1.yaml      ip.txt                        projet3                  vars2.yml
exo2.yaml          item_users.yaml      projet4                  vars_multi.yml
exo3.yaml          items.yaml                rep.yaml                when.yaml
exo4.yaml          items_users.yaml    seq.yaml                when1.yaml
fact.yaml          list.yaml                  shell.yml
fact1.yaml        locale.yml                snap
handler.yaml    nginx.yaml                template.yaml
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ls
geerlingguy.apache    group_vars    hosts.yml    hosts_vars    site.yml
ansadmin@svl200:~/projet4$ sudo vim geerlingguy.apache/
.ansible-lint    LICENSE                meta/                    templates/
.github/              README.md            molecule/            vars/
.gitignore          defaults/            site.yml
.yamllint            handlers/            tasks/
ansadmin@svl200:~/projet4$ sudo vim geerlingguy.apache/tasks/
configure-Debian.yml      configure-Suse.yml          setup-RedHat.yml
configure-RedHat.yml      main.yml                              setup-Solaris.yml
configure-Solaris.yml    setup-Debian.yml              setup-Suse.yml
ansadmin@svl200:~/projet4$ sudo vim geerlingguy.apache/tasks/main.yml
ansadmin@svl200:~/projet4$ cd
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ls
geerlingguy.apache    group_vars    hosts.yml    hosts_vars    site.yml
ansadmin@svl200:~/projet4$ tree
.
├── geerlingguy.apache
│   ├── LICENSE
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── molecule
│   │   └── default
│   │            ├── converge.yml
│   │            └── molecule.yml
│   ├── site.yml
│   ├── tasks
│   │   ├── configure-Debian.yml
│   │   ├── configure-RedHat.yml
│   │   ├── configure-Solaris.yml
│   │   ├── configure-Suse.yml
│   │   ├── main.yml
│   │   ├── setup-Debian.yml
│   │   ├── setup-RedHat.yml
│   │   ├── setup-Solaris.yml
│   │   └── setup-Suse.yml
│   ├── templates
│   │   └── vhosts.conf.j2
│   └── vars
│            ├── AmazonLinux.yml
│            ├── Debian.yml
│            ├── RedHat.yml
│            ├── Solaris.yml
│            ├── Suse.yml
│            ├── apache-22.yml
│            └── apache-24.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
└── site.yml

11 directories, 28 files
ansadmin@svl200:~/projet4$ cd
ansadmin@svl200:~$ cd
.ansible/    TP3/              projet/        projet2/      projet4/
.ssh/            TPansible/ projet1/      projet3/      snap/
ansadmin@svl200:~$ cd TPansible/
TPpostgres/ group_vars/ hosts_vars/ roles/
ansadmin@svl200:~$ cd TPansible/TPpostgres/
defaults/      group_vars/ hosts_vars/ tasks/            tests/
files/            handlers/      meta/              templates/    vars/
ansadmin@svl200:~$ sudo vim TPansible/TPpostgres/vars/main.yml
ansadmin@svl200:~$ cd TP
TP3/              TPansible/
ansadmin@svl200:~$ cd TPansible/TPpostgres/
ansadmin@svl200:~/TPansible/TPpostgres$ tree
.
├── README.md
├── defaults
│   └── main.yml
├── files
├── group_vars
│   └── all.yml
├── handlers
│   └── main.yml
├── hosts_vars
├── meta
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
        └── main.yml

11 directories, 8 files
ansadmin@svl200:~/TPansible/TPpostgres$ ls
README.md    files              handlers        meta      templates    vars
defaults      group_vars    hosts_vars    tasks    tests
ansadmin@svl200:~/TPansible/TPpostgres$ cd ..
ansadmin@svl200:~/TPansible$ ls
TPpostgres    hosts.yml      main_base.yml            psql.yml
dump.yml        hosts_vars    main_houcem.yml        roles
group_vars    main.yml        main_postgres.yml    site.yml
ansadmin@svl200:~/TPansible$ cd group_vars/
ansadmin@svl200:~/TPansible/group_vars$ ls
all.yml
ansadmin@svl200:~/TPansible/group_vars$ cp all.yml ../TPpostgres/
.travis.yml    files/              hosts_vars/    templates/
README.md        group_vars/    meta/                tests/
defaults/        handlers/        tasks/              vars/
ansadmin@svl200:~/TPansible/group_vars$ cp all.yml ../TPpostgres/group_v             
ars/
cp: cannot overwrite directory '../TPpostgres/group_vars/all.yml' with n             
on-directory
ansadmin@svl200:~/TPansible/group_vars$ cp all.yml ../TPpostgres/group_v             
ars/all.yml
ansadmin@svl200:~/TPansible/group_vars$
ansadmin@svl200:~/TPansible/group_vars$ cd ..
ansadmin@svl200:~/TPansible$ tree
.
├── TPpostgres
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── group_vars
│   │   └── all.yml
│   │            └── all.yml
│   ├── handlers
│   │   └── main.yml
│   ├── hosts_vars
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
├── dump.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── main.yml
├── main_base.yml
├── main_houcem.yml
├── main_postgres.yml
├── psql.yml
├── roles
│   ├── postgres
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── tasks
│   │   │   └── main.yml
│   │   ├── templates
│   │   │   └── index.html.j2
│   │   └── vars
│   │            └── main.yml
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

25 directories, 26 files
ansadmin@svl200:~/TPansible$ cd TPpostgres/
ansadmin@svl200:~/TPansible/TPpostgres$ ls
README.md    files              handlers        meta      templates    vars
defaults      group_vars    hosts_vars    tasks    tests
ansadmin@svl200:~/TPansible/TPpostgres$ cd ..
ansadmin@svl200:~/TPansible$ ls
TPpostgres    hosts.yml      main_base.yml            psql.yml
dump.yml        hosts_vars    main_houcem.yml        roles
group_vars    main.yml        main_postgres.yml    site.yml
ansadmin@svl200:~/TPansible$ sudo vim site.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ TPpostgres/
-bash: TPpostgres/: Is a directory
ansadmin@svl200:~/TPansible$ cd TPpostgres/
ansadmin@svl200:~/TPansible/TPpostgres$ tree
.
├── README.md
├── defaults
│   └── main.yml
├── files
├── group_vars
│   └── all.yml
│            └── all.yml
├── handlers
│   └── main.yml
├── hosts_vars
├── meta
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
        └── main.yml

11 directories, 9 files
ansadmin@svl200:~/TPansible/TPpostgres$ ansible-playbook -i hosts.yml site.yml
ERROR! the playbook: site.yml could not be found
ansadmin@svl200:~/TPansible/TPpostgres$ cd ..
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml
ERROR! conflicting action statements: hosts, gather_facts

The error appears to be in '/home/ansadmin/TPansible/TPpostgres/tasks/main.yml': line


1, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: install postgresql and BD


    ^ here
ansadmin@svl200:~/TPansible$ TPp
TPp: command not found
ansadmin@svl200:~/TPansible$ cd TPpostgres/
ansadmin@svl200:~/TPansible/TPpostgres$ ls
README.md    defaults    files    group_vars    handlers    hosts_vars    meta   
tasks    templates    tests    vars
ansadmin@svl200:~/TPansible/TPpostgres$ tree
.
├── README.md
├── defaults
│   └── main.yml
├── files
├── group_vars
│   └── all.yml
│            └── all.yml
├── handlers
│   └── main.yml
├── hosts_vars
├── meta
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
        └── main.yml

11 directories, 9 files
ansadmin@svl200:~/TPansible/TPpostgres$ cd ..
ansadmin@svl200:~/TPansible$ tree
.
├── TPpostgres
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── group_vars
│   │   └── all.yml
│   │            └── all.yml
│   ├── handlers
│   │   └── main.yml
│   ├── hosts_vars
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
├── dump.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── main.yml
├── main_base.yml
├── main_houcem.yml
├── main_postgres.yml
├── psql.yml
├── roles
│   ├── postgres
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── tasks
│   │   │   └── main.yml
│   │   ├── templates
│   │   │   └── index.html.j2
│   │   └── vars
│   │            └── main.yml
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

25 directories, 26 files
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml
ERROR! conflicting action statements: hosts, gather_facts

The error appears to be in '/home/ansadmin/TPansible/TPpostgres/tasks/main.yml': line


1, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: install postgresql and BD


    ^ here
ansadmin@svl200:~/TPansible$ ansible-playbook -i hosts.yml site.yml
    hosts: cible1
    become: yes
    become_method: sudo
    gather_facts: yes

    tasks:
    - name: installation postgresql-contrib
        apt:
            name: postgresql-contrib
            state: latest

    - name: package_python
        apt:
            name: python3-psycopg2
            state: latest

    - name: acl
        apt:
            name: acl
            state: latest

    - name: installation postgresql


        apt:
            name: postgresql
            state: present

    - name: start servicde


        service:
            name: postgresql
            state: started
            enabled: true

    - name: BD
Network error: Software caused connection abort
            state: present
─────────────────────────────────────────────────────────────────────────────────────
──────────────────────────────────────────────────────────────────────────
        become: true
Session stopped: postgres
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file                                   
34,1                    Top
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation
10 updates can be applied immediately.
To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Thu Oct    6 12:01:07 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$ ls
TP3                  debug1.yaml    fact1.yaml        index.html.j2       
items_users.yaml    play-vars.yml    projet4        template.yaml             
vars.yml
TPansible      exo2.yaml        handler.yaml    index.html1.j2      list.yaml       
projet                  rep.yaml      template1.yaml            vars2.yml
cible1.txt    exo3.yaml        hello.yaml        ip.txt                     
locale.yml                projet1                seq.yaml      var_dic.yml           
vars_multi.yml
copie.yaml    exo4.yaml        hello.yml          item_users.yaml    nginx.yaml     
projet2                shell.yml    var_dic2.yml                when.yaml
debug.yaml    fact.yaml        index.html        items.yaml              play-
vars.yaml        projet3                snap              var_dic_multi3.yml   
when1.yaml
ansadmin@svl200:~$ cd TPansible/
TPpostgres/ group_vars/ hosts_vars/ roles/
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ls
TPpostgres    dump.yml    group_vars    hosts.yml    hosts_vars    main.yml   
main_base.yml    main_houcem.yml    main_postgres.yml    psql.yml    roles   
site.yml
ansadmin@svl200:~/TPansible$ sudo vim main_postgres.yml
ansadmin@svl200:~/TPansible$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
──────────────────────────────────────────────────────────────────────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

10 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

*** System restart required ***


Last login: Thu Oct    6 16:12:19 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ ls -lrta .git/
ls: cannot access '.git/': No such file or directory
ofi03@svl200:~$
ofi03@svl200:~$ mkdir projetgit
ofi03@svl200:~$ cd projetgit/
ofi03@svl200:~/projetgit$ git init
Initialized empty Git repository in /home/ofi03/projetgit/.git/
ofi03@svl200:~/projetgit$ ls -lrta .git/
total 40
drwxrwxr-x 2 ofi03 ofi03 4096 Oct    7 08:47 branches
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 08:47 ..
drwxrwxr-x 4 ofi03 ofi03 4096 Oct    7 08:47 refs
drwxrwxr-x 4 ofi03 ofi03 4096 Oct    7 08:47 objects
drwxrwxr-x 2 ofi03 ofi03 4096 Oct    7 08:47 info
drwxrwxr-x 2 ofi03 ofi03 4096 Oct    7 08:47 hooks
-rw-rw-r-- 1 ofi03 ofi03      73 Oct    7 08:47 description
-rw-rw-r-- 1 ofi03 ofi03      92 Oct    7 08:47 config
-rw-rw-r-- 1 ofi03 ofi03      23 Oct    7 08:47 HEAD
drwxrwxr-x 7 ofi03 ofi03 4096 Oct    7 08:47 .
ofi03@svl200:~/projetgit$ git config --global user.name "aaw"
ofi03@svl200:~/projetgit$ git config --global user.email [email protected]
ofi03@svl200:~/projetgit$ git add fichier.html
fatal: pathspec 'fichier.html' did not match any files
ofi03@svl200:~/projetgit$ touch fichier.html
ofi03@svl200:~/projetgit$ git add fichier.html
ofi03@svl200:~/projetgit$ git commit
hint: Waiting for your editor to close the file...

Use "fg" to return to nano.

[1]+    Stopped                                  git commit


ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git commit
hint: Waiting for your editor to close the file...

Use "fg" to return to nano.

[2]+    Stopped                                  git commit


ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git add fichier.html
ofi03@svl200:~/projetgit$ git commit
hint: Waiting for your editor to close the file...

Use "fg" to return to nano.

[3]+    Stopped                                  git commit


ofi03@svl200:~/projetgit$ git status
On branch master

No commits yet

Changes to be committed:
    (use "git rm --cached <file>..." to unstage)
                new file:      fichier.html

ofi03@svl200:~/projetgit$ git ls-tree -r HEAD


fatal: Not a valid object name HEAD
ofi03@svl200:~/projetgit$ git ls-tree -r head
fatal: Not a valid object name head
ofi03@svl200:~/projetgit$ git ls -tree -r head
git: 'ls' is not a git command. See 'git --help'.

The most similar command is


                log
ofi03@svl200:~/projetgit$ git ls-tree
usage: git ls-tree [<options>] <tree-ish> [<path>...]

        -d                                        only show trees


        -r                                        recurse into subtrees
        -t                                        show trees when recursing
        -z                                        terminate entries with NUL byte
        -l, --long                        include object size
        --name-only                      list only filenames
        --name-status                  list only filenames
        --full-name                      use full path names
        --full-tree                      list entire tree; not just current directory
(implies --full-name)
        --abbrev[=<n>]                use <n> digits to display SHA-1s

ofi03@svl200:~/projetgit$ git ls -tree head


git: 'ls' is not a git command. See 'git --help'.

The most similar command is


                log
ofi03@svl200:~/projetgit$ git --help
usage: git [--version] [--help] [-C <path>] [-c <name>=<value>]
                      [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
                      [-p | --paginate | -P | --no-pager] [--no-replace-objects] [--
bare]
                      [--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>]
                      <command> [<args>]

These are common Git commands used in various situations:

start a working area (see also: git help tutorial)


      clone                          Clone a repository into a new directory
      init                            Create an empty Git repository or reinitialize
an existing one

work on the current change (see also: git help everyday)


      add                              Add file contents to the index
      mv                                Move or rename a file, a directory, or a
symlink
      restore                      Restore working tree files
      rm                                Remove files from the working tree and from
the index
      sparse-checkout      Initialize and modify the sparse-checkout

examine the history and state (see also: git help revisions)
      bisect                        Use binary search to find the commit that
introduced a bug
      diff                            Show changes between commits, commit and
working tree, etc
      grep                            Print lines matching a pattern
      log                              Show commit logs
      show                            Show various types of objects
      status                        Show the working tree status

grow, mark and tweak your common history


      branch                        List, create, or delete branches
      commit                        Record changes to the repository
      merge                          Join two or more development histories together
      rebase                        Reapply commits on top of another base tip
      reset                          Reset current HEAD to the specified state
      switch                        Switch branches
      tag                              Create, list, delete or verify a tag object
signed with GPG

collaborate (see also: git help workflows)


      fetch                          Download objects and refs from another
repository
      pull                            Fetch from and integrate with another
repository or a local branch
      push                            Update remote refs along with associated
objects

'git help -a' and 'git help -g' list available subcommands and some
concept guides. See 'git help <command>' or 'git help <concept>'
to read about a specific subcommand or concept.
See 'git help git' for an overview of the system.
ofi03@svl200:~/projetgit$ git --help -r
error: unknown switch `r'
usage: git help [--all] [--guides] [--man | --web | --info] [<command>]

        -a, --all                          print all available commands


        -g, --guides                    print list of useful guides
        -c, --config                    print all configuration variable names
        -m, --man                          show man page
        -w, --web                          show manual in web browser
        -i, --info                        show info page
        -v, --verbose                  print command description

ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git mv rename fichier.html fichier1.html
fatal: destination 'fichier1.html' is not a directory
ofi03@svl200:~/projetgit$ git mv rename fichier.html
fatal: bad source, source=rename, destination=fichier.html
ofi03@svl200:~/projetgit$ git ls-tree -r HEAD
fatal: Not a valid object name HEAD
ofi03@svl200:~/projetgit$ ll
total 12
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 08:50 ./
drwxr-xr-x 23 ofi03 ofi03 4096 Oct    7 08:48 ../
drwxrwxr-x    7 ofi03 ofi03 4096 Oct    7 08:56 .git/
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
ofi03@svl200:~/projetgit$ git status
On branch master

No commits yet

Changes to be committed:
    (use "git rm --cached <file>..." to unstage)
                new file:      fichier.html

ofi03@svl200:~/projetgit$ git commit -m "aaw"


[master (root-commit) 38d2f37] aaw
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100644 fichier.html
ofi03@svl200:~/projetgit$ git ls-tree -r HEAD
100644 blob e69de29bb2d1d6434b8b29ae775ad8c2e48c5391        fichier.html
ofi03@svl200:~/projetgit$ sudo vim .gitignore
[sudo] password for ofi03:
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ ll
total 12
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 09:05 ./
drwxr-xr-x 23 ofi03 ofi03 4096 Oct    7 08:48 ../
drwxrwxr-x    8 ofi03 ofi03 4096 Oct    7 08:58 .git/
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
ofi03@svl200:~/projetgit$ git add index.html
fatal: pathspec 'index.html' did not match any files
ofi03@svl200:~/projetgit$ touch index.html
ofi03@svl200:~/projetgit$ git add index.html
ofi03@svl200:~/projetgit$ touch readme.md
ofi03@svl200:~/projetgit$ git add readme.md
ofi03@svl200:~/projetgit$ git status
On branch master
Changes to be committed:
    (use "git restore --staged <file>..." to unstage)
                new file:      index.html
                new file:      readme.md

ofi03@svl200:~/projetgit$ touch tuto.pdf


ofi03@svl200:~/projetgit$ git add tuto.pdf
ofi03@svl200:~/projetgit$ sudo vim .gitignore
ofi03@svl200:~/projetgit$ git status
On branch master
Changes to be committed:
    (use "git restore --staged <file>..." to unstage)
                new file:      index.html
                new file:      readme.md
                new file:      tuto.pdf

Untracked files:
    (use "git add <file>..." to include in what will be committed)
                .gitignore

ofi03@svl200:~/projetgit$ ll
total 16
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 09:08 ./
drwxr-xr-x 23 ofi03 ofi03 4096 Oct    7 08:48 ../
drwxrwxr-x    8 ofi03 ofi03 4096 Oct    7 09:08 .git/
-rw-r--r--    1 root    root        17 Oct    7 09:08 .gitignore
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:06 index.html
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:06 readme.md
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:07 tuto.pdf
ofi03@svl200:~/projetgit$ git add .gitignore
ofi03@svl200:~/projetgit$ git status
On branch master
Changes to be committed:
    (use "git restore --staged <file>..." to unstage)
                new file:      .gitignore
                new file:      index.html
                new file:      readme.md
                new file:      tuto.pdf

ofi03@svl200:~/projetgit$ git commit -m "ajout .gitignore"


[master 73cde3e] ajout .gitignore
4 files changed, 3 insertions(+)
create mode 100644 .gitignore
create mode 100644 index.html
create mode 100644 readme.md
create mode 100644 tuto.pdf
ofi03@svl200:~/projetgit$ git status
On branch master
nothing to commit, working tree clean
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git log
commit 73cde3eb6d731ca5c67f032bdc18190b4b78ef35 (HEAD -> master)
Author: aaw <[email protected]>
Date:      Fri Oct 7 09:12:35 2022 +0000

        ajout .gitignore

commit 38d2f37b1b0470a41d74e1d9679dd2d7a4694a7a
Author: aaw <[email protected]>
Date:      Fri Oct 7 08:58:37 2022 +0000

        aaw
ofi03@svl200:~/projetgit$ git log -1 --stat
commit 73cde3eb6d731ca5c67f032bdc18190b4b78ef35 (HEAD -> master)
Author: aaw <[email protected]>
Date:      Fri Oct 7 09:12:35 2022 +0000

        ajout .gitignore

.gitignore | 3 +++
index.html | 0
readme.md    | 0
tuto.pdf      | 0
4 files changed, 3 insertions(+)
ofi03@svl200:~/projetgit$ git log -1 --oneline
73cde3e (HEAD -> master) ajout .gitignore
ofi03@svl200:~/projetgit$ git log -2 index.html
commit 73cde3eb6d731ca5c67f032bdc18190b4b78ef35 (HEAD -> master)
Author: aaw <[email protected]>
Date:      Fri Oct 7 09:12:35 2022 +0000

        ajout .gitignore
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ git diff
diff --git a/index.html b/index.html
index e69de29..a9a9b37 100644
--- a/index.html
+++ b/index.html
@@ -0,0 +1,3 @@
+<html> aaw </html>
+<html> aaw am </html>
+
ofi03@svl200:~/projetgit$ git add index.html
ofi03@svl200:~/projetgit$ git status
On branch master
Changes to be committed:
    (use "git restore --staged <file>..." to unstage)
                modified:      index.html

ofi03@svl200:~/projetgit$ vim index.html


ofi03@svl200:~/projetgit$ git diff --staged
diff --git a/index.html b/index.html
index e69de29..a9a9b37 100644
--- a/index.html
+++ b/index.html
@@ -0,0 +1,3 @@
+<html> aaw </html>
+<html> aaw am </html>
+
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ git commit -m "modif index"
[master 19a2a9b] modif index
1 file changed, 3 insertions(+)
ofi03@svl200:~/projetgit$ git diff --staged
ofi03@svl200:~/projetgit$ git diff --cached
ofi03@svl200:~/projetgit$ git status
On branch master
nothing to commit, working tree clean
ofi03@svl200:~/projetgit$ git diff --color-words
ofi03@svl200:~/projetgit$ git status
On branch master
nothing to commit, working tree clean
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git diff --color-words=.
diff --git a/index.html b/index.html
index a9a9b37..7fd126b 100644
--- a/index.html
+++ b/index.html
@@ -1,3 +1,3 @@
<html> aaw </html>
<html> aaw amw </html>

ofi03@svl200:~/projetgit$ git diff --word-diff


diff --git a/index.html b/index.html
index a9a9b37..7fd126b 100644
--- a/index.html
+++ b/index.html
@@ -1,3 +1,3 @@
<html> aaw </html>
<html> aaw [-am-]{+aw+} </html>

ofi03@svl200:~/projetgit$ git reflog


19a2a9b (HEAD -> master) HEAD@{0}: commit: modif index
73cde3e HEAD@{1}: commit: ajout .gitignore
38d2f37 HEAD@{2}: commit (initial): aaw
ofi03@svl200:~/projetgit$ git checkout 38d2f37
error: Your local changes to the following files would be overwritten by checkout:
                index.html
Please commit your changes or stash them before you switch branches.
Aborting
ofi03@svl200:~/projetgit$ git checkout <38d2f37>
-bash: syntax error near unexpected token `newline'
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git log --oneline
19a2a9b (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ git checkout 38d2f37 index.html
error: pathspec 'index.html' did not match any file(s) known to git
ofi03@svl200:~/projetgit$ ll
total 20
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 09:46 ./
drwxr-xr-x 23 ofi03 ofi03 4096 Oct    7 09:46 ../
drwxrwxr-x    8 ofi03 ofi03 4096 Oct    7 10:04 .git/
-rw-r--r--    1 root    root        17 Oct    7 09:08 .gitignore
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
-rw-rw-r--    1 ofi03 ofi03      42 Oct    7 09:46 index.html
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:06 readme.md
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:07 tuto.pdf
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git log --oneline
19a2a9b (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ git checkout 38d2f37 index.html
error: pathspec 'index.html' did not match any file(s) known to git
ofi03@svl200:~/projetgit$ git diff --word-diff
diff --git a/index.html b/index.html
index a9a9b37..7fd126b 100644
--- a/index.html
+++ b/index.html
@@ -1,3 +1,3 @@
<html> aaw </html>
<html> aaw [-am-]{+aw+} </html>

ofi03@svl200:~/projetgit$ git checkout 100644 index.html


error: pathspec '100644' did not match any file(s) known to git
ofi03@svl200:~/projetgit$ git checkout index.html 100644
error: pathspec '100644' did not match any file(s) known to git
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git checkout 100644 index.html
error: pathspec '100644' did not match any file(s) known to git
ofi03@svl200:~/projetgit$ git diff --word-diff
diff --git a/index.html b/index.html
index a9a9b37..7fd126b 100644
--- a/index.html
+++ b/index.html
@@ -1,3 +1,3 @@
<html> aaw </html>
<html> aaw [-am-]{+aw+} </html>

ofi03@svl200:~/projetgit$ git log --oneline


19a2a9b (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ git checkout 19a2a9b index.html
Updated 1 path from f427aa8
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ git checkout 19a2a9b index.html
Updated 1 path from f427aa8
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ git commit --amend
hint: Waiting for your editor to close the file...

Use "fg" to return to nano.

[4]+    Stopped                                  git commit --amend


ofi03@svl200:~/projetgit$ git log --oneline
19a2a9b (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ git commit --amend --no-edit
[master de0c025] modif index
Date: Fri Oct 7 09:44:00 2022 +0000
1 file changed, 3 insertions(+)
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ git log --oneline
de0c025 (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ git log --oneline
ofi03@svl200:~/projetgit$ git log --oneline
de0c025 (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ git commit --amend --no-edit
[master 1ecde7e] modif index
Date: Fri Oct 7 09:44:00 2022 +0000
1 file changed, 3 insertions(+)
ofi03@svl200:~/projetgit$ git log --oneline
1ecde7e (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ git commit --amend
[master fb7032a] modif index
Date: Fri Oct 7 09:44:00 2022 +0000
1 file changed, 3 insertions(+)
ofi03@svl200:~/projetgit$ git log --oneline
fb7032a (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ vim index.html
ofi03@svl200:~/projetgit$ git commit --amend
[master 9fcc5d2] modif index
Date: Fri Oct 7 09:44:00 2022 +0000
1 file changed, 3 insertions(+)
ofi03@svl200:~/projetgit$ git log --oneline
9fcc5d2 (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$ git commit --amend
[master 84cb809] modif index
Date: Fri Oct 7 09:44:00 2022 +0000
1 file changed, 3 insertions(+)
ofi03@svl200:~/projetgit$ git commit --amend
[master ec25a48] modif index
Date: Fri Oct 7 09:44:00 2022 +0000
1 file changed, 3 insertions(+)
ofi03@svl200:~/projetgit$ git log --oneline
ec25a48 (HEAD -> master) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
───────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)


* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

10 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Fri Oct    7 08:42:58 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ cd projetgit/
ofi03@svl200:~/projetgit$ git remote add origin
https://gitlab.com/logwire9/projet1.git
ofi03@svl200:~/projetgit$ git remote -v
origin    https://gitlab.com/logwire9/projet1.git (fetch)
origin    https://gitlab.com/logwire9/projet1.git (push)
ofi03@svl200:~/projetgit$ git push -u origin --all
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
Enumerating objects: 9, done.
Counting objects: 100% (9/9), done.
Compressing objects: 100% (5/5), done.
Writing objects: 100% (9/9), 728 bytes | 242.00 KiB/s, done.
Total 9 (delta 1), reused 0 (delta 0)
To https://gitlab.com/logwire9/projet1.git
* [new branch]            master -> master
Branch 'master' set up to track remote branch 'master' from 'origin'.
ofi03@svl200:~/projetgit$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
───────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

10 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Fri Oct    7 12:06:42 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ cat .ssh/
authorized_keys    known_hosts
ofi03@svl200:~$ cat .ssh/
authorized_keys    known_hosts
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$ cat .ssh/
id_rsa              id_rsa.pub      known_hosts
ansadmin@svl200:~$ cat .ssh/id_rsa.pub
ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAABgQC+mSwnfLabQvto3xXof26d1FSVallOycWRUXofBs4lrFoDakRQlVS/
kQuy                                                                                 
gGr0FAudHvTJCMZ8SM8F2atIy4rrgWrBlysk1WJmqBr2X6Xj1GzjykWlezNrZYkbrTwZVtBG6hvuSKeNnrdYx
q4LW2DsgtNf                                                                         
2+ex+jGPW8K/cQHmrWG9IPBVpsRFwC0V50fvvsil4UYIUC3lfugRA1yduzPFYEU/5rEmHvmxfVKZ8KxoEjEVJ
FgTLJZ0AX0O                                                                         
KLJuZVv+HiBcBVbRVnfk+LYz9R4FcjijoCFZMGNbVSJdi9IaqPVFka6zXZn6WItoiOs7t0TuJJCf/
6sNJRdrtvVc4Et7EwX3                                                                 
jP5/MTblLEPPYIaZUF3jT6qBPHUt+NQpGe/SBq1EFYziv84aU6CKvCe1uhIMJV1ekqr8B+cVoL8TdUunvCWJ6
y2UOGF1vqMo                                                                         
xz21L43X5dz+udXPvECb4HNyIX6sccXQ9pfBTHkMeVNypz2xQffSphudoeJiBc7pVlMOPvs=
ansadmin@svl200
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$ git clone [email protected]:logwire9/projet1.git
fatal: destination path 'projet1' already exists and is not an empty directory.
ansadmin@svl200:~$ git clone [email protected]:logwire9/projet1.git
fatal: destination path 'projet1' already exists and is not an empty directory.
ansadmin@svl200:~$
ansadmin@svl200:~$ git clone [email protected]:logwire9/projet1.git
fatal: destination path 'projet1' already exists and is not an empty directory.
ansadmin@svl200:~$ mkdir git
ansadmin@svl200:~$ cd git
ansadmin@svl200:~/git$ git clone [email protected]:logwire9/projet1.git
Cloning into 'projet1'...
The authenticity of host 'gitlab.com (2606:4700:90:0:f22e:fbec:5bed:a9b9)' can't be
established.
ECDSA key fingerprint is SHA256:HbW3g8zUjNSksFbqTiUWPWg2Bq1x8xdGUrliXFzSnUw.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'gitlab.com,2606:4700:90:0:f22e:fbec:5bed:a9b9' (ECDSA) to
the list of known hosts.
remote: Enumerating objects: 9, done.
remote: Counting objects: 100% (9/9), done.
remote: Compressing objects: 100% (5/5), done.
remote: Total 9 (delta 1), reused 0 (delta 0), pack-reused 0
Receiving objects: 100% (9/9), done.
Resolving deltas: 100% (1/1), done.
ansadmin@svl200:~/git$ ls
projet1
ansadmin@svl200:~/git$ cd projet1/
ansadmin@svl200:~/git/projet1$ ls
fichier.html    index.html    readme.md    tuto.pdf
ansadmin@svl200:~/git/projet1$ git log --oneline
ec25a48 (HEAD -> master, origin/master, origin/HEAD) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ansadmin@svl200:~/git/projet1$ sudo vim test.txt
ansadmin@svl200:~/git/projet1$ git status
On branch master
Your branch is up to date with 'origin/master'.

Untracked files:
    (use "git add <file>..." to include in what will be committed)
                test.txt

nothing added to commit but untracked files present (use "git add" to track)
ansadmin@svl200:~/git/projet1$ git add test.txt
ansadmin@svl200:~/git/projet1$ git commit -m "ajout new file"

*** Please tell me who you are.


Run

    git config --global user.email "[email protected]"


    git config --global user.name "Your Name"

to set your account's default identity.


Omit --global to set the identity only in this repository.

fatal: unable to auto-detect email address (got 'ansadmin@svl200.(none)')


ansadmin@svl200:~/git/projet1$ git log --oneline
ec25a48 (HEAD -> master, origin/master, origin/HEAD) modif index
73cde3e ajout .gitignore
38d2f37 aaw
ansadmin@svl200:~/git/projet1$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
─────────────────────────────────────────────────────────────────────────────────────
───────────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
Access denied
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage
System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

10 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Fri Oct    7 12:18:12 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ ls
TP3                  debug.yaml      exo4.yaml      handler.yaml    index.html.j2   
items.yaml                nginx.yaml            projet1    rep.yaml     
template.yaml      var_dic_multi3.yml    when.yaml
TPansible      debug1.yaml    fact.yaml      hello.yaml        index.html1.j2     
items_users.yaml    play-vars.yaml    projet2    seq.yaml      template1.yaml   
vars.yml                        when1.yaml
cible1.txt    exo2.yaml        fact1.yaml    hello.yml          ip.txt               
list.yaml                  play-vars.yml      projet3    shell.yml    var_dic.yml   
vars2.yml
copie.yaml    exo3.yaml        git                  index.html        item_users.yaml
locale.yml                projet                    projet4    snap             
var_dic2.yml        vars_multi.yml
ansadmin@svl200:~$ cd git
ansadmin@svl200:~/git$ ll
total 12
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 12:36 ./
drwxr-xr-x 13 ansadmin ansadmin 4096 Oct    7 12:36 ../
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 12:43 projet1/
ansadmin@svl200:~/git$ cd projet1/
ansadmin@svl200:~/git/projet1$ ll
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 12:43 ./
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 12:36 ../
drwxrwxr-x 8 ansadmin ansadmin 4096 Oct    7 12:44 .git/
-rw-rw-r-- 1 ansadmin ansadmin      17 Oct    7 12:36 .gitignore
-rw-rw-r-- 1 ansadmin ansadmin        0 Oct    7 12:36 fichier.html
-rw-rw-r-- 1 ansadmin ansadmin      42 Oct    7 12:36 index.html
-rw-rw-r-- 1 ansadmin ansadmin        0 Oct    7 12:36 readme.md
-rw-r--r-- 1 root          root              14 Oct    7 12:43 test.txt
-rw-rw-r-- 1 ansadmin ansadmin        0 Oct    7 12:36 tuto.pdf
ansadmin@svl200:~/git/projet1$ git add .
ansadmin@svl200:~/git/projet1$ git commit -m "ajout file2"
*** Please tell me who you are.

Run

    git config --global user.email "[email protected]"


    git config --global user.name "Your Name"

to set your account's default identity.


Omit --global to set the identity only in this repository.

fatal: unable to auto-detect email address (got 'ansadmin@svl200.(none)')


ansadmin@svl200:~/git/projet1$ l
ansadmin@svl200:~/git/projet1$ exit
logout
ofi03@svl200:~$
ofi03@svl200:~$ ll
total 160100
drwxr-xr-x 23 ofi03 ofi03          4096 Oct    7 12:48 ./
drwxr-xr-x 11 root    root            4096 Oct    3 08:32 ../
-rw-------    1 ofi03 ofi03            364 Oct    7 12:48 .Xauthority
drwx------    4 ofi03 ofi03          4096 Oct    4 07:55 .ansible/
-rw-------    1 ofi03 ofi03        16540 Oct    6 18:31 .bash_history
-rw-r--r--    1 ofi03 ofi03            220 Aug 31 06:36 .bash_logout
-rw-r--r--    1 ofi03 ofi03          3771 Sep    2 08:39 .bashrc
drwx------    2 ofi03 ofi03          4096 Aug 31 08:04 .cache/
drwx------    3 ofi03 ofi03          4096 Aug 31 10:10 .config/
-rw-rw-r--    1 ofi03 ofi03              51 Oct    7 08:48 .gitconfig
drwxrwxr-x    3 ofi03 ofi03          4096 Sep    1 14:35 .local/
-rw-r--r--    1 ofi03 ofi03            932 Sep 30 09:14 .profile
-rw-rw-r--    1 ofi03 ofi03              66 Sep    1 14:35 .selected_editor
drwx------    2 ofi03 ofi03          4096 Oct    4 07:55 .ssh/
-rw-r--r--    1 ofi03 ofi03                0 Aug 31 10:12 .sudo_as_admin_successful
-rw-------    1 ofi03 ofi03        19513 Oct    7 10:16 .viminfo
drwxrwxr-x    3 exp2    ofi03          4096 Sep    5 13:32 Python/
drwxrwxr-x    4 ofi03 ofi03          4096 Sep    5 12:02 Unix/
-rw-rw-r--    1 ofi03 ofi03            192 Sep    5 13:29 Unix.tar.gz
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    7 14:16 am/
-rw-rw-r--    1 ofi03 ofi03              21 Sep    4 21:44 am.txt
-rw-rw-r--    1 ofi03 ofi03 11593900 Jul 14 13:13 apache-tomcat-9.0.65.tar.gz
drwxrw-rw-    3 root    ofi03          4096 Aug 31 12:05 backup/
drwxrwxr-x    8 ofi03 ofi03          4096 Sep    5 21:25 d1/
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    2 09:47 data/
-rw-rw-r--    1 ofi03 ofi03            198 Oct    6 12:49 dump.sql
-rw-------    1 ofi03 ofi03 41858954 Sep    8 08:17 dump1.hprof
-rw-rw-r--    1 ofi03 ofi03            138 Aug 31 12:39 etudiant.txt
-rw-rw-r--    1 ofi03 ofi03                0 Sep    5 12:26 exo1
-rw-rw-r--    1 ofi03 ofi03                0 Sep    5 12:26 exo2
-rw-------    1 ofi03 ofi03 33635764 Sep    8 09:32 heapdump.hprof
drwxr-xr-x    7 ofi03 ofi03          4096 Sep    7 12:48 hello.war/
-rw-rw-r--    1 ofi03 ofi03 75570057 Sep 30 09:11 instantclient-basic-linux.x64-
19.8.0.0.0dbru.zip
-rw-rw-r--    1 ofi03 ofi03      911254 Sep 30 09:12 instantclient-sqlplus-linux.x64-
19.8.0.0.0dbru.zip
lrwxrwxrwx    1 ofi03 ofi03                4 Sep    4 13:05 lien -> tp1//
lrwxrwxrwx    1 ofi03 ofi03                7 Aug 31 12:01 lien_backup -> backup//
drwxrwxr-x    4 ofi03 ofi03          4096 Aug 31 09:58 list/
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    7 13:44 monappli/
-rw-------    1 root    root                34 Sep 12 01:06 nano.save
-rw-------    1 root    root                34 Sep 12 01:06 nano.save.1
-rw-------    1 root    root                  9 Oct    3 15:25 nano.save.2
-rw-------    1 root    root                  8 Oct    3 15:25 nano.save.3
-rw-rw-r--    1 ofi03 ofi03              36 Aug 31 12:45 nom.txt
-rw-rw-r--    1 ofi03 ofi03              36 Sep    1 15:42 nom1.txt
drwxrwxr-x    6 ofi03 ofi03          4096 Sep 12 23:37 postgresql-tomcat/
-rw-rw-r--    1 ofi03 ofi03        10240 Aug 31 13:40 profile.tar
-rw-rw-r--    1 ofi03 ofi03          1556 Aug 31 13:47 profile.tar.bz2
-rw-rw-r--    1 ofi03 ofi03          1612 Aug 31 13:46 profile.tar.xz
drwxrwxr-x    3 ofi03 ofi03          4096 Oct    7 12:30 projetgit/
-rw-rw-r--    1 ofi03 ofi03          1317 Oct    6 12:49 psql.yml
-rw-rw-r--    1 ofi03 ofi03                0 Sep    4 21:44 resultat.txt
-rw-rw-r--    1 ofi03 ofi03          4606 Sep    7 13:18 sample.war
-rwxrwxr-x    1 ofi03 ofi03              43 Sep    2 07:56 script0.sh*
-rwxrwxr-x    1 ofi03 ofi03            196 Sep    2 08:21 script1.sh*
-rwxrwxr-x    1 ofi03 ofi03            110 Sep    2 10:29 script10.sh*
-rwxrwxr-x    1 ofi03 ofi03            106 Sep    2 12:08 script11.sh*
-rwxrwxr-x    1 ofi03 ofi03            111 Sep    2 12:22 script12.sh*
-rwxrwxr-x    1 ofi03 ofi03            106 Sep    2 12:27 script13.sh*
-rw-rw-r--    1 ofi03 ofi03                0 Sep    2 12:40 script14
-rw-rw-r--    1 ofi03 ofi03                0 Sep    2 12:38 script14.sh
-rw-rw-r--    1 ofi03 ofi03                0 Sep    2 13:27 script15.sh
-rw-rw-r--    1 ofi03 ofi03                0 Sep    2 13:28 script17.sh
-rwxrwxr-x    1 ofi03 ofi03              66 Sep    2 13:07 script18.sh*
-rwxrwxr-x    1 ofi03 ofi03            102 Sep    2 13:16 script19.sh*
-rw-rw-r--    1 ofi03 ofi03              67 Sep    2 08:29 script2.sh
-rwxrwxr-x    1 ofi03 ofi03              94 Sep    2 13:26 script20.sh*
-rwxrwxr-x    1 ofi03 ofi03            128 Sep    2 13:37 script21.sh*
-rwxrwxr-x    1 ofi03 ofi03            162 Sep    2 13:50 script22.sh*
-rwxrwxr-x    1 ofi03 ofi03            220 Sep    2 14:05 script23.sh*
-rwxrwxr-x    1 ofi03 ofi03            195 Sep    2 09:03 script3.sh*
-rwxrwxr-x    1 ofi03 ofi03            104 Sep    2 09:34 script4.sh*
-rwxrwxr-x    1 ofi03 ofi03              48 Sep    2 09:45 script5.sh*
-rwxrwxr-x    1 ofi03 ofi03              91 Sep    2 10:14 script6.sh*
-rwxrwxr-x    1 ofi03 ofi03            106 Sep    2 10:13 script7.sh*
-rwxrwxr-x    1 ofi03 ofi03            135 Sep    2 10:23 script8.sh*
-rwxrwxr-x    1 ofi03 ofi03            110 Sep    2 10:25 script9.sh*
-rw-rw-r--    1 ofi03 ofi03              94 Sep    4 21:38 sed.txt
drwx------    3 ofi03 ofi03          4096 Sep    5 12:20 snap/
drw-------    2 ofi03 ofi03          4096 Aug 31 09:35 system/
-rwxr-xr-x    1 ofi03 ofi03          2738 Aug 31 09:41 system.log*
-rw-rw-r--    1 ofi03 ofi03        10240 Aug 31 13:38 system.tar
-rw-rw-r--    1 ofi03 ofi03            208 Sep    5 13:24 system.tar.bz2
-rw-rw-r--    1 ofi03 ofi03            192 Sep    5 13:22 system.tar.gz
-rw-rw-r--    1 ofi03 ofi03            228 Sep    5 13:23 system.tar.xz
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    2 13:29 targz/
-rw-r--r--    1 root    root                  0 Sep    1 09:31 test.log
-rw-rw-r--    1 ofi03 ofi03                0 Sep    1 15:20 test_ssh.log
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    4 13:06 tp1/
drwxrwxr-x    3 ofi03 ofi03          4096 Sep    2 15:42 tp2/
-rw-------    1 ofi03 ofi03          2602 Sep    5 15:54 yes
-rw-r--r--    1 ofi03 ofi03            566 Sep    5 15:54 yes.pub
-rw-rw-r--    1 ofi03 ofi03          1543 Aug 31 13:52 {profile.tar.gz_old}
ofi03@svl200:~$
ofi03@svl200:~$ cd projetgit/
ofi03@svl200:~/projetgit$ ll
total 24
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 12:30 ./
drwxr-xr-x 23 ofi03 ofi03 4096 Oct    7 12:48 ../
drwxrwxr-x    8 ofi03 ofi03 4096 Oct    7 12:30 .git/
-rw-r--r--    1 root    root        17 Oct    7 09:08 .gitignore
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
-rw-rw-r--    1 ofi03 ofi03      84 Oct    7 10:16 index.html
-rw-------    1 ofi03 ofi03        1 Oct    7 12:30 nano.save
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:06 readme.md
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:07 tuto.pdf
ofi03@svl200:~/projetgit$ ssh
usage: ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bind_interface]
                      [-b bind_address] [-c cipher_spec] [-D [bind_address:]port]
                      [-E log_file] [-e escape_char] [-F configfile] [-I pkcs11]
                      [-i identity_file] [-J [user@]host[:port]] [-L address]
                      [-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p
port]
                      [-Q query_option] [-R address] [-S ctl_path] [-W host:port]
                      [-w local_tun[:remote_tun]] destination [command]
ofi03@svl200:~/projetgit$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/ofi03/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/ofi03/.ssh/id_rsa
Your public key has been saved in /home/ofi03/.ssh/id_rsa.pub
The key fingerprint is:
SHA256:aJJRPawe3YJ8O9UhVs+mqjDvpujCh+Y1PEQ2/gdNfUA ofi03@svl200
The key's randomart image is:
+---[RSA 3072]----+
|            .o .E..        |
|          .    +.o..o      |
|        =. +.+.o..+    |
|      + +=++ o..o      |
|        =.+oS+    .        |
|      o +..o    .          |
| . .= + ...            |
|    =..+ =..              |
| o.+o .++                |
+----[SHA256]-----+
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ git clone [email protected]:logwire9/projet1.git
Cloning into 'projet1'...
The authenticity of host 'gitlab.com (2606:4700:90:0:f22e:fbec:5bed:a9b9)' can't be
established.
ECDSA key fingerprint is SHA256:HbW3g8zUjNSksFbqTiUWPWg2Bq1x8xdGUrliXFzSnUw.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'gitlab.com,2606:4700:90:0:f22e:fbec:5bed:a9b9' (ECDSA) to
the list of known hosts.
[email protected]: Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights


and the repository exists.
ofi03@svl200:~/projetgit$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/ofi03/.ssh/id_rsa):
/home/ofi03/.ssh/id_rsa already exists.
Overwrite (y/n)? y
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/ofi03/.ssh/id_rsa
Your public key has been saved in /home/ofi03/.ssh/id_rsa.pub
The key fingerprint is:
SHA256:hpm4GC1loGb2hXkq+LQTT2iVVI96wz/VT/AERPK0bpU ofi03@svl200
The key's randomart image is:
+---[RSA 3072]----+
|    . ...      .o=        |
| . oo. o      + o . |
|.+ o=o. .      + E    |
|= .*++ +      o =      |
|..Bo= B S . + o    |
| +.O o + . . o      |
|    = o      o          .    |
|      .          .              |
|                                  |
+----[SHA256]-----+
ofi03@svl200:~/projetgit$ cd
ofi03@svl200:~$ cat .ssh/
authorized_keys    id_rsa                      id_rsa.pub              known_hosts
ofi03@svl200:~$ cat .ssh/id_rsa
id_rsa            id_rsa.pub
ofi03@svl200:~$ cat .ssh/id_rsa
id_rsa            id_rsa.pub
ofi03@svl200:~$ cat .ssh/id_rsa.pub
ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAABgQDRXIB324zopABpaxXK8QQKhwMWlILiCpMOnWZMzM5zejf2I0+eGYNGY
rva                                                                                 
+6LjnvcmZDUHKcS+19LeNewqk3o41xzSF6r2/FkKEc0xbu7bpY5Gyzxjh0XiDMVIFg3NjKBN17+9to5doSGYn
bBU53IFFEhF                                                                         
SBr3jg2+UzzSbmW76ZNlr7wu5kD/yoROkN7eRVmfjt4PtzwK3sg8gGEdhwDrgXlWkoYgw2BjoXtecnR27iXwF
nFoMsr2By05                                                                         
GZ0Ap7lTdZVqsIAyBZyyAov2VJwzn/4rEu8RPjBL8WtGr5PCImmv0flcWiEYKY7EvDHb3e+wI8t0Bi+ExIU8U
LifoOEYVXNH                                                                         
0mxM5RGVRFBrOFI654286qWe9PxYzioFJ/w8j0YqAtPKtA9E32zR9LN+cLtu7vUBrhPDFjBSNxO/+/
iUR0Ig+R4mvfYWgont                                                                   
uICBvDQ5vC6zx9E/BvZsY21kopqh62KzqwsmJPe0benNsLMomNSMzh2zlKCIqJytSFIMtKk= ofi03@svl200
ofi03@svl200:~$ ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAABgQDRXIB324zopABpaxXK8QQKhwMWlILiCpMOnWZMzM5z             
ejf2I0+eGYNGYrva+6LjnvcmZDUHKcS+19LeNewqk3o41xzSF6r2/FkKEc0xbu7bpY5Gyzxjh0XiDMVIFg3Nj
KBN17+9to5d                                                                         
oSGYnbBU53IFFEhFSBr3jg2+UzzSbmW76ZNlr7wu5kD/yoROkN7eRVmfjt4PtzwK3sg8gGEdhwDrgXlWkoYgw
2BjoXtecnR2                                                                         
7iXwFnFoMsr2By05GZ0Ap7lTdZVqsIAyBZyyAov2VJwzn/4rEu8RPjBL8WtGr5PCImmv0flcWiEYKY7EvDHb3
e+wI8t0Bi+E                                                                         
xIU8ULifoOEYVXNH0mxM5RGVRFBrOFI654286qWe9PxYzioFJ/w8j0YqAtPKtA9E32zR9LN+cLtu7vUBrhPDF
jBSNxO/+/iU                                                                         
R0Ig+R4mvfYWgontuICBvDQ5vC6zx9E/BvZsY21kopqh62KzqwsmJPe0benNsLMomNSMzh2zlKCIqJytSFIMt
Kk= ofi03@s                                                                         
vl200
ssh-rsa: command not found
ofi03@svl200:~$ ^C
ofi03@svl200:~$
ofi03@svl200:~$ cd projetgit/.
ofi03@svl200:~/projetgit$ git clone [email protected]:logwire9/projet1.git
Cloning into 'projet1'...
remote: Enumerating objects: 9, done.
remote: Counting objects: 100% (9/9), done.
remote: Compressing objects: 100% (5/5), done.
remote: Total 9 (delta 1), reused 0 (delta 0), pack-reused 0
Receiving objects: 100% (9/9), done.
Resolving deltas: 100% (1/1), done.
ofi03@svl200:~/projetgit$ ll
total 28
drwxrwxr-x    4 ofi03 ofi03 4096 Oct    7 12:57 ./
drwxr-xr-x 23 ofi03 ofi03 4096 Oct    7 12:48 ../
drwxrwxr-x    8 ofi03 ofi03 4096 Oct    7 12:30 .git/
-rw-r--r--    1 root    root        17 Oct    7 09:08 .gitignore
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
-rw-rw-r--    1 ofi03 ofi03      84 Oct    7 10:16 index.html
-rw-------    1 ofi03 ofi03        1 Oct    7 12:30 nano.save
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 12:57 projet1/
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:06 readme.md
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:07 tuto.pdf
ofi03@svl200:~/projetgit$ cd projet1/
ofi03@svl200:~/projetgit/projet1$ ll
total 20
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 12:57 ./
drwxrwxr-x 4 ofi03 ofi03 4096 Oct    7 12:57 ../
drwxrwxr-x 8 ofi03 ofi03 4096 Oct    7 12:57 .git/
-rw-rw-r-- 1 ofi03 ofi03      17 Oct    7 12:57 .gitignore
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 fichier.html
-rw-rw-r-- 1 ofi03 ofi03      42 Oct    7 12:57 index.html
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 readme.md
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 tuto.pdf
ofi03@svl200:~/projetgit/projet1$
ofi03@svl200:~/projetgit/projet1$ sudo vim conflit.txt
[sudo] password for ofi03:
ofi03@svl200:~/projetgit/projet1$ sudo vim java.txt
ofi03@svl200:~/projetgit/projet1$ sudo vim java.txt
ofi03@svl200:~/projetgit/projet1$ git add .
ofi03@svl200:~/projetgit/projet1$ git commit -m "ajout fichier java"
[master 98ff414] ajout fichier java
2 files changed, 6 insertions(+)
create mode 100644 conflit.txt
create mode 100644 java.txt
ofi03@svl200:~/projetgit/projet1$ git push conflit.txt
fatal: invalid gitfile format: conflit.txt
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
ofi03@svl200:~/projetgit/projet1$ git push
Enumerating objects: 4, done.
Counting objects: 100% (4/4), done.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 351 bytes | 351.00 KiB/s, done.
Total 3 (delta 1), reused 0 (delta 0)
To gitlab.com:logwire9/projet1.git
      ec25a48..98ff414    master -> master
ofi03@svl200:~/projetgit/projet1$ sudo vim java.txt
ofi03@svl200:~/projetgit/projet1$ git add .
ofi03@svl200:~/projetgit/projet1$ git commit -m "modif fichier java"
[master 5a5d165] modif fichier java
1 file changed, 1 insertion(+), 1 deletion(-)
ofi03@svl200:~/projetgit/projet1$ git push
Enumerating objects: 5, done.
Counting objects: 100% (5/5), done.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 336 bytes | 336.00 KiB/s, done.
Total 3 (delta 1), reused 0 (delta 0)
To gitlab.com:logwire9/projet1.git
      98ff414..5a5d165    master -> master
ofi03@svl200:~/projetgit/projet1$ git pull
Already up to date.
ofi03@svl200:~/projetgit/projet1$ sudo vim java.txt
ofi03@svl200:~/projetgit/projet1$ git add .
ofi03@svl200:~/projetgit/projet1$ git commit -m "modif fichier"
On branch master
Your branch is up to date with 'origin/master'.

nothing to commit, working tree clean


ofi03@svl200:~/projetgit/projet1$ git push
Everything up-to-date
ofi03@svl200:~/projetgit/projet1$
ofi03@svl200:~/projetgit/projet1$ git branch
* master
ofi03@svl200:~/projetgit/projet1$ git branch dev
ofi03@svl200:~/projetgit/projet1$ git branch
    dev
* master
ofi03@svl200:~/projetgit/projet1$ git branch dev
fatal: A branch named 'dev' already exists.
ofi03@svl200:~/projetgit/projet1$ git branch
    dev
* master
ofi03@svl200:~/projetgit/projet1$ git checkout dev
Switched to branch 'dev'
ofi03@svl200:~/projetgit/projet1$ git branch
* dev
    master
ofi03@svl200:~/projetgit/projet1$ ll
total 24
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:12 ./
drwxrwxr-x 4 ofi03 ofi03 4096 Oct    7 12:57 ../
drwxrwxr-x 8 ofi03 ofi03 4096 Oct    7 13:23 .git/
-rw-rw-r-- 1 ofi03 ofi03      17 Oct    7 12:57 .gitignore
-rw-r--r-- 1 root    root          0 Oct    7 13:04 conflit.txt
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 fichier.html
-rw-rw-r-- 1 ofi03 ofi03      42 Oct    7 12:57 index.html
-rw-r--r-- 1 root    root        94 Oct    7 13:12 java.txt
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 readme.md
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 tuto.pdf
ofi03@svl200:~/projetgit/projet1$ git log --oneline
5a5d165 (HEAD -> dev, origin/master, origin/HEAD, master) modif fichier java
98ff414 ajout fichier java
ec25a48 modif index
73cde3e ajout .gitignore
38d2f37 aaw
ofi03@svl200:~/projetgit/projet1$ git push conflit.txt
fatal: invalid gitfile format: conflit.txt
fatal: Could not read from remote repository.

Please make sure you have the correct access rights


and the repository exists.
ofi03@svl200:~/projetgit/projet1$ sudo vim conflit.txt
ofi03@svl200:~/projetgit/projet1$ git add .
ofi03@svl200:~/projetgit/projet1$ git commit -m "modif fichier conflit"
[dev 39d40ef] modif fichier conflit
1 file changed, 2 insertions(+)
ofi03@svl200:~/projetgit/projet1$ git push
fatal: The current branch dev has no upstream branch.
To push the current branch and set the remote as upstream, use

        git push --set-upstream origin dev

ofi03@svl200:~/projetgit/projet1$ git log --oneline --gr


--graph      --grep=
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate --a
--abbrev                    --abbrev=                  --all                         
--author=
--abbrev-commit      --after=                    --all-match
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate --all
* 39d40ef (HEAD -> dev) modif fichier conflit
* 5a5d165 (origin/master, origin/HEAD, master) modif fichier java
* 98ff414 ajout fichier java
* ec25a48 modif index
* 73cde3e ajout .gitignore
* 38d2f37 aaw
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate --all
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate --all
* 39d40ef (HEAD -> dev) modif fichier conflit
* 5a5d165 (origin/master, origin/HEAD, master) modif fichier java
* 98ff414 ajout fichier java
* ec25a48 modif index
* 73cde3e ajout .gitignore
* 38d2f37 aaw
ofi03@svl200:~/projetgit/projet1$ git add .
ofi03@svl200:~/projetgit/projet1$ git push
fatal: The current branch dev has no upstream branch.
To push the current branch and set the remote as upstream, use

        git push --set-upstream origin dev

ofi03@svl200:~/projetgit/projet1$ git commit -m "modif fichier conflit"


On branch dev
nothing to commit, working tree clean
ofi03@svl200:~/projetgit/projet1$ git commit -m "modif fichier conflit.txt"
On branch dev
nothing to commit, working tree clean
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph
FETCH_HEAD            ORIG_HEAD              master                    origin/master
HEAD                        dev                          origin/HEAD
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --
Display all 115 possibilities? (y or n)
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate -all
error: switch `l' expects a numerical value
ofi03@svl200:~/projetgit/projet1$ git dev --oneline --graph --decorate -all
git: 'dev' is not a git command. See 'git --help'.

The most similar commands are


                daemon
                diff
                grep
                help
                mv
                revert
ofi03@svl200:~/projetgit/projet1$
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate --all
* 39d40ef (HEAD -> dev) modif fichier conflit
* 5a5d165 (origin/master, origin/HEAD, master) modif fichier java
* 98ff414 ajout fichier java
* ec25a48 modif index
* 73cde3e ajout .gitignore
* 38d2f37 aaw
ofi03@svl200:~/projetgit/projet1$ git checkout master
Switched to branch 'master'
Your branch is up to date with 'origin/master'.
ofi03@svl200:~/projetgit/projet1$ git merge dev
Updating 5a5d165..39d40ef
Fast-forward
conflit.txt | 2 ++
1 file changed, 2 insertions(+)
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate --all
* 39d40ef (HEAD -> master, dev) modif fichier conflit
* 5a5d165 (origin/master, origin/HEAD) modif fichier java
* 98ff414 ajout fichier java
* ec25a48 modif index
* 73cde3e ajout .gitignore
* 38d2f37 aaw
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate --all
* 39d40ef (HEAD -> master, dev) modif fichier conflit
* 5a5d165 (origin/master, origin/HEAD) modif fichier java
* 98ff414 ajout fichier java
* ec25a48 modif index
* 73cde3e ajout .gitignore
* 38d2f37 aaw
ofi03@svl200:~/projetgit/projet1$ git push
Enumerating objects: 5, done.
Counting objects: 100% (5/5), done.
Compressing objects: 100% (2/2), done.
Writing objects: 100% (3/3), 263 bytes | 263.00 KiB/s, done.
Total 3 (delta 1), reused 0 (delta 0)
To gitlab.com:logwire9/projet1.git
      5a5d165..39d40ef    master -> master
ofi03@svl200:~/projetgit/projet1$ git log --oneline --graph --decorate --all
* 39d40ef (HEAD -> master, origin/master, origin/HEAD, dev) modif fichier conflit
* 5a5d165 modif fichier java
* 98ff414 ajout fichier java
* ec25a48 modif index
* 73cde3e ajout .gitignore
* 38d2f37 aaw
ofi03@svl200:~/projetgit/projet1$
ofi03@svl200:~/projetgit/projet1$ cd ../../
ofi03@svl200:~$ mkdir projetmerge
ofi03@svl200:~$ cd projetmerge/
ofi03@svl200:~/projetmerge$ git clone https://gitlab.com/logwire7/projet1.git
Cloning into 'projet1'...
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
remote: Enumerating objects: 50, done.
remote: Counting objects: 100% (50/50), done.
remote: Compressing objects: 100% (40/40), done.
remote: Total 50 (delta 13), reused 0 (delta 0), pack-reused 0
Unpacking objects: 100% (50/50), 4.55 KiB | 186.00 KiB/s, done.
ofi03@svl200:~/projetmerge$ git branch
fatal: not a git repository (or any of the parent directories): .git
ofi03@svl200:~/projetmerge$ cd ..
ofi03@svl200:~$ cd projet
projetgit/      projetmerge/
ofi03@svl200:~$ cd projetgit/
ofi03@svl200:~/projetgit$ mv ../projetmerge/ ..
mv: '../projetmerge/' and '../projetmerge' are the same file
*ofi03@svl200:~/projetgit$ mv ../projetmerge/ .
ofi03@svl200:~/projetgit$ ll
total 32
drwxrwxr-x    5 ofi03 ofi03 4096 Oct    7 13:54 ./
drwxr-xr-x 23 ofi03 ofi03 4096 Oct    7 13:54 ../
drwxrwxr-x    8 ofi03 ofi03 4096 Oct    7 12:30 .git/
-rw-r--r--    1 root    root        17 Oct    7 09:08 .gitignore
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
-rw-rw-r--    1 ofi03 ofi03      84 Oct    7 10:16 index.html
-rw-------    1 ofi03 ofi03        1 Oct    7 12:30 nano.save
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 13:33 projet1/
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 13:51 projetmerge/
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:06 readme.md
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:07 tuto.pdf
ofi03@svl200:~/projetgit$ cd projetmerge/
ofi03@svl200:~/projetgit/projetmerge$ git branch
* master
ofi03@svl200:~/projetgit/projetmerge$ git clone
https://gitlab.com/logwire7/projet1.git
fatal: destination path 'projet1' already exists and is not an empty directory.
ofi03@svl200:~/projetgit/projetmerge$
ofi03@svl200:~/projetgit/projetmerge$ git branch aaw
ofi03@svl200:~/projetgit/projetmerge$ git branch
    aaw
* master
ofi03@svl200:~/projetgit/projetmerge$ git checkout aaw
M              index.html
Switched to branch 'aaw'
ofi03@svl200:~/projetgit/projetmerge$ git branch
* aaw
    master
ofi03@svl200:~/projetgit/projetmerge$ ll
total 12
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:51 ./
drwxrwxr-x 5 ofi03 ofi03 4096 Oct    7 13:54 ../
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:52 projet1/
ofi03@svl200:~/projetgit/projetmerge$ sudo vim aaw.txt
[sudo] password for ofi03:
ofi03@svl200:~/projetgit/projetmerge$ git push origin aaw
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
Enumerating objects: 9, done.
Counting objects: 100% (9/9), done.
Compressing objects: 100% (5/5), done.
Writing objects: 100% (9/9), 728 bytes | 121.00 KiB/s, done.
Total 9 (delta 1), reused 0 (delta 0)
remote:
remote: To create a merge request for aaw, visit:
remote:      https://gitlab.com/logwire9/projet1/-/merge_requests/new?merge_request
%5Bsource_branch                                                                     
%5D=aaw
remote:
To https://gitlab.com/logwire9/projet1.git
* [new branch]            aaw -> aaw
ofi03@svl200:~/projetgit/projetmerge$
ofi03@svl200:~/projetgit/projetmerge$ ll
total 16
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:59 ./
drwxrwxr-x 5 ofi03 ofi03 4096 Oct    7 13:54 ../
-rw-r--r-- 1 root    root          7 Oct    7 13:59 aaw.txt
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:52 projet1/
ofi03@svl200:~/projetgit/projetmerge$ git branch
* aaw
    master
ofi03@svl200:~/projetgit/projetmerge$ cd
ofi03@svl200:~$ cd projetgit/
.git/                projet1/          projetmerge/
ofi03@svl200:~$ cd projetgit/projet1/
ofi03@svl200:~/projetgit/projet1$ ll
total 28
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:33 ./
drwxrwxr-x 5 ofi03 ofi03 4096 Oct    7 13:54 ../
drwxrwxr-x 8 ofi03 ofi03 4096 Oct    7 13:33 .git/
-rw-rw-r-- 1 ofi03 ofi03      17 Oct    7 12:57 .gitignore
-rw-rw-r-- 1 ofi03 ofi03        9 Oct    7 13:33 conflit.txt
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 fichier.html
-rw-rw-r-- 1 ofi03 ofi03      42 Oct    7 12:57 index.html
-rw-r--r-- 1 root    root        94 Oct    7 13:12 java.txt
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 readme.md
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 tuto.pdf
ofi03@svl200:~/projetgit/projet1$ git branch
    dev
* master
ofi03@svl200:~/projetgit/projet1$ git branch aaw
ofi03@svl200:~/projetgit/projet1$ git branch
    aaw
    dev
* master
ofi03@svl200:~/projetgit/projet1$ git checkout aaw
Switched to branch 'aaw'
ofi03@svl200:~/projetgit/projet1$ ll
total 28
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:33 ./
drwxrwxr-x 5 ofi03 ofi03 4096 Oct    7 13:54 ../
drwxrwxr-x 8 ofi03 ofi03 4096 Oct    7 14:07 .git/
-rw-rw-r-- 1 ofi03 ofi03      17 Oct    7 12:57 .gitignore
-rw-rw-r-- 1 ofi03 ofi03        9 Oct    7 13:33 conflit.txt
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 fichier.html
-rw-rw-r-- 1 ofi03 ofi03      42 Oct    7 12:57 index.html
-rw-r--r-- 1 root    root        94 Oct    7 13:12 java.txt
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 readme.md
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 12:57 tuto.pdf
ofi03@svl200:~/projetgit/projet1$ sudo vim index.html
ofi03@svl200:~/projetgit/projet1$ git add .
ofi03@svl200:~/projetgit/projet1$ git commit -m "modif index"
[aaw 39942c8] modif index
1 file changed, 2 insertions(+)
ofi03@svl200:~/projetgit/projet1$ git push origin aaw
Enumerating objects: 5, done.
Counting objects: 100% (5/5), done.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 288 bytes | 288.00 KiB/s, done.
Total 3 (delta 1), reused 0 (delta 0)
remote:
remote: To create a merge request for aaw, visit:
remote:      https://gitlab.com/logwire9/projet1/-/merge_requests/new?merge_request
%5Bsource_branch                                                                     
%5D=aaw
remote:
To gitlab.com:logwire9/projet1.git
      ec25a48..39942c8    aaw -> aaw
ofi03@svl200:~/projetgit/projet1$ git push origin master
Everything up-to-date
ofi03@svl200:~/projetgit/projet1$ cd ..
ofi03@svl200:~/projetgit$ cd
.git/                projet1/          projetmerge/
ofi03@svl200:~/projetgit$ cd projetmerge/
ofi03@svl200:~/projetgit/projetmerge$
ofi03@svl200:~/projetgit/projetmerge$ ll
total 16
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:59 ./
drwxrwxr-x 5 ofi03 ofi03 4096 Oct    7 13:54 ../
-rw-r--r-- 1 root    root          7 Oct    7 13:59 aaw.txt
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:52 projet1/
ofi03@svl200:~/projetgit/projetmerge$ sudo vim aaw.txt
ofi03@svl200:~/projetgit/projetmerge$ cd projet1/
ofi03@svl200:~/projetgit/projetmerge/projet1$ ll
total 40
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 13:52 ./
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 14:13 ../
drwxrwxr-x 8 ofi03 ofi03 4096 Oct    7 13:52 .git/
-rw-rw-r-- 1 ofi03 ofi03      17 Oct    7 13:52 .gitignore
-rw-rw-r-- 1 ofi03 ofi03      44 Oct    7 13:52 conflit.txt
-rw-rw-r-- 1 ofi03 ofi03      19 Oct    7 13:52 conflit1.txt
-rw-rw-r-- 1 ofi03 ofi03      99 Oct    7 13:52 index.html
-rw-rw-r-- 1 ofi03 ofi03      95 Oct    7 13:52 projet.java
-rw-rw-r-- 1 ofi03 ofi03      15 Oct    7 13:52 test.txt
-rw-rw-r-- 1 ofi03 ofi03      23 Oct    7 13:52 test1.txt
ofi03@svl200:~/projetgit/projetmerge/projet1$ sudo vim index.html
ofi03@svl200:~/projetgit/projetmerge/projet1$ git add .
ofi03@svl200:~/projetgit/projetmerge/projet1$ git commit -m "modif index"
[master 587445f] modif index
1 file changed, 1 insertion(+)
ofi03@svl200:~/projetgit/projetmerge/projet1$ git push origin aaw
error: src refspec aaw does not match any
error: failed to push some refs to 'https://gitlab.com/logwire7/projet1.git'
ofi03@svl200:~/projetgit/projetmerge/projet1$ git branch
* master
ofi03@svl200:~/projetgit/projetmerge/projet1$ git branch
HEAD                        master                    origin/HEAD          origin/dev
origin/master
ofi03@svl200:~/projetgit/projetmerge/projet1$ git branch aaw
ofi03@svl200:~/projetgit/projetmerge/projet1$ git chekout branch
.git/                  conflit.txt      index.html        test.txt
.gitignore        conflit1.txt    projet.java      test1.txt
ofi03@svl200:~/projetgit/projetmerge/projet1$ git branch
    aaw
* master
ofi03@svl200:~/projetgit/projetmerge/projet1$ git checkout aaw
Switched to branch 'aaw'
ofi03@svl200:~/projetgit/projetmerge/projet1$ git push origin aaw
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
Enumerating objects: 5, done.
Counting objects: 100% (5/5), done.
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 285 bytes | 285.00 KiB/s, done.
Total 3 (delta 2), reused 0 (delta 0)
remote:
remote: To create a merge request for aaw, visit:
remote:      https://gitlab.com/logwire7/projet1/-/merge_requests/new?merge_request
%5Bsource_branch                                                                     
%5D=aaw
remote:
To https://gitlab.com/logwire7/projet1.git
* [new branch]            aaw -> aaw
ofi03@svl200:~/projetgit/projetmerge/projet1$ git push origin master
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
To https://gitlab.com/logwire7/projet1.git
! [rejected]              master -> master (fetch first)
error: failed to push some refs to 'https://gitlab.com/logwire7/projet1.git'
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
ofi03@svl200:~/projetgit/projetmerge/projet1$
ofi03@svl200:~/projetgit/projetmerge/projet1$ git checkout aaw^C
ofi03@svl200:~/projetgit/projetmerge/projet1$ git tag
ofi03@svl200:~/projetgit/projetmerge/projet1$ ll
total 40
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 14:13 ./
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 14:13 ../
drwxrwxr-x 8 ofi03 ofi03 4096 Oct    7 14:15 .git/
-rw-rw-r-- 1 ofi03 ofi03      17 Oct    7 13:52 .gitignore
-rw-rw-r-- 1 ofi03 ofi03      44 Oct    7 13:52 conflit.txt
-rw-rw-r-- 1 ofi03 ofi03      19 Oct    7 13:52 conflit1.txt
-rw-rw-r-- 1 ofi03 ofi03    109 Oct    7 14:13 index.html
-rw-rw-r-- 1 ofi03 ofi03      95 Oct    7 13:52 projet.java
-rw-rw-r-- 1 ofi03 ofi03      15 Oct    7 13:52 test.txt
-rw-rw-r-- 1 ofi03 ofi03      23 Oct    7 13:52 test1.txt
ofi03@svl200:~/projetgit/projetmerge/projet1$ git log --oneline
587445f (HEAD -> aaw, origin/aaw, master) modif index
2921237 (origin/master, origin/dev, origin/HEAD) modification de fichier conflit
dfc5039 modif3
47c130b modif java file
3c39d43 Update projet.java
1d48e1d ajout fichier java
002abdd Merge branch 'master' of gitlab.com:logwire7/projet1
dbd7ce2 ajout conflit1
cea8cbf Add new file
5b29683 ajout file2
fe14cd1 ajout new file
0494cd8 modif index
a271a83 modification2 fichier
f615b42 modification de fichier index.html
9b9d48b ajout gitignore
49c8531 delete readme
45109db ajout readme
9283318 rename file
ac74d1b modif1 fichier.html
dd11c8f ajout fichier.html
ofi03@svl200:~/projetgit/projetmerge/projet1$ git tag v1.2 45109db
ofi03@svl200:~/projetgit/projetmerge/projet1$ git log --oneline
587445f (HEAD -> aaw, origin/aaw, master) modif index
2921237 (origin/master, origin/dev, origin/HEAD) modification de fichier conflit
dfc5039 modif3
47c130b modif java file
3c39d43 Update projet.java
1d48e1d ajout fichier java
002abdd Merge branch 'master' of gitlab.com:logwire7/projet1
dbd7ce2 ajout conflit1
cea8cbf Add new file
5b29683 ajout file2
fe14cd1 ajout new file
0494cd8 modif index
a271a83 modification2 fichier
f615b42 modification de fichier index.html
9b9d48b ajout gitignore
49c8531 delete readme
45109db (tag: v1.2) ajout readme
9283318 rename file
ac74d1b modif1 fichier.html
dd11c8f ajout fichier.html
ofi03@svl200:~/projetgit/projetmerge/projet1$
ofi03@svl200:~/projetgit/projetmerge/projet1$ git log --oneline
587445f (HEAD -> aaw, origin/aaw, master) modif index
2921237 (origin/master, origin/dev, origin/HEAD) modification de fichier conflit
dfc5039 modif3
47c130b modif java file
3c39d43 Update projet.java
1d48e1d ajout fichier java
002abdd Merge branch 'master' of gitlab.com:logwire7/projet1
dbd7ce2 ajout conflit1
cea8cbf Add new file
5b29683 ajout file2
fe14cd1 ajout new file
0494cd8 modif index
a271a83 modification2 fichier
f615b42 modification de fichier index.html
9b9d48b ajout gitignore
49c8531 delete readme
45109db (tag: v1.2) ajout readme
9283318 rename file
ac74d1b modif1 fichier.html
dd11c8f ajout fichier.html
ofi03@svl200:~/projetgit/projetmerge/projet1$ git tag v1.2 cea8cbf
fatal: tag 'v1.2' already exists
ofi03@svl200:~/projetgit/projetmerge/projet1$ git push origin v1.2
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
Everything up-to-date
ofi03@svl200:~/projetgit/projetmerge/projet1$ git tag v1.3 45109db
ofi03@svl200:~/projetgit/projetmerge/projet1$ git push origin v1.3
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
Total 0 (delta 0), reused 0 (delta 0)
To https://gitlab.com/logwire7/projet1.git
* [new tag]                  v1.3 -> v1.3
ofi03@svl200:~/projetgit/projetmerge/projet1$
ofi03@svl200:~/projetgit/projetmerge/projet1$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
─────────────────────────────────────────────────────────────────────────────────────
───────────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file

Network error: Network is unreachable

─────────────────────────────────────────────────────────────────────────────────────
─────────────────────────────────────────────────────────────────────────────────────
───────────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.
      https://ubuntu.com/blog/microk8s-memory-optimisation

11 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

New release '22.04.1 LTS' available.


Run 'do-release-upgrade' to upgrade to it.

*** System restart required ***


Last login: Fri Oct    7 12:48:10 2022 from 176.160.191.208
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$ ls -lrt
total 172
-rw-r--r--    1 root          root                0 Oct    3 10:12 cible1.txt
-rw-r--r--    1 root          root            224 Oct    3 12:31 nginx.yaml
-rw-r--r--    1 root          root            199 Oct    3 13:01 shell.yml
-rw-r--r--    1 root          root            428 Oct    3 13:28 handler.yaml
-rw-r--r--    1 root          root              24 Oct    3 13:38 index.html
-rw-r--r--    1 root          root            247 Oct    3 14:37 fact.yaml
-rw-r--r--    1 root          root                0 Oct    3 14:40 ip.txt
-rw-r--r--    1 ansadmin ansadmin    179 Oct    3 14:46 fact1.yaml
-rw-r--r--    1 ansadmin ansadmin    277 Oct    3 17:57 debug1.yaml
-rw-r--r--    1 root          root            304 Oct    3 17:58 when.yaml
-rw-r--r--    1 root          root            190 Oct    4 08:34 exo2.yaml
-rw-r--r--    1 root          root            175 Oct    4 08:44 exo3.yaml
-rw-r--r--    1 root          root            316 Oct    4 09:32 when1.yaml
-rw-r--r--    1 root          root            595 Oct    4 09:57 rep.yaml
-rw-r--r--    1 root          root            235 Oct    4 10:08 list.yaml
-rw-r--r--    1 root          root            244 Oct    4 10:20 items.yaml
-rw-r--r--    1 root          root                0 Oct    4 10:24 items_users.yaml
-rw-r--r--    1 ansadmin ansadmin    247 Oct    4 10:35 item_users.yaml
-rw-r--r--    1 ansadmin ansadmin    209 Oct    4 12:04 seq.yaml
-rw-r--r--    1 root          root            173 Oct    4 12:29 copie.yaml
-rw-r--r--    1 root          root            243 Oct    4 13:01 index.html.j2
-rw-r--r--    1 ansadmin ansadmin    135 Oct    4 13:01 index.html1.j2
-rw-r--r--    1 root          root            147 Oct    4 13:05 exo4.yaml
-rw-r--r--    1 root          root            228 Oct    4 13:14 template.yaml
-rw-r--r--    1 ansadmin ansadmin    254 Oct    4 13:21 template1.yaml
-rw-------    1 ansadmin ansadmin    355 Oct    4 13:26 hello.yml
-rw-------    1 ansadmin ansadmin    255 Oct    4 13:34 hello.yaml
-rw-r--r--    1 root          root            254 Oct    4 13:41 play-vars.yaml
-rw-------    1 ansadmin ansadmin    273 Oct    4 13:49 play-vars.yml
-rw-r--r--    1 root          root            184 Oct    4 13:58 locale.yml
-rw-r--r--    1 root          root            268 Oct    4 14:35 var_dic.yml
-rw-r--r--    1 ansadmin ansadmin    146 Oct    4 15:07 vars.yml
-rw-r--r--    1 ansadmin ansadmin    280 Oct    4 15:12 var_dic2.yml
-rw-r--r--    1 root          root            237 Oct    5 08:08 vars_multi.yml
drwx------    3 ansadmin ansadmin 4096 Oct    5 10:20 snap
-rw-r--r--    1 ansadmin ansadmin    149 Oct    5 10:26 vars2.yml
-rw-r--r--    1 root          root            261 Oct    5 11:29 debug.yaml
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    5 13:14 projet1
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    5 13:44 projet
-rw-r--r--    1 root          root            337 Oct    5 14:04 var_dic_multi3.yml
drwxrwxr-x 10 ansadmin ansadmin 4096 Oct    5 14:49 projet3
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    5 15:09 projet4
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    6 07:29 projet2
drwxr-xr-x    3 root          root          4096 Oct    6 09:27 TP3
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    6 18:05 TPansible
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 12:36 git
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ll
total 52
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    6 18:05 ./
drwxr-xr-x 13 ansadmin ansadmin 4096 Oct    7 12:36 ../
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    6 15:10 TPpostgres/
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    6 15:06 roles/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$ cd roles/
ansadmin@svl200:~/TPansible/roles$ ll
total 16
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    6 15:06 ./
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 18:05 ../
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 14:57 postgres/
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 09:40 users/
ansadmin@svl200:~/TPansible/roles$ cd postgres/
ansadmin@svl200:~/TPansible/roles/postgres$ ll
total 24
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 14:57 ./
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    6 15:06 ../
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    6 14:57 handlers/
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    6 14:57 tasks/
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    6 14:57 templates/
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    6 14:57 vars/
ansadmin@svl200:~/TPansible/roles/postgres$ tree
.
├── handlers
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
│   └── index.html.j2
└── vars
        └── main.yml

4 directories, 4 files
ansadmin@svl200:~/TPansible/roles/postgres$ sudo vim handlers/main.yml
ansadmin@svl200:~/TPansible/roles/postgres$ cd ..
ansadmin@svl200:~/TPansible/roles$ ll
total 16
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    6 15:06 ./
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 18:05 ../
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 14:57 postgres/
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 09:40 users/
ansadmin@svl200:~/TPansible/roles$ cd ..
ansadmin@svl200:~/TPansible$ LL
LL: command not found
ansadmin@svl200:~/TPansible$ ll
total 52
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    6 18:05 ./
drwxr-xr-x 13 ansadmin ansadmin 4096 Oct    7 12:36 ../
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    6 15:10 TPpostgres/
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    6 15:06 roles/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$ mv -r TPpostgres/ roles/
mv: invalid option -- 'r'
Try 'mv --help' for more information.
ansadmin@svl200:~/TPansible$ mv TPpostgres/ roles/
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ ll
total 48
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    7 18:43 ./
drwxr-xr-x 13 ansadmin ansadmin 4096 Oct    7 12:36 ../
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    7 18:43 roles/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$ cd roles
ansadmin@svl200:~/TPansible/roles$ ll
total 20
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    7 18:43 ./
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    7 18:43 ../
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    6 15:10 TPpostgres/
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    6 14:57 postgres/
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    6 09:40 users/
ansadmin@svl200:~/TPansible/roles$ mv TPpostgres/ ../
ansadmin@svl200:~/TPansible/roles$ ll
total 16
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    7 18:44 ./
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    7 18:44 ../
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 14:57 postgres/
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    6 09:40 users/
ansadmin@svl200:~/TPansible/roles$ cd ..
ansadmin@svl200:~/TPansible$ ll
total 52
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    7 18:44 ./
drwxr-xr-x 13 ansadmin ansadmin 4096 Oct    7 12:36 ../
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    6 15:10 TPpostgres/
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$ mv roles/ TPpostgres/
ansadmin@svl200:~/TPansible$ cd TPpostgres/
ansadmin@svl200:~/TPansible/TPpostgres$ ll
total 60
drwxrwxr-x 13 ansadmin ansadmin 4096 Oct    7 18:45 ./
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    7 18:45 ../
-rw-rw-r--    1 ansadmin ansadmin    539 Oct    6 15:04 .travis.yml
-rw-rw-r--    1 ansadmin ansadmin 1328 Oct    6 15:04 README.md
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 defaults/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 files/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    6 15:10 group_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 handlers/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:10 hosts_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 meta/
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tasks/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 templates/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tests/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:15 vars/
ansadmin@svl200:~/TPansible/TPpostgres$ cd roles/
ansadmin@svl200:~/TPansible/TPpostgres/roles$ ll
total 16
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 ./
drwxrwxr-x 13 ansadmin ansadmin 4096 Oct    7 18:45 ../
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    6 14:57 postgres/
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    6 09:40 users/
ansadmin@svl200:~/TPansible/TPpostgres/roles$ cd ..
ansadmin@svl200:~/TPansible/TPpostgres$ mv roles roles1
ansadmin@svl200:~/TPansible/TPpostgres$ ll
total 60
drwxrwxr-x 13 ansadmin ansadmin 4096 Oct    7 18:48 ./
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    7 18:45 ../
-rw-rw-r--    1 ansadmin ansadmin    539 Oct    6 15:04 .travis.yml
-rw-rw-r--    1 ansadmin ansadmin 1328 Oct    6 15:04 README.md
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 defaults/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 files/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    6 15:10 group_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 handlers/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:10 hosts_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 meta/
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles1/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tasks/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 templates/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tests/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:15 vars/
ansadmin@svl200:~/TPansible/TPpostgres$ mkdir roles
ansadmin@svl200:~/TPansible/TPpostgres$ ll
total 64
drwxrwxr-x 14 ansadmin ansadmin 4096 Oct    7 18:48 ./
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    7 18:45 ../
-rw-rw-r--    1 ansadmin ansadmin    539 Oct    6 15:04 .travis.yml
-rw-rw-r--    1 ansadmin ansadmin 1328 Oct    6 15:04 README.md
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 defaults/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 files/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    6 15:10 group_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 handlers/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:10 hosts_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 meta/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 18:48 roles/
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles1/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tasks/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 templates/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tests/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:15 vars/
ansadmin@svl200:~/TPansible/TPpostgres$ vim README.md
ansadmin@svl200:~/TPansible/TPpostgres$ mv * roles
roles/    roles1/
ansadmin@svl200:~/TPansible/TPpostgres$ mv * roles
mv: cannot move 'roles' to a subdirectory of itself, 'roles/roles'
ansadmin@svl200:~/TPansible/TPpostgres$ mv roles/ ../
ansadmin@svl200:~/TPansible/TPpostgres$ ll
total 12
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 18:51 ./
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    7 18:51 ../
-rw-rw-r-- 1 ansadmin ansadmin    539 Oct    6 15:04 .travis.yml
ansadmin@svl200:~/TPansible/TPpostgres$ cd ..
ansadmin@svl200:~/TPansible$ ll
total 52
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    7 18:51 ./
drwxr-xr-x 13 ansadmin ansadmin 4096 Oct    7 18:49 ../
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 18:51 TPpostgres/
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x 13 ansadmin ansadmin 4096 Oct    7 18:49 roles/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$ cd roles/
ansadmin@svl200:~/TPansible/roles$ ll
total 56
drwxrwxr-x 13 ansadmin ansadmin 4096 Oct    7 18:49 ./
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    7 18:51 ../
-rw-rw-r--    1 ansadmin ansadmin 1328 Oct    6 15:04 README.md
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 defaults/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 files/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    6 15:10 group_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 handlers/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:10 hosts_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 meta/
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles1/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tasks/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 templates/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tests/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:15 vars/
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$ cd ..
ansadmin@svl200:~/TPansible$ ll
total 52
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    7 18:51 ./
drwxr-xr-x 13 ansadmin ansadmin 4096 Oct    7 18:49 ../
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 18:51 TPpostgres/
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x 13 ansadmin ansadmin 4096 Oct    7 18:49 roles/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$ cd roles/
ansadmin@svl200:~/TPansible/roles$ ll
total 56
drwxrwxr-x 13 ansadmin ansadmin 4096 Oct    7 18:49 ./
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    7 18:51 ../
-rw-rw-r--    1 ansadmin ansadmin 1328 Oct    6 15:04 README.md
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 defaults/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 files/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    6 15:10 group_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 handlers/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:10 hosts_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 meta/
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles1/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tasks/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 templates/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tests/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:15 vars/
ansadmin@svl200:~/TPansible/roles$ mv roles1/ ../
ansadmin@svl200:~/TPansible/roles$
ansadmin@svl200:~/TPansible/roles$ ll
total 52
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    7 18:53 ./
drwxrwxr-x    7 ansadmin ansadmin 4096 Oct    7 18:53 ../
-rw-rw-r--    1 ansadmin ansadmin 1328 Oct    6 15:04 README.md
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 defaults/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 files/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    6 15:10 group_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 handlers/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:10 hosts_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 meta/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tasks/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 templates/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tests/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:15 vars/
ansadmin@svl200:~/TPansible/roles$ cd ..
ansadmin@svl200:~/TPansible$ tree
.
├── TPpostgres
├── dump.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── main.yml
├── main_base.yml
├── main_houcem.yml
├── main_postgres.yml
├── psql.yml
├── roles
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── group_vars
│   │   └── all.yml
│   │            └── all.yml
│   ├── handlers
│   │   └── main.yml
│   ├── hosts_vars
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
├── roles1
│   ├── postgres
│   │   ├── handlers
│   │   │   └── main.yml
│   │   ├── tasks
│   │   │   └── main.yml
│   │   ├── templates
│   │   │   └── index.html.j2
│   │   └── vars
│   │            └── main.yml
│   └── users
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

26 directories, 26 files
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ cd
ansadmin@svl200:~$ ll
total 272
drwxr-xr-x 13 ansadmin ansadmin    4096 Oct    7 18:49 ./
drwxr-xr-x 11 root          root            4096 Oct    3 08:32 ../
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 14:52 .ansible/
-rw-------    1 ansadmin ansadmin 31795 Oct    7 13:03 .bash_history
-rw-r--r--    1 ansadmin ansadmin      220 Oct    3 08:32 .bash_logout
-rw-r--r--    1 ansadmin ansadmin    3771 Oct    3 08:32 .bashrc
-rw-r--r--    1 root          root          12288 Oct    4 08:51 .exo4.yaml.swp
-rw-------    1 root          root          12288 Oct    3 13:11 .handler.yaml.swp
-rw-r--r--    1 ansadmin ansadmin      807 Oct    3 08:32 .profile
drwx------    2 ansadmin ansadmin    4096 Oct    6 10:47 .ssh/
-rw-------    1 ansadmin ansadmin    8842 Oct    7 18:49 .viminfo
drwxr-xr-x    3 root          root            4096 Oct    6 09:27 TP3/
drwxrwxr-x    7 ansadmin ansadmin    4096 Oct    7 18:53 TPansible/
-rw-r--r--    1 root          root                  0 Oct    3 10:12 cible1.txt
-rw-r--r--    1 root          root              173 Oct    4 12:29 copie.yaml
-rw-r--r--    1 root          root              261 Oct    5 11:29 debug.yaml
-rw-r--r--    1 ansadmin ansadmin      277 Oct    3 17:57 debug1.yaml
-rw-r--r--    1 root          root              190 Oct    4 08:34 exo2.yaml
-rw-r--r--    1 root          root              175 Oct    4 08:44 exo3.yaml
-rw-r--r--    1 root          root              147 Oct    4 13:05 exo4.yaml
-rw-r--r--    1 root          root              247 Oct    3 14:37 fact.yaml
-rw-r--r--    1 ansadmin ansadmin      179 Oct    3 14:46 fact1.yaml
drwxrwxr-x    3 ansadmin ansadmin    4096 Oct    7 12:36 git/
-rw-r--r--    1 root          root              428 Oct    3 13:28 handler.yaml
-rw-------    1 ansadmin ansadmin      255 Oct    4 13:34 hello.yaml
-rw-------    1 ansadmin ansadmin      355 Oct    4 13:26 hello.yml
-rw-r--r--    1 root          root                24 Oct    3 13:38 index.html
-rw-r--r--    1 root          root              243 Oct    4 13:01 index.html.j2
-rw-r--r--    1 ansadmin ansadmin      135 Oct    4 13:01 index.html1.j2
-rw-r--r--    1 root          root                  0 Oct    3 14:40 ip.txt
-rw-r--r--    1 ansadmin ansadmin      247 Oct    4 10:35 item_users.yaml
-rw-r--r--    1 root          root              244 Oct    4 10:20 items.yaml
-rw-r--r--    1 root          root                  0 Oct    4 10:24 items_users.yaml
-rw-r--r--    1 root          root              235 Oct    4 10:08 list.yaml
-rw-r--r--    1 root          root              184 Oct    4 13:58 locale.yml
-rw-r--r--    1 root          root              224 Oct    3 12:31 nginx.yaml
-rw-r--r--    1 root          root              254 Oct    4 13:41 play-vars.yaml
-rw-------    1 ansadmin ansadmin      273 Oct    4 13:49 play-vars.yml
drwxrwxr-x    4 ansadmin ansadmin    4096 Oct    5 13:44 projet/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 13:14 projet1/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    6 07:29 projet2/
drwxrwxr-x 10 ansadmin ansadmin    4096 Oct    5 14:49 projet3/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 15:09 projet4/
-rw-r--r--    1 root          root              595 Oct    4 09:57 rep.yaml
-rw-r--r--    1 ansadmin ansadmin      209 Oct    4 12:04 seq.yaml
-rw-r--r--    1 root          root              199 Oct    3 13:01 shell.yml
drwx------    3 ansadmin ansadmin    4096 Oct    5 10:20 snap/
-rw-r--r--    1 root          root              228 Oct    4 13:14 template.yaml
-rw-r--r--    1 ansadmin ansadmin      254 Oct    4 13:21 template1.yaml
-rw-r--r--    1 root          root              268 Oct    4 14:35 var_dic.yml
-rw-r--r--    1 ansadmin ansadmin      280 Oct    4 15:12 var_dic2.yml
-rw-r--r--    1 root          root              337 Oct    5 14:04 var_dic_multi3.yml
-rw-r--r--    1 ansadmin ansadmin      146 Oct    4 15:07 vars.yml
-rw-r--r--    1 ansadmin ansadmin      149 Oct    5 10:26 vars2.yml
-rw-r--r--    1 root          root              237 Oct    5 08:08 vars_multi.yml
-rw-r--r--    1 root          root              304 Oct    3 17:58 when.yaml
-rw-r--r--    1 root          root              316 Oct    4 09:32 when1.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ cd TP
TP3/              TPansible/
ansadmin@svl200:~$ cd TP
TP3/              TPansible/
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ll
total 56
drwxrwxr-x    7 ansadmin ansadmin 4096 Oct    7 18:53 ./
drwxr-xr-x 13 ansadmin ansadmin 4096 Oct    7 18:49 ../
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 18:51 TPpostgres/
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    7 18:53 roles/
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles1/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$ mkdir ../tpansible
ansadmin@svl200:~/TPansible$ ll
total 56
drwxrwxr-x    7 ansadmin ansadmin 4096 Oct    7 18:53 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    7 18:57 ../
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 18:51 TPpostgres/
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    7 18:53 roles/
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles1/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$ mv roles/ ../tpansible/
ansadmin@svl200:~/TPansible$ ll
total 52
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    7 18:57 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    7 18:57 ../
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 18:51 TPpostgres/
-rw-rw-r--    1 ansadmin ansadmin    198 Oct    6 12:52 dump.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    130 Oct    6 12:18 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 09:40 hosts_vars/
-rw-rw-r--    1 ansadmin ansadmin 1037 Oct    6 12:07 main.yml
-rw-r--r--    1 root          root            105 Oct    6 12:10 main_base.yml
-rw-r--r--    1 root          root                0 Oct    6 12:43 main_houcem.yml
-rw-r--r--    1 root          root          1458 Oct    6 14:55 main_postgres.yml
-rw-rw-r--    1 ansadmin ansadmin 1426 Oct    6 13:03 psql.yml
drwxrwxr-x    4 ansadmin ansadmin 4096 Oct    7 18:44 roles1/
-rw-r--r--    1 ansadmin ansadmin      85 Oct    6 15:19 site.yml
ansadmin@svl200:~/TPansible$
ansadmin@svl200:~/TPansible$ cd
ansadmin@svl200:~$ ll
total 276
drwxr-xr-x 14 ansadmin ansadmin    4096 Oct    7 18:57 ./
drwxr-xr-x 11 root          root            4096 Oct    3 08:32 ../
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 14:52 .ansible/
-rw-------    1 ansadmin ansadmin 31795 Oct    7 13:03 .bash_history
-rw-r--r--    1 ansadmin ansadmin      220 Oct    3 08:32 .bash_logout
-rw-r--r--    1 ansadmin ansadmin    3771 Oct    3 08:32 .bashrc
-rw-r--r--    1 root          root          12288 Oct    4 08:51 .exo4.yaml.swp
-rw-------    1 root          root          12288 Oct    3 13:11 .handler.yaml.swp
-rw-r--r--    1 ansadmin ansadmin      807 Oct    3 08:32 .profile
drwx------    2 ansadmin ansadmin    4096 Oct    6 10:47 .ssh/
-rw-------    1 ansadmin ansadmin    8842 Oct    7 18:49 .viminfo
drwxr-xr-x    3 root          root            4096 Oct    6 09:27 TP3/
drwxrwxr-x    6 ansadmin ansadmin    4096 Oct    7 18:57 TPansible/
-rw-r--r--    1 root          root                  0 Oct    3 10:12 cible1.txt
-rw-r--r--    1 root          root              173 Oct    4 12:29 copie.yaml
-rw-r--r--    1 root          root              261 Oct    5 11:29 debug.yaml
-rw-r--r--    1 ansadmin ansadmin      277 Oct    3 17:57 debug1.yaml
-rw-r--r--    1 root          root              190 Oct    4 08:34 exo2.yaml
-rw-r--r--    1 root          root              175 Oct    4 08:44 exo3.yaml
-rw-r--r--    1 root          root              147 Oct    4 13:05 exo4.yaml
-rw-r--r--    1 root          root              247 Oct    3 14:37 fact.yaml
-rw-r--r--    1 ansadmin ansadmin      179 Oct    3 14:46 fact1.yaml
drwxrwxr-x    3 ansadmin ansadmin    4096 Oct    7 12:36 git/
-rw-r--r--    1 root          root              428 Oct    3 13:28 handler.yaml
-rw-------    1 ansadmin ansadmin      255 Oct    4 13:34 hello.yaml
-rw-------    1 ansadmin ansadmin      355 Oct    4 13:26 hello.yml
-rw-r--r--    1 root          root                24 Oct    3 13:38 index.html
-rw-r--r--    1 root          root              243 Oct    4 13:01 index.html.j2
-rw-r--r--    1 ansadmin ansadmin      135 Oct    4 13:01 index.html1.j2
-rw-r--r--    1 root          root                  0 Oct    3 14:40 ip.txt
-rw-r--r--    1 ansadmin ansadmin      247 Oct    4 10:35 item_users.yaml
-rw-r--r--    1 root          root              244 Oct    4 10:20 items.yaml
-rw-r--r--    1 root          root                  0 Oct    4 10:24 items_users.yaml
-rw-r--r--    1 root          root              235 Oct    4 10:08 list.yaml
-rw-r--r--    1 root          root              184 Oct    4 13:58 locale.yml
-rw-r--r--    1 root          root              224 Oct    3 12:31 nginx.yaml
-rw-r--r--    1 root          root              254 Oct    4 13:41 play-vars.yaml
-rw-------    1 ansadmin ansadmin      273 Oct    4 13:49 play-vars.yml
drwxrwxr-x    4 ansadmin ansadmin    4096 Oct    5 13:44 projet/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 13:14 projet1/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    6 07:29 projet2/
drwxrwxr-x 10 ansadmin ansadmin    4096 Oct    5 14:49 projet3/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 15:09 projet4/
-rw-r--r--    1 root          root              595 Oct    4 09:57 rep.yaml
-rw-r--r--    1 ansadmin ansadmin      209 Oct    4 12:04 seq.yaml
-rw-r--r--    1 root          root              199 Oct    3 13:01 shell.yml
drwx------    3 ansadmin ansadmin    4096 Oct    5 10:20 snap/
-rw-r--r--    1 root          root              228 Oct    4 13:14 template.yaml
-rw-r--r--    1 ansadmin ansadmin      254 Oct    4 13:21 template1.yaml
drwxrwxr-x    3 ansadmin ansadmin    4096 Oct    7 18:57 tpansible/
-rw-r--r--    1 root          root              268 Oct    4 14:35 var_dic.yml
-rw-r--r--    1 ansadmin ansadmin      280 Oct    4 15:12 var_dic2.yml
-rw-r--r--    1 root          root              337 Oct    5 14:04 var_dic_multi3.yml
-rw-r--r--    1 ansadmin ansadmin      146 Oct    4 15:07 vars.yml
-rw-r--r--    1 ansadmin ansadmin      149 Oct    5 10:26 vars2.yml
-rw-r--r--    1 root          root              237 Oct    5 08:08 vars_multi.yml
-rw-r--r--    1 root          root              304 Oct    3 17:58 when.yaml
-rw-r--r--    1 root          root              316 Oct    4 09:32 when1.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ll
total 12
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 18:57 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    7 18:57 ../
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    7 18:53 roles/
ansadmin@svl200:~/tpansible$ cd .
./    ../
ansadmin@svl200:~/tpansible$ cd ./
ansadmin@svl200:~/tpansible$ ll
total 12
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 18:57 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    7 18:57 ../
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    7 18:53 roles/
ansadmin@svl200:~/tpansible$ cd ../
ansadmin@svl200:~$ ll
total 276
drwxr-xr-x 14 ansadmin ansadmin    4096 Oct    7 18:57 ./
drwxr-xr-x 11 root          root            4096 Oct    3 08:32 ../
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 14:52 .ansible/
-rw-------    1 ansadmin ansadmin 31795 Oct    7 13:03 .bash_history
-rw-r--r--    1 ansadmin ansadmin      220 Oct    3 08:32 .bash_logout
-rw-r--r--    1 ansadmin ansadmin    3771 Oct    3 08:32 .bashrc
-rw-r--r--    1 root          root          12288 Oct    4 08:51 .exo4.yaml.swp
-rw-------    1 root          root          12288 Oct    3 13:11 .handler.yaml.swp
-rw-r--r--    1 ansadmin ansadmin      807 Oct    3 08:32 .profile
drwx------    2 ansadmin ansadmin    4096 Oct    6 10:47 .ssh/
-rw-------    1 ansadmin ansadmin    8842 Oct    7 18:49 .viminfo
drwxr-xr-x    3 root          root            4096 Oct    6 09:27 TP3/
drwxrwxr-x    6 ansadmin ansadmin    4096 Oct    7 18:57 TPansible/
-rw-r--r--    1 root          root                  0 Oct    3 10:12 cible1.txt
-rw-r--r--    1 root          root              173 Oct    4 12:29 copie.yaml
-rw-r--r--    1 root          root              261 Oct    5 11:29 debug.yaml
-rw-r--r--    1 ansadmin ansadmin      277 Oct    3 17:57 debug1.yaml
-rw-r--r--    1 root          root              190 Oct    4 08:34 exo2.yaml
-rw-r--r--    1 root          root              175 Oct    4 08:44 exo3.yaml
-rw-r--r--    1 root          root              147 Oct    4 13:05 exo4.yaml
-rw-r--r--    1 root          root              247 Oct    3 14:37 fact.yaml
-rw-r--r--    1 ansadmin ansadmin      179 Oct    3 14:46 fact1.yaml
drwxrwxr-x    3 ansadmin ansadmin    4096 Oct    7 12:36 git/
-rw-r--r--    1 root          root              428 Oct    3 13:28 handler.yaml
-rw-------    1 ansadmin ansadmin      255 Oct    4 13:34 hello.yaml
-rw-------    1 ansadmin ansadmin      355 Oct    4 13:26 hello.yml
-rw-r--r--    1 root          root                24 Oct    3 13:38 index.html
-rw-r--r--    1 root          root              243 Oct    4 13:01 index.html.j2
-rw-r--r--    1 ansadmin ansadmin      135 Oct    4 13:01 index.html1.j2
-rw-r--r--    1 root          root                  0 Oct    3 14:40 ip.txt
-rw-r--r--    1 ansadmin ansadmin      247 Oct    4 10:35 item_users.yaml
-rw-r--r--    1 root          root              244 Oct    4 10:20 items.yaml
-rw-r--r--    1 root          root                  0 Oct    4 10:24 items_users.yaml
-rw-r--r--    1 root          root              235 Oct    4 10:08 list.yaml
-rw-r--r--    1 root          root              184 Oct    4 13:58 locale.yml
-rw-r--r--    1 root          root              224 Oct    3 12:31 nginx.yaml
-rw-r--r--    1 root          root              254 Oct    4 13:41 play-vars.yaml
-rw-------    1 ansadmin ansadmin      273 Oct    4 13:49 play-vars.yml
drwxrwxr-x    4 ansadmin ansadmin    4096 Oct    5 13:44 projet/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 13:14 projet1/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    6 07:29 projet2/
drwxrwxr-x 10 ansadmin ansadmin    4096 Oct    5 14:49 projet3/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 15:09 projet4/
-rw-r--r--    1 root          root              595 Oct    4 09:57 rep.yaml
-rw-r--r--    1 ansadmin ansadmin      209 Oct    4 12:04 seq.yaml
-rw-r--r--    1 root          root              199 Oct    3 13:01 shell.yml
drwx------    3 ansadmin ansadmin    4096 Oct    5 10:20 snap/
-rw-r--r--    1 root          root              228 Oct    4 13:14 template.yaml
-rw-r--r--    1 ansadmin ansadmin      254 Oct    4 13:21 template1.yaml
drwxrwxr-x    3 ansadmin ansadmin    4096 Oct    7 18:57 tpansible/
-rw-r--r--    1 root          root              268 Oct    4 14:35 var_dic.yml
-rw-r--r--    1 ansadmin ansadmin      280 Oct    4 15:12 var_dic2.yml
-rw-r--r--    1 root          root              337 Oct    5 14:04 var_dic_multi3.yml
-rw-r--r--    1 ansadmin ansadmin      146 Oct    4 15:07 vars.yml
-rw-r--r--    1 ansadmin ansadmin      149 Oct    5 10:26 vars2.yml
-rw-r--r--    1 root          root              237 Oct    5 08:08 vars_multi.yml
-rw-r--r--    1 root          root              304 Oct    3 17:58 when.yaml
-rw-r--r--    1 root          root              316 Oct    4 09:32 when1.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ll
total 12
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 18:57 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    7 18:57 ../
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    7 18:53 roles/
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls -lrt
total 4
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    7 18:53 roles
ansadmin@svl200:~/tpansible$ cd roles/
ansadmin@svl200:~/tpansible/roles$ ls
README.md    defaults    files    group_vars    handlers    hosts_vars    meta   
tasks    templates    tests    vars
ansadmin@svl200:~/tpansible/roles$ cd ..
ansadmin@svl200:~/tpansible$ tree
.
└── roles
        ├── README.md
        ├── defaults
        │   └── main.yml
        ├── files
        ├── group_vars
        │   └── all.yml
        │            └── all.yml
        ├── handlers
        │   └── main.yml
        ├── hosts_vars
        ├── meta
        │   └── main.yml
        ├── tasks
        │   └── main.yml
        ├── templates
        ├── tests
        │   ├── inventory
        │   └── test.yml
        └── vars
                └── main.yml

12 directories, 9 files
ansadmin@svl200:~/tpansible$ mkdir roles/postgres
ansadmin@svl200:~/tpansible$ cd roles/
ansadmin@svl200:~/tpansible/roles$ ll
total 56
drwxrwxr-x 13 ansadmin ansadmin 4096 Oct    7 19:02 ./
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 18:57 ../
-rw-rw-r--    1 ansadmin ansadmin 1328 Oct    6 15:04 README.md
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 defaults/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 files/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    6 15:10 group_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 handlers/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:10 hosts_vars/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 meta/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:02 postgres/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tasks/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 templates/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:04 tests/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    6 15:15 vars/
ansadmin@svl200:~/tpansible/roles$ mv ./ ../ README.md defaults files/ group_vars/
handlers/ hosts_vars/ meta/ tasks/ templates/ tests/ vars/ postgres/
mv: cannot move './' to 'postgres/.': Device or resource busy
mv: cannot move '../' to 'postgres/..': Device or resource busy
ansadmin@svl200:~/tpansible/roles$ mv README.md defaults files/ group_vars/ handlers/
hosts_vars/ meta/ tasks/ templates/ tests/ vars/ postgres/
mv: cannot stat 'README.md': No such file or directory
mv: cannot stat 'defaults': No such file or directory
mv: cannot stat 'files/': No such file or directory
mv: cannot stat 'group_vars/': No such file or directory
mv: cannot stat 'handlers/': No such file or directory
mv: cannot stat 'hosts_vars/': No such file or directory
mv: cannot stat 'meta/': No such file or directory
mv: cannot stat 'tasks/': No such file or directory
mv: cannot stat 'templates/': No such file or directory
mv: cannot stat 'tests/': No such file or directory
mv: cannot stat 'vars/': No such file or directory
ansadmin@svl200:~/tpansible/roles$
ansadmin@svl200:~/tpansible/roles$ ls -lrt
total 4
drwxrwxr-x 12 ansadmin ansadmin 4096 Oct    7 19:04 postgres
ansadmin@svl200:~/tpansible/roles$
ansadmin@svl200:~/tpansible/roles$ ls
postgres
ansadmin@svl200:~/tpansible/roles$ cd ..
ansadmin@svl200:~/tpansible$ tree
.
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── group_vars
                │   └── all.yml
                │            └── all.yml
                ├── handlers
                │   └── main.yml
                ├── hosts_vars
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml
13 directories, 9 files
ansadmin@svl200:~/tpansible$ cd ..
ansadmin@svl200:~$ ls
TP3                  copie.yaml      exo2.yaml    fact.yaml      handler.yaml   
index.html            ip.txt                      items_users.yaml    nginx.yaml     
projet      projet3      seq.yaml      template.yaml      var_dic.yml               
vars.yml
TPansible      debug.yaml      exo3.yaml    fact1.yaml    hello.yaml       
index.html.j2      item_users.yaml    list.yaml                  play-vars.yaml   
projet1    projet4      shell.yml    template1.yaml    var_dic2.yml               
vars2.yml
cible1.txt    debug1.yaml    exo4.yaml    git                  hello.yml         
index.html1.j2    items.yaml              locale.yml                play-vars.yml   
projet2    rep.yaml    snap              tpansible              var_dic_multi3.yml   
vars_multi
ansadmin@svl200:~$ cd TPansible/
ansadmin@svl200:~/TPansible$ ls
TPpostgres    dump.yml    group_vars    hosts.yml    hosts_vars    main.yml   
main_base.yml    main_houcem.yml    main_postgres.yml    psql.yml    roles1   
site.yml
ansadmin@svl200:~/TPansible$ cd ..
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ls
geerlingguy.apache    group_vars    hosts.yml    hosts_vars    site.yml
ansadmin@svl200:~/projet4$ tree
.
├── geerlingguy.apache
│   ├── LICENSE
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── molecule
│   │   └── default
│   │            ├── converge.yml
│   │            └── molecule.yml
│   ├── site.yml
│   ├── tasks
│   │   ├── configure-Debian.yml
│   │   ├── configure-RedHat.yml
│   │   ├── configure-Solaris.yml
│   │   ├── configure-Suse.yml
│   │   ├── main.yml
│   │   ├── setup-Debian.yml
│   │   ├── setup-RedHat.yml
│   │   ├── setup-Solaris.yml
│   │   └── setup-Suse.yml
│   ├── templates
│   │   └── vhosts.conf.j2
│   └── vars
│            ├── AmazonLinux.yml
│            ├── Debian.yml
│            ├── RedHat.yml
│            ├── Solaris.yml
│            ├── Suse.yml
│            ├── apache-22.yml
│            └── apache-24.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
└── site.yml

11 directories, 28 files
ansadmin@svl200:~/projet4$ cd ..
ansadmin@svl200:~$ ls
TP3                  copie.yaml      exo2.yaml    fact.yaml      handler.yaml   
index.html            ip.txt                      items_users.yaml    nginx.yaml     
projet      projet3      seq.yaml      template.yaml      var_dic.yml               
vars.yml
TPansible      debug.yaml      exo3.yaml    fact1.yaml    hello.yaml       
index.html.j2      item_users.yaml    list.yaml                  play-vars.yaml   
projet1    projet4      shell.yml    template1.yaml    var_dic2.yml               
vars2.yml
cible1.txt    debug1.yaml    exo4.yaml    git                  hello.yml         
index.html1.j2    items.yaml              locale.yml                play-vars.yml   
projet2    rep.yaml    snap              tpansible              var_dic_multi3.yml   
vars_multi
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ls
geerlingguy.apache    group_vars    hosts.yml    hosts_vars    site.yml
ansadmin@svl200:~/projet4$ cp group_vars/ hosts_vars/ hosts.yml site.yml
../tpansible/
cp: -r not specified; omitting directory 'group_vars/'
cp: -r not specified; omitting directory 'hosts_vars/'
ansadmin@svl200:~/projet4$ cp -r group_vars hosts_vars hosts.yml site.yml
../tpansible/
ansadmin@svl200:~/projet4$ cd ..
ansadmin@svl200:~$ ls
TP3                  copie.yaml      exo2.yaml    fact.yaml      handler.yaml   
index.html            ip.txt                      items_users.yaml    nginx.yaml     
projet      projet3      seq.yaml      template.yaml      var_dic.yml               
vars.yml
TPansible      debug.yaml      exo3.yaml    fact1.yaml    hello.yaml       
index.html.j2      item_users.yaml    list.yaml                  play-vars.yaml   
projet1    projet4      shell.yml    template1.yaml    var_dic2.yml               
vars2.yml
cible1.txt    debug1.yaml    exo4.yaml    git                  hello.yml         
index.html1.j2    items.yaml              locale.yml                play-vars.yml   
projet2    rep.yaml    snap              tpansible              var_dic_multi3.yml   
vars_multi
ansadmin@svl200:~$
ansadmin@svl200:~$ ls
TP3                  copie.yaml      exo2.yaml    fact.yaml      handler.yaml   
index.html            ip.txt                      items_users.yaml    nginx.yaml     
projet      projet3      seq.yaml      template.yaml      var_dic.yml               
vars.yml
TPansible      debug.yaml      exo3.yaml    fact1.yaml    hello.yaml       
index.html.j2      item_users.yaml    list.yaml                  play-vars.yaml   
projet1    projet4      shell.yml    template1.yaml    var_dic2.yml               
vars2.yml
cible1.txt    debug1.yaml    exo4.yaml    git                  hello.yml         
index.html1.j2    items.yaml              locale.yml                play-vars.yml   
projet2    rep.yaml    snap              tpansible              var_dic_multi3.yml   
vars_multi
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── group_vars
│            │   └── all.yml
│            │            └── all.yml
│            ├── handlers
│            │   └── main.yml
│            ├── hosts_vars
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── site.yml

15 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo vim group_vars/all.yml
ansadmin@svl200:~/tpansible$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible$ cd hosts_vars/
ansadmin@svl200:~/tpansible/hosts_vars$ ls
ansadmin@svl200:~/tpansible/hosts_vars$ cd ..
ansadmin@svl200:~/tpansible$ cd ..
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ tree
.
├── geerlingguy.apache
│   ├── LICENSE
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── molecule
│   │   └── default
│   │            ├── converge.yml
│   │            └── molecule.yml
│   ├── site.yml
│   ├── tasks
│   │   ├── configure-Debian.yml
│   │   ├── configure-RedHat.yml
│   │   ├── configure-Solaris.yml
│   │   ├── configure-Suse.yml
│   │   ├── main.yml
│   │   ├── setup-Debian.yml
│   │   ├── setup-RedHat.yml
│   │   ├── setup-Solaris.yml
│   │   └── setup-Suse.yml
│   ├── templates
│   │   └── vhosts.conf.j2
│   └── vars
│            ├── AmazonLinux.yml
│            ├── Debian.yml
│            ├── RedHat.yml
│            ├── Solaris.yml
│            ├── Suse.yml
│            ├── apache-22.yml
│            └── apache-24.yml
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
└── site.yml

11 directories, 28 files
ansadmin@svl200:~/projet4$ cd
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── group_vars
│            │   └── all.yml
│            │            └── all.yml
│            ├── handlers
│            │   └── main.yml
│            ├── hosts_vars
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── site.yml

15 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/group_vars/all.yml/all.yml
ansadmin@svl200:~/tpansible$ rm roles/postgres/group_vars/
rm: cannot remove 'roles/postgres/group_vars/': Is a directory
ansadmin@svl200:~/tpansible$ rm -r roles/postgres/group_vars/
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── handlers
│            │   └── main.yml
│            ├── hosts_vars
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── site.yml

13 directories, 11 files
ansadmin@svl200:~/tpansible$ rm -r roles/postgres/hosts_vars/
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── handlers
│            │   └── main.yml
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── site.yml

12 directories, 11 files
ansadmin@svl200:~/tpansible$ cd roles/postgres/te
templates/ tests/
ansadmin@svl200:~/tpansible$ cd roles/postgres/te
templates/ tests/
ansadmin@svl200:~/tpansible$ cd roles/postgres/te
templates/ tests/
ansadmin@svl200:~/tpansible$ cd roles/postgres/templates/
ansadmin@svl200:~/tpansible$ cd roles/postgres/templates/
ansadmin@svl200:~/tpansible/roles/postgres/templates$ ls
ansadmin@svl200:~/tpansible/roles/postgres/templates$ cd
ansadmin@svl200:~$
ansadmin@svl200:~$ ls
TP3                  debug.yaml      exo4.yaml      handler.yaml    index.html.j2   
items.yaml                nginx.yaml            projet1    rep.yaml     
template.yaml      var_dic2.yml                vars_multi.yml
TPansible      debug1.yaml    fact.yaml      hello.yaml        index.html1.j2     
items_users.yaml    play-vars.yaml    projet2    seq.yaml      template1.yaml   
var_dic_multi3.yml    when.yaml
cible1.txt    exo2.yaml        fact1.yaml    hello.yml          ip.txt               
list.yaml                  play-vars.yml      projet3    shell.yml    tpansible     
vars.yml                        when1.yaml
copie.yaml    exo3.yaml        git                  index.html        item_users.yaml
locale.yml                projet                    projet4    snap             
var_dic.yml          vars2.yml
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ls
geerlingguy.apache    group_vars    hosts.yml    hosts_vars    site.yml
ansadmin@svl200:~/projet4$ cd geerlingguy.apache/
.github/      defaults/    handlers/    meta/            molecule/    tasks/         
templates/ vars/
ansadmin@svl200:~/projet4$ cd ../projet1
ansadmin@svl200:~/projet1$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/projet1$ cd roles/apache/
handlers/    tasks/          templates/ vars/
ansadmin@svl200:~/projet1$ cp roles/apache/templates/index.html.j2 ../tpansible/
group_vars/ hosts.yml      hosts_vars/ roles/            site.yml
ansadmin@svl200:~/projet1$ cp roles/apache/templates/index.html.j2
../tpansible/roles/postgres/
README.md    defaults/    files/          handlers/    meta/            tasks/       
templates/ tests/          vars/
ansadmin@svl200:~/projet1$ cp roles/apache/templates/index.html.j2
../tpansible/roles/postgres/t
tasks/          templates/ tests/
ansadmin@svl200:~/projet1$ cp roles/apache/templates/index.html.j2
../tpansible/roles/postgres/te
templates/ tests/
ansadmin@svl200:~/projet1$ cp roles/apache/templates/index.html.j2
../tpansible/roles/postgres/te
templates/ tests/
ansadmin@svl200:~/projet1$ cp roles/apache/templates/index.html.j2
../tpansible/roles/postgres/templates/
ansadmin@svl200:~/projet1$
ansadmin@svl200:~/projet1$ cd ../tpansible/
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── handlers
│            │   └── main.yml
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── site.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ su vim hosts.yml
su: user vim does not exist
ansadmin@svl200:~/tpansible$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── handlers
│            │   └── main.yml
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── site.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ cd ../projet1
ansadmin@svl200:~/projet1$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/projet1$ cd hosts_vars/
ansadmin@svl200:~/projet1/hosts_vars$ ls
ansadmin@svl200:~/projet1/hosts_vars$ cd ../../tpansible/
ansadmin@svl200:~/tpansible$ tree
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── handlers
│            │   └── main.yml
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── site.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/handlers/main.yml
ansadmin@svl200:~/tpansible$ cd ../projet1
ansadmin@svl200:~/projet1$ tree
ansadmin@svl200:~/projet1$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet1$ sudo vim roles/apache/handlers/main.yml
ansadmin@svl200:~/projet1$ sudo vim roles/apache/t
tasks/          templates/
ansadmin@svl200:~/projet1$ sudo vim roles/apache/t
tasks/          templates/
ansadmin@svl200:~/projet1$ sudo vim roles/apache/tasks/main.yml
ansadmin@svl200:~/projet1$ sudo vim ../tpansible/roles/postgres/tasks/main.yml
ansadmin@svl200:~/projet1$ sudo vim ../tpansible/roles/postgres/handlers/main.yml
ansadmin@svl200:~/projet1$ cd
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ sudo vim site.yml
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/templates/index.html.j2
ansadmin@svl200:~/tpansible$ ansible-playbook
group_vars/ hosts.yml      hosts_vars/ roles/            site.yml
ansadmin@svl200:~/tpansible$ ansible-playbook hosts
hosts.yml      hosts_vars/
ansadmin@svl200:~/tpansible$ ansible-playbook hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/tpansible/hosts.yml, line
3, column 7, found a duplicate dict key (cible1). Using last defined value only.
ERROR! A playbook must be a list of plays, got a <class
'ansible.parsing.yaml.objects.AnsibleMapping'> instead

The error appears to be in '/home/ansadmin/tpansible/hosts.yml': line 1, column 1,


but may
be elsewhere in the file depending on the exact syntax problem.
The offending line appears to be:

all:
^ here
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ansible-playbook
group_vars/ hosts.yml      hosts_vars/ roles/            site.yml
ansadmin@svl200:~/tpansible$ ansible-playbook roles/postgres/t
tasks/          templates/ tests/
ansadmin@svl200:~/tpansible$ ansible-playbook roles/postgres/tasks/main.yml

PLAY [install postgresql and BD]


*************************************************************************************
*******************************************************************

TASK [Gathering Facts]


*************************************************************************************
*****************************************************************************
ok: [146.59.158.16]

TASK [installation postgresql-contrib]


*************************************************************************************
*************************************************************
ok: [146.59.158.16]

TASK [package_python]
*************************************************************************************
******************************************************************************
ok: [146.59.158.16]

TASK [acl]
*************************************************************************************
*************************************************************************************
****
ok: [146.59.158.16]

TASK [installation postgresql]


*************************************************************************************
*********************************************************************
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]

TASK [BD]
*************************************************************************************
*************************************************************************************
*****
ok: [146.59.158.16]

TASK [start servicde]


*************************************************************************************
******************************************************************************
changed: [146.59.158.16]

TASK [Add some dummy data to our database]


*************************************************************************************
*********************************************************
changed: [146.59.158.16]

TASK [sauvegarde]
*************************************************************************************
**********************************************************************************
changed: [146.59.158.16]

TASK [BD]
*************************************************************************************
*************************************************************************************
*****
ok: [146.59.158.16]

TASK [Import BD]


*************************************************************************************
***********************************************************************************
changed: [146.59.158.16]

TASK [Add some dummy data to our database dbapx]


*************************************************************************************
***************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
****
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ cd
ansadmin@svl200:~$ cd projet4
ansadmin@svl200:~/projet4$ ls
geerlingguy.apache    group_vars    hosts.yml    hosts_vars    site.yml
ansadmin@svl200:~/projet4$ ansible-playbook hosts.yml site.yml
[WARNING]: While constructing a mapping from /home/ansadmin/projet4/hosts.yml, line
3, column 7, found a duplicate dict key (cible1). Using last defined value only.
ERROR! A playbook must be a list of plays, got a <class
'ansible.parsing.yaml.objects.AnsibleMapping'> instead

The error appears to be in '/home/ansadmin/projet4/hosts.yml': line 1, column 1, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

all:
^ here
ansadmin@svl200:~/projet4$ ansible-playbook hosts_vars site.yml
ERROR! the playbook: hosts_vars does not appear to be a file
ansadmin@svl200:~/projet4$ ansible-playbook site.yml

PLAY [install apache]


*************************************************************************************
******************************************************************************

TASK [Gathering Facts]


*************************************************************************************
*****************************************************************************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: [email protected]: Permission denied
(publickey,password).", "unreachabl                                        e": true}
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [geerlingguy.apache : Include OS-specific variables.]


*************************************************************************************
*****************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [geerlingguy.apache : Include variables for Amazon Linux.]


*************************************************************************************
************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [geerlingguy.apache : Define apache_packages.]


*************************************************************************************
************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [geerlingguy.apache : include_tasks]


*************************************************************************************
**********************************************************
included: /home/ansadmin/.ansible/roles/geerlingguy.apache/tasks/setup-Debian.yml for
146.59.158.16, 141.95.160.133

TASK [geerlingguy.apache : Update apt cache.]


*************************************************************************************
******************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

TASK [geerlingguy.apache : Ensure Apache is installed on Debian.]


*************************************************************************************
**********************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [geerlingguy.apache : Get installed version of Apache.]


*************************************************************************************
***************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [geerlingguy.apache : Create apache_version variable.]


*************************************************************************************
****************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [geerlingguy.apache : Include Apache 2.2 variables.]


*************************************************************************************
******************************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [geerlingguy.apache : Include Apache 2.4 variables.]


*************************************************************************************
******************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [geerlingguy.apache : Configure Apache.]


*************************************************************************************
******************************************************
included: /home/ansadmin/.ansible/roles/geerlingguy.apache/tasks/configure-Debian.yml
for 146.59.158.16, 141.95.160.133

TASK [geerlingguy.apache : Configure Apache.]


*************************************************************************************
******************************************************
ok: [146.59.158.16] => (item={'regexp': '^Listen ', 'line': 'Listen 80'})
ok: [141.95.160.133] => (item={'regexp': '^Listen ', 'line': 'Listen 80'})

TASK [geerlingguy.apache : Enable Apache mods.]


*************************************************************************************
****************************************************
changed: [146.59.158.16] => (item=rewrite)
ok: [141.95.160.133] => (item=rewrite)
changed: [146.59.158.16] => (item=ssl)
ok: [141.95.160.133] => (item=ssl)

TASK [geerlingguy.apache : Disable Apache mods.]


*************************************************************************************
***************************************************

TASK [geerlingguy.apache : Check whether certificates defined in vhosts exist.]


*************************************************************************************
********************

TASK [geerlingguy.apache : Add apache vhosts configuration.]


*************************************************************************************
***************************************
ok: [141.95.160.133]
changed: [146.59.158.16]

TASK [geerlingguy.apache : Add vhost symlink in sites-enabled.]


*************************************************************************************
************************************
changed: [146.59.158.16]
ok: [141.95.160.133]

TASK [geerlingguy.apache : Remove default vhost in sites-enabled.]


*************************************************************************************
*********************************
skipping: [146.59.158.16]
skipping: [141.95.160.133]

TASK [geerlingguy.apache : Ensure Apache has selected state and enabled on boot.]
*************************************************************************************
******************
ok: [141.95.160.133]
changed: [146.59.158.16]

RUNNING HANDLER [geerlingguy.apache : restart apache]


*************************************************************************************
**********************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
****
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=0
141.95.160.133                          : ok=15    changed=1      unreachable=0   
failed=0        skipped=5      rescued=0        ignored=0
146.59.158.16                            : ok=16    changed=6      unreachable=0   
failed=0        skipped=5      rescued=0        ignored=0

ansadmin@svl200:~/projet4$ sudo vim site.yml


ansadmin@svl200:~/projet4$ cd
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ansible-playbook site.yml
ERROR! conflicting action statements: hosts, gather_facts

The error appears to be in '/home/ansadmin/tpansible/roles/postgres/tasks/main.yml':


line 1, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: install postgresql and BD


    ^ here
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── handlers
│            │   └── main.yml
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── site.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo vim site.yml
ansadmin@svl200:~/tpansible$ sudo roles/postgres/tasks/main.yml
sudo: roles/postgres/tasks/main.yml: command not found
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/tasks/main.yml
ansadmin@svl200:~/tpansible$ mv site.yml psql.yml
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml
ERROR! conflicting action statements: hosts, gather_facts

The error appears to be in '/home/ansadmin/tpansible/roles/postgres/tasks/main.yml':


line 1, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

- name: install postgresql and BD


    ^ here
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/tasks/main.yml
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml
ERROR! The tasks/main.yml file for role 'postgres' must contain a list of tasks

The error appears to be in '/home/ansadmin/tpansible/roles/postgres/tasks/main.yml':


line 7, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    tasks:
    ^ here
ansadmin@svl200:~/tpansible$ cd
ansadmin@svl200:~$ cd projet1
ansadmin@svl200:~/projet1$ ls
group_vars    hosts.yml    hosts_vars    roles    site.yml
ansadmin@svl200:~/projet1$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── roles
│   └── apache
│            ├── handlers
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            └── vars
│                    └── main.yml
└── site.yml

8 directories, 7 files
ansadmin@svl200:~/projet1$ sudo vim roles/apache/tasks/main.yml
ansadmin@svl200:~/projet1$ cd
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ tree
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/tasks/main.yml
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
****************************************************************************

TASK [Gathering Facts]


*************************************************************************************
*****************************************************************************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: [email protected]: Permission denied
(publickey,password).", "unreachabl                                        e": true}
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql-contrib]


*************************************************************************************
**************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : package_python]


*************************************************************************************
*******************************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : acl]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : installation postgresql]


*************************************************************************************
**********************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*******************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : BD]


*************************************************************************************
*******************************************************************************
ok: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*******************************************************************
changed: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : Add some dummy data to our database]


*************************************************************************************
**********************************************
fatal: [141.95.160.133]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/home/ansadmin/dump.sql", "delta": "0:00:00.003623", "end": "2022-10-07
20:03:50.253304", "msg": "non-zero ret                                        urn
code", "rc": 2, "start": "2022-10-07 20:03:50.249681", "stderr": "/bin/sh: 1: cannot
open /home/ansadmin/dump.sql: No such file", "stderr_lines": ["/bin/sh: 1: cannot
open /home/ans                                        admin/dump.sql: No such file"],
"stdout": "", "stdout_lines": []}
changed: [146.59.158.16]

TASK [postgres : sauvegarde]


*************************************************************************************
***********************************************************************
changed: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*******************************************************************************
ok: [146.59.158.16]
TASK [postgres : Import BD]
*************************************************************************************
************************************************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
****************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
****
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=0
141.95.160.133                          : ok=8      changed=6      unreachable=0   
failed=1      skipped=0        rescued=0        ignored=0
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
*************************************************************************************
***********

TASK [Gathering Facts]


*************************************************************************************
*************************************************************************************
************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: [email protected]: Permission denied
(publickey,password).", "unreachable": true}
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql-contrib]


*************************************************************************************
**********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : package_python]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : acl]


*************************************************************************************
*************************************************************************************
*************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
changed: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : Add some dummy data to our database]


*************************************************************************************
******************************************************************
fatal: [141.95.160.133]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/home/ansadmin/dump.sql", "delta": "0:00:00.004202", "end": "2022-10-07
20:35:27.477285", "msg": "non-zero return code", "rc": 2, 1: cannot open
/home/ansadmin/dump.sql: No such file", "stderr_lines": ["/bin/sh: 1: cannot open
/home/ansadmin/dump.sql: No such file"], "stdout": "", "stdout_lines": []}
changed: [146.59.158.16]

TASK [postgres : sauvegarde]


*************************************************************************************
*************************************************************************************
******
changed: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]

TASK [postgres : Import BD]


*************************************************************************************
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=0
141.95.160.133                          : ok=8      changed=1      unreachable=0   
failed=1      skipped=0        rescued=0        ignored=0
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/tasks/main.yml
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
*************************************************************************************
***********

TASK [Gathering Facts]


*************************************************************************************
*************************************************************************************
************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: [email protected]: Permission denied
(publickey,password).", "unreachable": true}
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql-contrib]


*************************************************************************************
**********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : package_python]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [postgres : acl]
*************************************************************************************
*************************************************************************************
*************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
changed: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : Add some dummy data to our database]


*************************************************************************************
******************************************************************
fatal: [141.95.160.133]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/home/ansadmin/dump.sql", "delta": "0:00:00.003157", "end": "2022-10-07
20:37:08.576697", "msg": "non-zero return code", "rc": 2, 1: cannot open
/home/ansadmin/dump.sql: No such file", "stderr_lines": ["/bin/sh: 1: cannot open
/home/ansadmin/dump.sql: No such file"], "stdout": "", "stdout_lines": []}
changed: [146.59.158.16]

TASK [postgres : sauvegarde]


*************************************************************************************
*************************************************************************************
******
changed: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]
TASK [postgres : Import BD]
*************************************************************************************
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=0
141.95.160.133                          : ok=8      changed=1      unreachable=0   
failed=1      skipped=0        rescued=0        ignored=0
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$ sudo vim hosts.yml


ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
*************************************************************************************
***********

TASK [Gathering Facts]


*************************************************************************************
*************************************************************************************
************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: [email protected]: Permission denied
(publickey,password).", "unreachable": true}
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql-contrib]


*************************************************************************************
**********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : package_python]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [postgres : acl]
*************************************************************************************
*************************************************************************************
*************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
changed: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : Add some dummy data to our database]


*************************************************************************************
******************************************************************
fatal: [141.95.160.133]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/home/ansadmin/dump.sql", "delta": "0:00:00.003360", "end": "2022-10-07
20:38:56.051714", "msg": "non-zero return code", "rc": 2, 1: cannot open
/home/ansadmin/dump.sql: No such file", "stderr_lines": ["/bin/sh: 1: cannot open
/home/ansadmin/dump.sql: No such file"], "stdout": "", "stdout_lines": []}
changed: [146.59.158.16]

TASK [postgres : sauvegarde]


*************************************************************************************
*************************************************************************************
******
changed: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]
TASK [postgres : Import BD]
*************************************************************************************
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=0
141.95.160.133                          : ok=8      changed=1      unreachable=0   
failed=1      skipped=0        rescued=0        ignored=0
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/vars/main.yml
ansadmin@svl200:~/tpansible$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml
PLAY [install postgres]
*************************************************************************************
*************************************************************************************
***********

TASK [Gathering Facts]


*************************************************************************************
*************************************************************************************
************
fatal: [141.95.160.128]: UNREACHABLE! => {"changed": false, "msg": "Failed to connect
to the host via ssh: [email protected]: Permission denied
(publickey,password).", "unreachable": true}
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql-contrib]


*************************************************************************************
**********************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : package_python]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : acl]


*************************************************************************************
*************************************************************************************
*************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : installation postgresql]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]
ok: [141.95.160.133]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]
ok: [141.95.160.133]
TASK [postgres : start servicde]
*************************************************************************************
*************************************************************************************
**
changed: [146.59.158.16]
changed: [141.95.160.133]

TASK [postgres : Add some dummy data to our database]


*************************************************************************************
******************************************************************
changed: [146.59.158.16]
fatal: [141.95.160.133]: FAILED! => {"changed": true, "cmd": "psql dbofi <
/home/ansadmin/dump.sql", "delta": "0:00:00.004010", "end": "2022-10-07
20:42:03.525380", "msg": "non-zero return code", "rc": 2, 1: cannot open
/home/ansadmin/dump.sql: No such file", "stderr_lines": ["/bin/sh: 1: cannot open
/home/ansadmin/dump.sql: No such file"], "stdout": "", "stdout_lines": []}

TASK [postgres : sauvegarde]


*************************************************************************************
*************************************************************************************
******
changed: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]

TASK [postgres : Import BD]


*************************************************************************************
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
************************
141.95.160.128                          : ok=0        changed=0        unreachable=1 
failed=0        skipped=0        rescued=0        ignored=0
141.95.160.133                          : ok=8      changed=1      unreachable=0   
failed=1      skipped=0        rescued=0        ignored=0
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$ sudo vim hosts.yml


ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ sudo gro
groff              grog                grops              grotty           
group_vars/ groupadd        groupdel        groupmems      groupmod        groups   
growpart
ansadmin@svl200:~/tpansible$ sudo vim group_vars/all.yml
ansadmin@svl200:~/tpansible$ sudo vim psql.yml
ansadmin@svl200:~/tpansible$ sudo vim group_vars/all.yml
ansadmin@svl200:~/tpansible$ sudo vim group_vars/all.yml
ansadmin@svl200:~/tpansible$ sudo host
Usage: host [-aCdilrTvVw] [-c class] [-N ndots] [-t type] [-W time]
                        [-R number] [-m flag] hostname [server]
              -a is equivalent to -v -t ANY
              -A is like -a but omits RRSIG, NSEC, NSEC3
              -c specifies query class for non-IN data
              -C compares SOA records on authoritative nameservers
              -d is equivalent to -v
              -l lists all hosts in a domain, using AXFR
              -m set memory debugging flag (trace|record|usage)
              -N changes the number of dots allowed before root lookup is done
              -r disables recursive processing
              -R specifies number of retries for UDP packets
              -s a SERVFAIL response should stop query
              -t specifies the query type
              -T enables TCP/IP mode
              -U enables UDP mode
              -v enables verbose output
              -V print version number and exit
              -w specifies to wait forever for a reply
              -W specifies how long to wait for a reply
              -4 use IPv4 query transport only
              -6 use IPv6 query transport only
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ sudo vim
vim                vim.basic    vim.tiny      vimdiff        vimtutor
ansadmin@svl200:~/tpansible$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible$ sudo vim psql.yml
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
*************************************************************************************
***********

TASK [Gathering Facts]


*************************************************************************************
*************************************************************************************
************
ok: [146.59.158.16]

TASK [postgres : installation postgresql-contrib]


*************************************************************************************
**********************************************************************
ok: [146.59.158.16]

TASK [postgres : package_python]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]

TASK [postgres : acl]


*************************************************************************************
*************************************************************************************
*************
ok: [146.59.158.16]

TASK [postgres : installation postgresql]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]

TASK [postgres : start servicde]


*************************************************************************************
*************************************************************************************
**
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database]


*************************************************************************************
******************************************************************
changed: [146.59.158.16]

TASK [postgres : sauvegarde]


*************************************************************************************
*************************************************************************************
******
changed: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]

TASK [postgres : Import BD]


*************************************************************************************
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
************************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/tasks/main.yml
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
*************************************************************************************
***********

TASK [Gathering Facts]


*************************************************************************************
*************************************************************************************
************
ok: [146.59.158.16]
TASK [postgres : Installation postgresql-contrib]
*************************************************************************************
**********************************************************************
ok: [146.59.158.16]

TASK [postgres : Package_python]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]

TASK [postgres : acl]


*************************************************************************************
*************************************************************************************
*************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


*************************************************************************************
*************************************************************************************
**
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbofi]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

TASK [postgres : Sauvegarde]


*************************************************************************************
*************************************************************************************
******
changed: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
*************************************************************************************
**************
ok: [146.59.158.16]

TASK [postgres : Import BD]


*************************************************************************************
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
************************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible                                                         
ansadmin@svl200:~/tpansible                                                         
ansadmin@svl200:~/tpansib                                                           
ansadmin@svl200:~/tpansib                                                           
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tpa                                                               
ansadmin@svl200:~/tp                                                                 
ansadmin@svl200:~/tp                                                                 
ansadmin@svl200:~/t                                                                 
ansadmin@svl200:~                                                                   
ansadmin@svl200:~                                                                   
ansadmin@svl200:                                                                     
ansadmin@svl200                                                                     
ansadmin@svl20                                                                       
0:~/tpansible$                                                                       
ansadmin@svl                                                                         
200:~/tpansi                                                                         
ansadmin@svl                                                                         
200:~/tpansi                                                                         
ansadmin@svl                                                                         
200:~/tpansi                                                                         
ansadmin@sv                                                                         
l200:~/tpan                                                                         
ansadmin@s                                                                           
vl200:~/tp                                                                           
ansadmin@                                                                           
svl200:~/                                                                           
tpansible                                                                           
ansadmin                                                                             
@svl200:                                                                             
~/tpansi                                                                             
ansadmin                                                                             
@svl200:                                                                             
~/tpansi                                                                             
ansadmi                                                                             
n@svl20                                                                             
0:~/tpa                                                                             
nsible$                                                                             
ansadmin                                                                             
@svl200:                                                                             
~/tpansi                                                                             
ansadmin                                                                             
@svl200:                                                                             
~/tpansi                                                                             
ansadmin@                                                                           
svl200:~/                                                                           
tpansible                                                                           
ansadmin@s                                                                           
vl200:~/tp                                                                           
ansadmin@sv                                                                         
l200:~/tpan                                                                         
ansadmin@svl2                                                                       
00:~/tpansibl                                                                       
ansadmin@svl2                                                                       
00:~/tpansibl                                                                       
ansadmin@svl2                                                                       
00:~/tpansibl                                                                       
ansadmin@svl20                                                                       
0:~/tpansible$                                                                       
ansadmin@svl200                                                                     
ansadmin@svl200:                                                                     
ansadmin@svl200:~                                                                   
ansadmin@svl200:~/t                                                                 
ansadmin@svl200:~/t                                                                 
ansadmin@svl200:~/tpa                                                               
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tpansi                                                             
ansadmin@svl200:~/tpansi                                                             
ansadmin@svl200:~/tpansib                                                           
ansadmin@svl200:~/tpansibl                                                           
ansadmin@svl200:~/tpansible$                                                         
ansadmin@svl200:~/tpansible                                                         
ansadmin@svl200:~/tpansible                                                         
ansadmin@svl200:~/tpansible                                                         
ansadmin@svl200:~/tpansible                                                         
ansadmin@svl200:~/tpansible                                                         
ansadmin@svl200:~/tpansible$                                                         
ansadmin@svl200:~/tpansible                                                         
ansadmin@svl200:~/tpansibl                                                           
ansadmin@svl200:~/tpansib                                                           
ansadmin@svl200:~/tpans                                                             
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tp                                                                 
ansadmin@svl200:~/tp                                                                 
ansadmin@svl200:~/tp                                                                 
ansadmin@svl200:~/                                                                   
ansadmin@svl200:~/                                                                   
ansadmin@svl200:                                                                     
ansadmin@svl200                                                                     
ansadmin@svl200                                                                     
ansadmin@svl200:                                                                     
ansadmin@svl200:~/                                                                   
ansadmin@svl200:~/                                                                   
ansadmin@svl200:~/tp                                                                 
ansadmin@svl200:~/tp                                                                 
ansadmin@svl200:~/tpan                                                               
ansadmin@svl200:~/tpansi                                                             
ansadmin@svl200:~/tpansi                                                             
ansadmin@svl200:~/tpansi                                                             
ansadmin@svl200:~/tpansi                                                             
ansadmin@svl200:~/tpansib                                                           
ansadmin@svl200:~/tpansibl                                                           
ansadmin@svl200:~/tpansible$                                                         
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
─────────────────────────────────────────────────────────────────────────────────────
───────────────────────────────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file
[email protected]'s password:
        ┌──────────────────────────────────────────────────────────────────────┐
        │                                  • MobaXterm Personal Edition v22.0 •     

        │                              (SSH client, X server and network tools)     

        │                                                                           

        │ → SSH session to [email protected]                                     

        │      • Direct SSH            :    v                                       

        │      • SSH compression :    v                                             

        │      • SSH-browser          :    v                                         

        │      • X11-forwarding    :    v    (remote display is forwarded through
SSH)    │
        │                                                                           

        │ → For more info, ctrl+click on help or visit our website.                 

        └──────────────────────────────────────────────────────────────────────┘

Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.4.0-122-generic x86_64)

* Documentation:    https://help.ubuntu.com
* Management:          https://landscape.canonical.com
* Support:                https://ubuntu.com/advantage

System information disabled due to load higher than 1.0

* Super-optimized for small spaces - read how we shrank the memory


      footprint of MicroK8s to make it the smallest full K8s around.

      https://ubuntu.com/blog/microk8s-memory-optimisation

12 updates can be applied immediately.


To see these additional updates run: apt list --upgradable

*** System restart required ***


Last login: Fri Oct    7 18:21:07 2022 from 80.119.120.22
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$ cd
.ansible/    .ssh/            TP3/              TPansible/ git/              projet/ 
projet1/      projet2/      projet3/      projet4/      snap/            tpansible/
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
*********************************************

TASK [Gathering Facts]


*************************************************************************************
**********************************************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql-contrib]


*************************************************************************************
*******************
ok: [146.59.158.16]

TASK [postgres : Package_python]


*************************************************************************************
************************************
ok: [146.59.158.16]

TASK [postgres : acl]


*************************************************************************************
***********************************************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql]


*************************************************************************************
***************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


*************************************************************************************
************************************
ok: [146.59.158.16]

TASK [postgres : BD]


*************************************************************************************
************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


*************************************************************************************
************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbofi]


*************************************************************************************
*********
changed: [146.59.158.16]

TASK [postgres : Sauvegarde]


*************************************************************************************
****************************************
changed: [146.59.158.16]
TASK [postgres : BD]
*************************************************************************************
************************************************
ok: [146.59.158.16]

TASK [postgres : Import BD]


*************************************************************************************
*****************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
*********
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
**********************************************************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/tasks/main.yml


ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 12 files
ansadmin@svl200:~/tpansible$ cd
ansadmin@svl200:~$ exit
logout
ofi03@svl200:~$
ofi03@svl200:~$ history
        1    clear
        2    usermod -aG sudo etl3
        3    su - etl
        4    clear
        5    sudo su -
        6    ls -lrt
        7    chmod u=rw,g=rw,o=r system.log
        8    ls -lrt
        9    clear
      10    ls -lrt
      11    chmod 777 system.log
      12    ls -lrt
      13    chmod u=rw,g=rw,o=r system.log
      14    clear
      15    ls -lrt
      16    chmod a+rw system.log
      17    ls -lrt
      18    clear
      19    chmod 755 -R system.log
      20    ls -lrt
      21    cd
      22    cd profile/
      23    cd
      24    sudo touch test.log
      25    ls -lrt
      26    clear
      27    sudo systemctl start cron.service
      28    sudo systemctl is-active cron.service
      29    sudo systemctl stop cron.service
      30    sudo systemctl is-active cron.service
      31    sudo systemctl restart cron.service
      32    sudo systemctl is-active cron.service
      33    sudo systemctl -t help
      34    sudo systemctl list-init-files -t init services
      35    sudo systemctl list-init-files -t init service
      36    sudo systemctl list-init-files -t service
      37    sudo systemctl list-init-file -t service
      38    clear
      39    sudo systemctl list-unit-files -t service
      40    clear
      41    sudo systemctl list-unit -t service
      42    sudo systemctl list-units -t service
      43    clear
      44    sudo dpkg --get -selections
      45    sudo dpkg --get -selection
      46    sudo dpkg --get-selections
      47    sudo dpkg --get-selections | grep vim
      48    sudo dpkg --get-selections | grep ucf
      49    sudo dpkg -l cron
      50    sudo dpkg -l cron |grep ii
      51    sudo dpkg -l cron |grep ixgh
      52    sudo dpkg -r cron
      53    clear
      54    sudo apt update
      55    sudo get install zip
      56    sudo apt install zip
      57    sudo dpkg --get-selections zip
      58    sudo dpkg --get-selections
      59    sudo dpkg --get-selections | grep zip
      60    clear
      61    sudo apt update
      62    apt list --upgradable
      63    sudo apt upgrade
      64    sudo apt update
      65    cat /etc/apt/source.lists
      66    cat /etc/apt/source.list
      67    cat /etc/apt/sources.list
      68    sudo apt-cache search apache2
      69    sudo apt-cache show apache2
      70    sudo apt-cache find apache2
      71    sudo apt-cache print apache2
      72    sudo apt-cache view apache2
      73    sudo apt-cache depends apache2
      74    sudo apt-cache rdepends apache2
      75    clear
      76    crontab -e
      77    clear
      78    crontab -e
      79    clear
      80    crontab -e
      81    clear
      82    crontab -e
      83    clear
      84    crontab -
      85    clear
      86    crontab -e
      87    clear
      88    crontab -e
      89    cd
      90    ls
      91    clear
      92    ls
      93    crontab -e
      94    clear
      95    rm crontab -e
      96    clear
      97    sudo crontab -e
      98    clear
      99    vim a1.sh
    100    cd
    101    ls
    102    cd /etc/cloud/templates/
    103    ll
    104    cd ..
    105    ll
    106    cd
    107    cd /etc/cloud/templates/
    108    ll
    109    xclock
    110    cd
    111    xclock
    112    exit
    113    cd
    114    pwd
    115    mkdir Unix Python
    116    ls
    117    mkdir Unix/TP1 Unix/TP2
    118    cd Unix
    119    ls
    120    mkdir Python/TP1 Python/TP2
    121    cd
    122    mkdir Python/TP1 Python/TP2
    123    cd Python
    124    ls
    125    rm -r TP1 TP2
    126    ls
    127    cd
    128    cd Unix
    129    ls
    130    cp TP1 TP2 /Python
    131    cp TP1 TP2 ./Python
    132    cd
    133    cd Unix
    134    ls
    135    cp TP1 TP2 ../Python
    136    cp -r TP1 TP2 ../Python
    137    cd
    138    cd Python
    139    ls
    140    mkdir cd
    141    cd
    142    mkdir -r seance1 seance2 /Unix/TP1/
    143    mkdir /Unix/TP1/seance1 /Unix/TP1/seance2
    144    mkdir -p /Unix/TP1/seance1 /Unix/TP1/seance2
    145    cd
    146    cd Unix
    147    cd TP1
    148    ls
    149    mkdir seance1 seance2
    150    ls
    151    cd
    152    ls-lrt
    153    ls -lrt Python
    154    rmdir cd
    155    cdPython
    156    cd Python
    157    rmdir cd
    158    ls -lrt Pyton
    159    ls -lrt Python
    160    ls
    161    tree
    162    sudo snap install tree
    163    cd
    164    tree
    165    touch /Unix/TP1/seance1/exo{1,2}
    166    cd /Unix/TP1/seance
    167    cd /Unix/TP1/seance1
    168    cd
    169    ls
    170    cd Unix
    171    ls
    172    cd TP1
    173    ls
    174    cd seance1
    175    touch exo{1,2}
    176    cd
    177    cd Python
    178    ls
    179    cd
    180    cd TP2
    181    touch exo{1,2}
    182    tree
    183    cd /Python/TP2
    184    cd Python/TP2
    185    ls
    186    touch exo{1,2}
    187    ls
    188    tree
    189    cd
    190    tree
    191    cd
    192    tree
    193    cd Python/TP1
    194    ls
    195    cd ../Unix/TP2
    196    cd ./Unix/TP2
    197    cd
    198    cd Python/TP1
    199    ls
    200    cd /Unix/TP2
    201    cd ./Unix/TP2
    202    cd ../../Unix/TP2
    203    cd
    204    cd Python
    205    cd TP1
    206    rmdir TP1
    207    rmdir -r TP1
    208    ls
    209    rmdir ../TP1
    210    cd
    211    cd Python
    212    ls
    213    cd
    214    rmdir Python/TP2
    215    cd Python
    216    ls
    217    rmdir TP2
    218    rm -r TP2
    219    Tree
    220    cd
    221    Tree
    222    tree
    223    cd Python
    224    ls
    225    cd
    226    cd Unix/TP1
    227    ls
    228    mv Unix/TP1/seance1/exo1 Unix/TP1/exo1
    229    mv Unix/TP1/seance1/exo1 Unix/TP1
    230    cd
    231    cd Unix
    232    ls
    233    cd TP1
    234    ls
    235    cd seance1
    236    ls
    237    mv exo1 ../../TP1
    238    cd ../../
    239    ls
    240    cd TP1
    241    ls
    242    cd
    243    rm -R Unix/TP1/seance1 Unix/TP1/ex1
    244    rm -R Unix/TP1/seance1 Unix/TP1/exo1
    245    cd Unix
    246    ls
    247    cd TP1
    248    ls
    249    tree
    250    cd
    251    tree
    252    cd Pyhton/TP1
    253    cd Python/TP1
    254    cd Python
    255    cd Python/TP1/
    256    cd
    257    cd Python/TP1
    258    cd Python/TP1/
    259    cd Python
    260    ls
    261    cd Unix/TP1
    262    cd Unix
    263    cd
    264    cd Unix
    265    ls
    266    cd TP2
    267    ls
    268    cd TP1
    269    cd ../
    270    cd
    271    ls
    272    cd Unix
    273    ls
    274    cd TP2
    275    ls
    276    cd ../
    277    cd TP1
    278    ls
    279    rm -r seance2
    280    ls
    281    trecd
    282    tree
    283    *tree
    284    tree
    285    cd
    286    tree
    287    cd Python/Unix
    288    cd Python/Unix/
    289    cd Unix/TP1
    290    ls
    291    touch exo{1,2}
    292    ls
    293    cd
    294    tree
    295    sudo su -
    296    l
    297    cd Unix/TP1
    298    ls-lrt
    299    cd
    300    cd Unix
    301    ls -lrt
    302    sudo chown Exp1 TP1
    303    chown Exp1 TP1
    304    sudo chown Exp1 TP1
    305    cd
    306    sudo chown Exp1 TP1
    307    sudo chown exp1 TP1
    308    ls -lrt
    309    cat /etc/passwd
    310    sudo chown exp1 TP1
    311    sudo chown exp1 /Pthon/TP1
    312    sudo chown exp1 /TP1
    313    cat /etc/passwd | grep exp
    314    ls -lrt Unix
    315    sudo chown -R exp1 Unix/TP1
    316    ls -lrt Unix
    317    sudo chown -R exp2 Python/
    318    cd TP/
    319    cd TP1/
    320    cd TP2/
    321    sudo chown -R exp2 Python
    322    ls -lrt
    323    cd
    324    ls -lrt
    325    cdcd
    326    cd -lrt Python
    327    ls -lrt Python
    328    cd Unix/TP1/seance1
    329    cd Unix/TP2/seance1
    330    cd Unix
    331    ls
    332    cd TP1
    333    ls
    334    ls -s cd
    335    cd
    336    cd Unix/TP1/
    337    ls
    338    ls -s Unix/TP1/exo1 lien
    339    ls -s Unix/TP1/ lien
    340    cd
    341    sudo apt install zip
    342    tar -czvf system.tar.gz Unix
    343    tar -cJvf system.tar.xz Unix
    344    tar -cJvf system.tar.bz2 Unix
    345    tar -cjvf system.tar.bz2 Unix
    346    cd
    347    ls -lrt
    348    tar -czvf Unix.tar.gz
    349    tar -czvf Unix.tar.gz Unix
    350    cd
    351    ls
    352    cd Unix
    353    ls
    354    cd system
    355    cd
    356    cd system
    357    sudo cd system
    358    l
    359    cd
    360    tar -czvf Unix.tar.gz Unix
    361    tar -cxvf Unix.tar.gz Unix
    362    mkdir Python/data
    363    tar -cxvf Unix.tar.gz Python/data
    364    tar -cxvf Unix.tar.gz Python/data/
    365    su exp2
    366    sudo netsat -patune | grep ssh
    367    su - epx2
    368    su -epx2
    369    clear
    370    ssh-keygen -t rsa
    371    y
    372    ssh-keygen -t rsa
    373    ssh-copy-id -i /home/ofi03/.ssh/id_rsa.pub -p 55600 [email protected]
    374    ssh-copy-id -i /home/ofi03/.ssh/id_rsa.pub -p 55600 [email protected]
    375    ps -ef | grep tomcat
    376    cd /etc/systemd/system/
    377    vim tomcat.service
    378    sudo vim tomcat.service
    379    sudo systemctl restart tomcat.service
    380    sudo systemctl daemon-reload tomcat.service
    381    sudo systemctl daemon-reload
    382    sudo systemctl restart tomcat.service
    383    vim tomcat.service
    384    ps -ef | grep tomcat
    385    sudo cd /opt/tomcat/bin
    386    cd /opt/tomcat/bin
    387    sudo vim catalina.sh
    388    sudo vim setenv.sh
    389    sudo systemctl restart tomcat.service
    390    ps -ef | grep tomcat
    391    cd
    392    ps -ef | grep tomcat
    393    sudo systemctl status tomcat.service
    394    journalctl -u tomcat
    395    sudo journalctl -u tomcat
    396    nano /etc/systemd/system/tomcat.service
    397    sudo journalctl -u tomcat
    398    sudo systemctl restart tomcat.service
    399    ps -ef | grep tomcat
    400    journalctl -u tomcat
    401    ps -ef | grep tomcat
    402    sudo vim setenv.sh
    403    sudo systemctl daemon-reload
    404    sudo systemctl restart tomcat.service
    405    cd /opt/tomcat/bin
    406    sudo vim setenv.sh
    407    sudo systemctl restart tomcat.service
    408    ps -ef | grep tomcat
    409    sudo su -l tomcat -s /bin/bash -c 'jmap -dump:format=b, file=dump1.hprof
286223'
    410    ps -ef | grep tomcat
    411    sudo su -l tomcat -s /bin/bash -c 'jmap -dump:format=b, file=dump1.hprof
91901'
    412    sudo su -l tomcat -s /bin/bash -c 'jmap -dump:format=b,file=dump1.hprof
91901'
    413    ls -lrt
    414    cd /opt/tomcat
    415    ls -lrt
    416    cd
    417    ls -lrt
    418    cd /opt/tomcat
    419    mv dump1.hprof /home/ofi03/
    420    sudo mv dump1.hprof /home/ofi03/
    421    sudo chown ofi03:ofi03 /home/ofi03/dump1.hprof
    422    d /bin/setenv
    423    cd /bin
    424    sudo vim setenv.sh
    425    cd /bin/
    426    ls
    427    sudo vim setenv.sh
    428    cd /opt/
    429    ls-lrt
    430    ls -lrt
    431    cd /etc/postgresql/12/
    432    ls -lrt
    433    cd main
    434    ls -lrt
    435    sudo vim postgresql.conf
    436    cd
    437    cd /etc/postgresql/12/main
    438    ls -lrt
    439    sudo vim postgresql.conf
    440    cd /etc/postgresql/12/main
    441    ls -lrt
    442    sudo vim postgresql.conf
    443    ls -lrt
    444    sudo vim pg_hba.conf
    445    systemctl status postgresql
    446    ps -aux | grep postgresql
    447    pg_c
    448    sudo pg_ctlcluster 12 main status
    449    psql -h 146.59.156.114 -p 5432 postgres postgres
    450    sudo pg_ctlcluster 12 main status
    451    psql -h 146.59.156.114 -p 5432 postgres postgres
    452    systemctl restart postgresql
    453    psql -h 146.59.156.114 -p 5432 postgres postgres
    454    sudo vim pg_hba.conf
    455    psql -h 146.59.156.114 -p 5432 postgres postgres
    456    systemctl restart postgresql
    457    sudo pg_ctlcluster 12 main status
    458    psql -h 146.59.156.114 -p 5432 postgres postgres
    459    sudo su -
    460    sudo vim pg_hba.conf
    461    psql -h 146.59.156.114 -p 5432 postgres postgres
    462    sudo vim pg_hba.conf
    463    psql -h 146.59.156.114 -p 5432 postgres postgres
    464    sudo su -
    465    sudo vim pg_hba.conf
    466    cd
    467    cd /etc/postgresql/12/main/
    468    ls -lrt
    469    sudo vim pg_hba.conf
    470    cd /etc/postgresql/12/main/
    471    sudo vim pg_hba.conf
    472    cd /etc/postgresql/12/main/
    473    sudo vim pg_hba.conf
    474    sudo su -
    475    systemctl status tomcat
    476    shutdown
    477    systemctl shutdown tomcat
    478    cd /opt/tomcat
    479    ls -lrt
    480    shutdown
    481    systemctl stop tomcat
    482    systemctl status tomcat
    483    systemctl stop tomcat.service
    484    systemctl status tomcat
    485    sudo su -
    486    systemctl restart postgresql
    487    sudo su -
    488    systemctl restart postgresql
    489    systemctl status postgresql.service
    490    systemctl restart postgresql
    491    sudo su -
    492    systemctl status postgresql.service
    493    cd /etc/postgresql/12/main
    494    ls -lrt
    495    systemctl status postgresql.service
    496    sudo su -
    497    cd
    498    sudo apt install postgresql postgresql contrib
    499    sudo apt install postgresql postgresql-contrib
    500    ls -lrt
    501    cd /etc/postgresql/12/main
    502    sudo vim postgresql.conf
    503    cd
    504    sudo su -
    505    psql -h 146.59.156.114 -p 5432 postgres postgres
    506    sudo su -
    507    sudo postgresql
    508    sudo postgres
    509    sudo -    postgres
    510    sudo su -
    511    history
    512    sudo systemctl status apache2.service
    513    sudo systemctl start apache2.service
    514    sudo vim /etc/apache2/conf-available/security.conf
    515    cd /etc/apache2/sites-available
    516    ls
    517    sudo vim 01-www.secondsite.com.conf
    518    sudo vim 01-www.logwire.org.conf
    519    sudo htpasswd -c /etc/apache2/passwords Amadou
    520    sudo systemctl restart apache2.service
    521    sudo vim 01-www.logwire.org.conf
    522    sudo vim 01-www.secondsite.com.conf
    523    sudo vim 01-www.logwire.org.conf
    524    sudo vim 01-www.secondsite.com.conf
    525    sudo systemctl restart apache2.service
    526    ls
    527    cd /var/www/html/www.secondsite.com/top_secret/
    528    ls
    529    sudo vim index.html
    530    sudo systemctl restart apache2.service
    531    ls
    532    sudo vim index.html
    533    cd
    534    cd /etc/apache2/sites-available/
    535    ls -lrt
    536    sudo vim 01-www.secondsite.com.conf
    537    sudo vim 01-www.logwire.org.conf
    538    sudo vim 01-www.secondsite.com.conf
    539    sudo systemctl restart apache2.service
    540    sudo systemctl restart apache2.service
    541    sudo systemctl restart apache2.service
    542    sudo systemctl status apache2.service
    543    cd
    544    sudo systemctl status apache2
    545    sudo systemctl restart apache2.service
    546    sudo systemctl status apache2.service
    547    ss -lrtnp
    548    sudo systemctl restart apache2.service
    549    journalctl -xe
    550    sudo systemctl restart apache2.service
    551    sudo apt-get install apache2
    552    sudo systemctl status apache2.service
    553    sudo systemctl restart apache2.service
    554    sudo systemctl status apache2.service
    555    sudo systemctl status apache2.service
    556    sudo systemctl start apache2.service
    557    sudo systemctl restart apache2.service
    558    journalctl -xe
    559    sudo systemctl stop apache2.service
    560    sudo systemctl status apache2.service
    561    sudo systemctl restart apache2.service
    562    sudo apt-get install apache2
    563    sudo systemctl restart apache2.service
    564    sudo systemctl status apache2.service
    565    sudo systemctl restart apache2.service
    566    systemctl status apache2.service
    567    sudo systemctl start apache2.service
    568    systemctl status apache2.service
    569    sudo systemctl restart apache2.service
    570    sudo apt update
    571    sudo systemctl restart apache2.service
    572    sudo apt install default
    573    jdksudo apt install default
    574    sudo apt install default-jdk
    575    history
    576    cd /opt/tomcat/bin/
    577    ls
    578    ls -lrt
    579    cd ..
    580    ls -lrt
    581    cd conf
    582    ls -lrt
    583    sudo vim server.xml
    584    sudo systemctl status apache2.service
    585    sudo systemctl restart apache2.service
    586    ls -lrt
    587    sudo systemctl restart apache2.service
    588    sudo vim server.xml cd
    589    cd
    590    cd /var/www/html/www.secondsite.com/top_secret/
    591    ls
    592    sudo vim index.html
    593    cd ../../
    594    ls
    595    sudo vim index.html
    596    sudo systemctl restart apache2.service
    597    sudo systemctl start apache2.service
    598    systemctl status apache2.service
    599    journalctl -xe
    600    systemctl status apache2.service
    601    which lib
    602    systemctl stop apache2.service
    603    sudo systemctl status apache2.service
    604    ps -aux
    605    ps -aux |grep apache
    606    ss -lrtnp
    607    is-active apache-tomcat-9.0.65.tar.gz
    608    is active apache-tomcat-9.0.65.tar.gz
    609    activate apache-tomcat-9.0.65.tar.gz
    610    ss -lrtnp
    611    sudo systemctl restart apache2.service
    612    history
    613    clear
    614    history
    615    sudo systemctl restart apache2.service
    616    systemctl status apache2.service
    617    sudo systemctl restart apache2.service
    618    sudo apt-get purge apache2
    619    sudo apt-get install apache2
    620    sudo systemctl status apache2.service
    621    sudo systemctl restart apache2.service
    622    cd /etc/apache2/sites-available/
    623    ls
    624    sudo vim 01-www.secondsite.com.conf
    625    cd
    626    ls
    627    cd /var/www/html/www.secondsite.com/
    628    ls
    629    cd top_secret/
    630    ls
    631    sudo vim index.html
    632    sudo systemctl restart apache2.service
    633    cd
    634    sudo a2enmod
    635    sudo a2enmod ssl
    636    sudo systemctl restart apache2.service
    637    sudo
    638    openssl req x509 nodes days 365 newkey rsa:2048 keyout / ssl private
/apache selfsigned.key out
    639    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsign
    640    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    641    -help
    642    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    643    sudo nano /etc/apache2/sites
    644    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    645    sudo apachectl configtest
    646    sudo systemctl reload apache2.service
    647    sudo systemctl restart apache2.service
    648    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    649    sudo vim /etc/apache2/sites-available/01-www.logwire.org.conf
    650    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    651    sudo systemctl restart apache2.service
    652    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    653    sudo systemctl restart apache2.service
    654    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    655    sudo openssl -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    656    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    657    history
    658    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    659    history
    660    sudo systemctl restart apache2.service
    661    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    662    sudo vim /opt/tomcat/conf/tomcat-users.xml
    663    sudo vim /opt/tomcat/conf
    664    sudo vim /opt/tomcat/conf/
    665    cd /opt/tomcat/conf/
    666    ls -lrt
    667    sudo vim logging.properties
    668    sudo vim context.xml
    669    sudo vim logging.properties
    670    cd ..
    671    ls -lrt
    672    history
    673    cd / | grep sentenv
    674    ls
    675    history | setenv
    676    cd /opt/
    677    ls
    678    cd /opt/tomcat
    679    ls
    680    cd conf
    681    ls
    682    cd ..
    683    ls
    684    cd conf
    685    ls
    686    cd
    687    ls
    688    cd ..
    689    ls
    690    cd
    691    cd /etc/
    692    ls
    693    cd systemd/system/
    694    ls
    695    cd
    696    cd /opt/tomat/
    697    cd
    698    cd /opt/tomat/
    699    cd /opt/tomcat/
    700    ls
    701    cd bin
    702    ls
    703    sudo vim setenv.sh
    704    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.git
    705    cd postgresql-tomcat/db
    706    cp init.sql /home/ubuntu
    707    sudo cp init.sql /home/ubuntu/
    708    su -postgres
    709    sudo su -postgres
    710    su - postgres
    711    sudo su - postgres
    712    su postgres
    713    sudo su postgres
    714    \q
    715    cd
    716    exit
    717    cd /opt/tomcat
    718    ls
    719    cd /opt/tomcat
    720    cd conf/
    721    ls
    722    sudo vim server.xml
    723    ls
    724    cd bin
    725    ls
    726    sudo vim setenv.sh
    727    cd /opt/systemd/
    728    cd /etc/systemd/
    729    cd system/
    730    ls
    731    sudo vim tomcat.service
    732    cd
    733    sudo vim /opt/tomcat/conf/tomcat-users.xml
    734    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.git
    735    cd postgresql-tomcat/db
    736    cp init.sql /home/ubuntu
    737    sudo cp init.sql /home/ubuntu
    738    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.git
    739    cd postgresql-tomcat/db
    740    sudo cp init.sql /home/ubuntu
    741    su -- postgres
    742    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.gitcd
    743    cd
    744    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.gitcd
    745    sudo systemctl restart postgresql
    746    sudo systemctl restart tomcat.service
    747    systemctl daemon-reload
    748    sudo systemctl daemon-reload
    749    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.gitcd
    750    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.git
    751    cd postgresql-tomcat/db
    752    sudo cp init.sql /home/ubuntu
    753    su - postgres
    754    sudo su - postgres
    755    sudo vim /etc/prometheus/prometheus.yml
    756    dpkg -l apache2
    757    cd /etc/apache2/
    758    ls -lrt
    759    cd conf-available/
    760    ls -lrt
    761    cd
    762    find -Name "error.log"
    763    find -name "error.log"
    764    sudo find -name "error.log"
    765    sudo find -name "access.log"
    766    sudo find "access.log"
    767    find "access.log"
    768    sudo find "error.log"
    769    sudo find -name "error.log"
    770    sudo find -name / "error.log"
    771    sudo find -name "error.log" /
    772    cd /etc/apache2/
    773    ls -lrt
    774    sudo vim apache2.conf
    775    sudo vim conf-available/
    776    sudo vim envares
    777    cd
    778    cd /opt/tomcat/
    779    ls -lrt
    780    cd logs/
    781    ls -lrt
    782    cd catalina.out
    783    sudo vim catalina.out
    784    cd /opt/tomcat/
    785    ls -lrt
    786    cd conf/
    787    ls -lrt
    788    sudo vim server.xml
    789    sudo vim catalina.p
    790    sudo vim catalina
    791    sudo vim tomcat-users.xml
    792    sudo vim logging.properties
    793    sudo vim context.xml
    794    cd /etc/systemd/system/
    795    ls -lrt
    796    cd
    797    cd /opt/tomcat/
    798    ls -lrt
    799    cd bin
    800    ls -lrt
    801    ./version.sh
    802    cd
    803    df -h
    804    top
    805    free -h
    806    adduser oracle
    807    sudo adduser oracle
    808    id oracle
    809    sudo su - oracle
    810    sudo mkdir /opt/oracle
    811    sudo unzip instantclient-sqlplus-linux.x64-19.8.0.0.0dbru.zip -d
/opt/oracle/
    812    sudo vim ~/.profile
    813    sudo chown oracle:oracle /opt/oracle
    814    su - oracle
    815    sudo chown oracle:oracle -R /opt/oracle/instantclient_19_8
    816    sudo su - oracle
    817    sudo su - oracle
    818    sudo chown oracle:oracle -R /opt/oracle/instantclient_19_8
    819    sudo su - oracle
    820    history
    821    sqlplus ot_admin/ot_password@L0CAL_PDB1
    822    sudo su - oracle
    823    sudo apt install ansible
    824    ansible
    825    versionansible
    826    ansible --version
    827    sudo adduser ansadmin
    828    sudo nano /etc/
    829    sudo vim /etc/sudoers
    830    cd /etc/sudoers.d/
    831    sudo cd /etc/sudoers.d/
    832    cd /etc/sudoers.d/
    833    sudo su -
    834    sudo su - ansadmin
    835    sudo su - ansadmin
    836    ansible all -bm group -a "name=rennes"
    837    ansible all -bm group -a "name=rennes"
    838    sudo su - ansadmin
    839    sudo su - ansadmin
    840    ll
    841    cd projetgit/
    842    ll
    843    ssh
    844    ssh-keygen -t rsa
    845    git clone [email protected]:logwire9/projet1.git
    846    ssh-keygen -t rsa
    847    cd
    848    cat .ssh/id_rsa.pub
    849    ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAABgQDRXIB324zopABpaxXK8QQKhwMWlILiCpMOnWZMzM5zejf2I0+eGYNGY
rva+6LjnvcmZDUHKcS+19LeNewqk3o41xzSF6r2/FkKEc0xbu7bpY5Gyzxjh0XiDMVIFg3NjKBN17+9to5doS
GYnbBU53IFFEhFSBr3jg2+UzzSbmW76ZNlr7wu5kD/yoROkN7eRVmfjt4PtzwK3sg8gGEdhwDrgXlWkoYgw2B
joXtecnR27iXwFnFoMsr2By05GZ0Ap7lTdZVqsIAyBZyyAov2VJwzn/
4rEu8RPjBL8WtGr5PCImmv0flcWiEYKY7EvDHb3e+wI8t                                       
0Bi+ExIU8ULifoOEYVXNH0mxM5RGVRFBrOFI654286qWe9PxYzioFJ/w8j0YqAtPKtA9E32zR9LN+cLtu7vUB
rhPDFjBSNxO/+/iUR0Ig+R4mvfYWgontuICBvDQ5vC6zx9E/
BvZsY21kopqh62KzqwsmJPe0benNsLMomNSMzh2zlKCIqJytSFIM                                 
tKk= ofi03@svl200
    850    cd projetgit/.
    851    git clone [email protected]:logwire9/projet1.git
    852    ll
    853    cd projet1/
    854    ll
    855    sudo vim conflit.txt
    856    sudo vim java.txt
    857    git add .
    858    git commit -m "ajout fichier java"
    859    git push conflit.txt
    860    git push
    861    sudo vim java.txt
    862    git add .
    863    git commit -m "modif fichier java"
    864    git push
    865    git pull
    866    sudo vim java.txt
    867    git add .
    868    git commit -m "modif fichier"
    869    git push
    870    git branch
    871    git bra
    872    git branch
    873    git branch dev
    874    git branch
    875    git checkout dev
    876    git branch
    877    ll
    878    git log --oneline
    879    git push conflit.txt
    880    sudo vim conflit.txt
    881    git add .
    882    git commit -m "modif fichier conflit"
    883    git push
    884    git push
    885    git commit -m "modif fichier conflit"
    886    git commit -m "modif fichier conflit.txt"
    887    git log --oneline --graph --decorate -all
    888    git dev --oneline --graph --decorate -all
    889    git log --oneline --graph --decorate --all
    890    git checkout master
    891    git merge dev
    892    git log --oneline --graph --decorate --all
    893    git push
    894    git log --oneline --graph --decorate --all
    895    cd ../../
    896    mkdir projetmerge
    897    cd projetmerge/
    898    git clone https://gitlab.com/logwire7/projet1.git
    899    git branch
    900    cd ..
    901    cd projetgit/
    902    mv ../projetmerge/ ..
    903    mv ../projetmerge/ .
    904    ll
    905    cd projetmerge/
    906    git branch
    907    git clone https://gitlab.com/logwire7/projet1.git
    908    git branch aaw
    909    git branch
    910    git checkout aaw
    911    git branch
    912    ll
    913    sudo vim aaw.txt
    914    git push origin aaw
    915    ll
    916    git branch
    917    cd
    918    cd projetgit/projet1/
    919    ll
    920    git
    921    git branch aaw
    922    git branch
    923    git checkout aaw
    924    ll
    925    sudo vim index.html
    926    git add .
    927    git commit -m "modif index"
    928    git push origin aaw
    929    git push origin master
    930    cd ..
    931    cd projetmerge/
    932    ll
    933    sudo vim aaw.txt
    934    ll
    935    sudo vim index.html
    936    git add .
    937    git commit -m "modif index"
    938    git push origin aaw
    939    git branch
    940    git branch aaw
    941    git branch
    942    git checkout aaw
    943    git push origin aaw
    944    git push origin master
    945    git tag
    946    ll
    947    git log --oneline
    948    git tag v1.2 45109db
    949    git log --oneline
    950    git tag v1.2 cea8cbf
    951    git push origin v1.2
    952    git tag v1.3 45109db
    953    git push origin v1.3
    954    sudo su - ansadmin
    955    history
ofi03@svl200:~$ cd
.ansible/                    .local/                        Unix/                   
d1/                                lien/                            monappli/       
snap/                            tp1/
.cache/                        .ssh/                            am/                 
data/                            lien_backup/              postgresql-tomcat/ system/
tp2/
.config/                      Python/                        backup/                 
hello.war/                  list/                            projetgit/             
targz/
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ git --version
git version 2.25.1
ansadmin@svl200:~$ ll
total 280
drwxr-xr-x 14 ansadmin ansadmin    4096 Oct    7 18:57 ./
drwxr-xr-x 11 root          root            4096 Oct    3 08:32 ../
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 14:52 .ansible/
-rw-------    1 ansadmin ansadmin 34979 Oct    8 13:56 .bash_history
-rw-r--r--    1 ansadmin ansadmin      220 Oct    3 08:32 .bash_logout
-rw-r--r--    1 ansadmin ansadmin    3771 Oct    3 08:32 .bashrc
-rw-r--r--    1 root          root          12288 Oct    4 08:51 .exo4.yaml.swp
-rw-------    1 root          root          12288 Oct    3 13:11 .handler.yaml.swp
-rw-r--r--    1 ansadmin ansadmin      807 Oct    3 08:32 .profile
drwx------    2 ansadmin ansadmin    4096 Oct    6 10:47 .ssh/
-rw-------    1 ansadmin ansadmin    8842 Oct    7 18:49 .viminfo
drwxr-xr-x    3 root          root            4096 Oct    6 09:27 TP3/
drwxrwxr-x    6 ansadmin ansadmin    4096 Oct    7 18:57 TPansible/
-rw-r--r--    1 root          root                  0 Oct    3 10:12 cible1.txt
-rw-r--r--    1 root          root              173 Oct    4 12:29 copie.yaml
-rw-r--r--    1 root          root              261 Oct    5 11:29 debug.yaml
-rw-r--r--    1 ansadmin ansadmin      277 Oct    3 17:57 debug1.yaml
-rw-r--r--    1 root          root              190 Oct    4 08:34 exo2.yaml
-rw-r--r--    1 root          root              175 Oct    4 08:44 exo3.yaml
-rw-r--r--    1 root          root              147 Oct    4 13:05 exo4.yaml
-rw-r--r--    1 root          root              247 Oct    3 14:37 fact.yaml
-rw-r--r--    1 ansadmin ansadmin      179 Oct    3 14:46 fact1.yaml
drwxrwxr-x    3 ansadmin ansadmin    4096 Oct    7 12:36 git/
-rw-r--r--    1 root          root              428 Oct    3 13:28 handler.yaml
-rw-------    1 ansadmin ansadmin      255 Oct    4 13:34 hello.yaml
-rw-------    1 ansadmin ansadmin      355 Oct    4 13:26 hello.yml
-rw-r--r--    1 root          root                24 Oct    3 13:38 index.html
-rw-r--r--    1 root          root              243 Oct    4 13:01 index.html.j2
-rw-r--r--    1 ansadmin ansadmin      135 Oct    4 13:01 index.html1.j2
-rw-r--r--    1 root          root                  0 Oct    3 14:40 ip.txt
-rw-r--r--    1 ansadmin ansadmin      247 Oct    4 10:35 item_users.yaml
-rw-r--r--    1 root          root              244 Oct    4 10:20 items.yaml
-rw-r--r--    1 root          root                  0 Oct    4 10:24 items_users.yaml
-rw-r--r--    1 root          root              235 Oct    4 10:08 list.yaml
-rw-r--r--    1 root          root              184 Oct    4 13:58 locale.yml
-rw-r--r--    1 root          root              224 Oct    3 12:31 nginx.yaml
-rw-r--r--    1 root          root              254 Oct    4 13:41 play-vars.yaml
-rw-------    1 ansadmin ansadmin      273 Oct    4 13:49 play-vars.yml
drwxrwxr-x    4 ansadmin ansadmin    4096 Oct    5 13:44 projet/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 13:14 projet1/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    6 07:29 projet2/
drwxrwxr-x 10 ansadmin ansadmin    4096 Oct    5 14:49 projet3/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    7 19:54 projet4/
-rw-r--r--    1 root          root              595 Oct    4 09:57 rep.yaml
-rw-r--r--    1 ansadmin ansadmin      209 Oct    4 12:04 seq.yaml
-rw-r--r--    1 root          root              199 Oct    3 13:01 shell.yml
drwx------    3 ansadmin ansadmin    4096 Oct    5 10:20 snap/
-rw-r--r--    1 root          root              228 Oct    4 13:14 template.yaml
-rw-r--r--    1 ansadmin ansadmin      254 Oct    4 13:21 template1.yaml
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    7 20:56 tpansible/
-rw-r--r--    1 root          root              268 Oct    4 14:35 var_dic.yml
-rw-r--r--    1 ansadmin ansadmin      280 Oct    4 15:12 var_dic2.yml
-rw-r--r--    1 root          root              337 Oct    5 14:04 var_dic_multi3.yml
-rw-r--r--    1 ansadmin ansadmin      146 Oct    4 15:07 vars.yml
-rw-r--r--    1 ansadmin ansadmin      149 Oct    5 10:26 vars2.yml
-rw-r--r--    1 root          root              237 Oct    5 08:08 vars_multi.yml
-rw-r--r--    1 root          root              304 Oct    3 17:58 when.yaml
-rw-r--r--    1 root          root              316 Oct    4 09:32 when1.yaml
ansadmin@svl200:~$
ansadmin@svl200:~$ ls -lrt projet
projet/    projet1/ projet2/ projet3/ projet4/
ansadmin@svl200:~$ ls -lrt projet
projet/    projet1/ projet2/ projet3/ projet4/
ansadmin@svl200:~$ ls -lrt projet
projet/    projet1/ projet2/ projet3/ projet4/
ansadmin@svl200:~$ ls -lrt projet
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ git init
Initialized empty Git repository in /home/ansadmin/tpansible/.git/
ansadmin@svl200:~/tpansible$ ll
total 32
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    8 15:00 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    7 18:57 ../
drwxrwxr-x    7 ansadmin ansadmin 4096 Oct    8 15:00 .git/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ ls -lrt .git/
total 32
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    8 15:00 branches
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    8 15:00 refs
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    8 15:00 info
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    8 15:00 hooks
-rw-rw-r-- 1 ansadmin ansadmin      73 Oct    8 15:00 description
-rw-rw-r-- 1 ansadmin ansadmin      23 Oct    8 15:00 HEAD
drwxrwxr-x 4 ansadmin ansadmin 4096 Oct    8 15:00 objects
-rw-rw-r-- 1 ansadmin ansadmin      92 Oct    8 15:00 config
ansadmin@svl200:~/tpansible$ git config --global user.name "aaw"
ansadmin@svl200:~/tpansible$ git config --global user.email "[email protected]"
ansadmin@svl200:~/tpansible$ ll
total 32
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    8 15:00 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    8 15:03 ../
drwxrwxr-x    7 ansadmin ansadmin 4096 Oct    8 15:00 .git/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ git status
On branch master
No commits yet

Untracked files:
    (use "git add <file>..." to include in what will be committed)
                group_vars/
                hosts.yml
                psql.yml
                roles/

nothing added to commit but untracked files present (use "git add" to track)
ansadmin@svl200:~/tpansible$ git ls-tree -r HEAD
fatal: Not a valid object name HEAD
ansadmin@svl200:~/tpansible$ touch fichier.txt
ansadmin@svl200:~/tpansible$ git status
On branch master

No commits yet

Untracked files:
    (use "git add <file>..." to include in what will be committed)
                fichier.txt
                group_vars/
                hosts.yml
                psql.yml
                roles/

nothing added to commit but untracked files present (use "git add" to track)
ansadmin@svl200:~/tpansible$ git add fichier.txt
ansadmin@svl200:~/tpansible$ git status
On branch master

No commits yet

Changes to be committed:
    (use "git rm --cached <file>..." to unstage)
                new file:      fichier.txt

Untracked files:
    (use "git add <file>..." to include in what will be committed)
                group_vars/
                hosts.yml
                psql.yml
                roles/

ansadmin@svl200:~/tpansible$ git branch


ansadmin@svl200:~/tpansible$ git commit -m "ajout fichier.txt"
[master (root-commit) cdc36a7] ajout fichier.txt
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100644 fichier.txt
ansadmin@svl200:~/tpansible$ git status
On branch master
Untracked files:
    (use "git add <file>..." to include in what will be committed)
                group_vars/
                hosts.yml
                psql.yml
                roles/

nothing added to commit but untracked files present (use "git add" to track)
ansadmin@svl200:~/tpansible$ git ls-tree -r HEAD
100644 blob e69de29bb2d1d6434b8b29ae775ad8c2e48c5391        fichier.txt
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ll
total 32
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    8 15:11 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    8 15:03 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 15:13 .git/
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ tree
.
├── fichier.txt
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

12 directories, 13 files
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ll
total 32
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    8 15:11 ./
drwxr-xr-x 14 ansadmin ansadmin 4096 Oct    8 15:03 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 15:13 .git/
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ mkdir ../progetgit
ansadmin@svl200:~/tpansible$ mv .git/ ../progetgit/
ansadmin@svl200:~/tpansible$ ll
total 28
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    8 15:28 ./
drwxr-xr-x 15 ansadmin ansadmin 4096 Oct    8 15:27 ../
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ cd ../
ansadmin@svl200:~$ ll
total 288
drwxr-xr-x 15 ansadmin ansadmin    4096 Oct    8 15:27 ./
drwxr-xr-x 11 root          root            4096 Oct    3 08:32 ../
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 14:52 .ansible/
-rw-------    1 ansadmin ansadmin 34979 Oct    8 13:56 .bash_history
-rw-r--r--    1 ansadmin ansadmin      220 Oct    3 08:32 .bash_logout
-rw-r--r--    1 ansadmin ansadmin    3771 Oct    3 08:32 .bashrc
-rw-r--r--    1 root          root          12288 Oct    4 08:51 .exo4.yaml.swp
-rw-rw-r--    1 ansadmin ansadmin        52 Oct    8 15:03 .gitconfig
-rw-------    1 root          root          12288 Oct    3 13:11 .handler.yaml.swp
-rw-r--r--    1 ansadmin ansadmin      807 Oct    3 08:32 .profile
drwx------    2 ansadmin ansadmin    4096 Oct    6 10:47 .ssh/
-rw-------    1 ansadmin ansadmin    8842 Oct    7 18:49 .viminfo
drwxr-xr-x    3 root          root            4096 Oct    6 09:27 TP3/
drwxrwxr-x    6 ansadmin ansadmin    4096 Oct    7 18:57 TPansible/
-rw-r--r--    1 root          root                  0 Oct    3 10:12 cible1.txt
-rw-r--r--    1 root          root              173 Oct    4 12:29 copie.yaml
-rw-r--r--    1 root          root              261 Oct    5 11:29 debug.yaml
-rw-r--r--    1 ansadmin ansadmin      277 Oct    3 17:57 debug1.yaml
-rw-r--r--    1 root          root              190 Oct    4 08:34 exo2.yaml
-rw-r--r--    1 root          root              175 Oct    4 08:44 exo3.yaml
-rw-r--r--    1 root          root              147 Oct    4 13:05 exo4.yaml
-rw-r--r--    1 root          root              247 Oct    3 14:37 fact.yaml
-rw-r--r--    1 ansadmin ansadmin      179 Oct    3 14:46 fact1.yaml
drwxrwxr-x    3 ansadmin ansadmin    4096 Oct    7 12:36 git/
-rw-r--r--    1 root          root              428 Oct    3 13:28 handler.yaml
-rw-------    1 ansadmin ansadmin      255 Oct    4 13:34 hello.yaml
-rw-------    1 ansadmin ansadmin      355 Oct    4 13:26 hello.yml
-rw-r--r--    1 root          root                24 Oct    3 13:38 index.html
-rw-r--r--    1 root          root              243 Oct    4 13:01 index.html.j2
-rw-r--r--    1 ansadmin ansadmin      135 Oct    4 13:01 index.html1.j2
-rw-r--r--    1 root          root                  0 Oct    3 14:40 ip.txt
-rw-r--r--    1 ansadmin ansadmin      247 Oct    4 10:35 item_users.yaml
-rw-r--r--    1 root          root              244 Oct    4 10:20 items.yaml
-rw-r--r--    1 root          root                  0 Oct    4 10:24 items_users.yaml
-rw-r--r--    1 root          root              235 Oct    4 10:08 list.yaml
-rw-r--r--    1 root          root              184 Oct    4 13:58 locale.yml
-rw-r--r--    1 root          root              224 Oct    3 12:31 nginx.yaml
-rw-r--r--    1 root          root              254 Oct    4 13:41 play-vars.yaml
-rw-------    1 ansadmin ansadmin      273 Oct    4 13:49 play-vars.yml
drwxrwxr-x    3 ansadmin ansadmin    4096 Oct    8 15:28 progetgit/
drwxrwxr-x    4 ansadmin ansadmin    4096 Oct    5 13:44 projet/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    5 13:14 projet1/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    6 07:29 projet2/
drwxrwxr-x 10 ansadmin ansadmin    4096 Oct    5 14:49 projet3/
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    7 19:54 projet4/
-rw-r--r--    1 root          root              595 Oct    4 09:57 rep.yaml
-rw-r--r--    1 ansadmin ansadmin      209 Oct    4 12:04 seq.yaml
-rw-r--r--    1 root          root              199 Oct    3 13:01 shell.yml
drwx------    3 ansadmin ansadmin    4096 Oct    5 10:20 snap/
-rw-r--r--    1 root          root              228 Oct    4 13:14 template.yaml
-rw-r--r--    1 ansadmin ansadmin      254 Oct    4 13:21 template1.yaml
drwxrwxr-x    5 ansadmin ansadmin    4096 Oct    8 15:28 tpansible/
-rw-r--r--    1 root          root              268 Oct    4 14:35 var_dic.yml
-rw-r--r--    1 ansadmin ansadmin      280 Oct    4 15:12 var_dic2.yml
-rw-r--r--    1 root          root              337 Oct    5 14:04 var_dic_multi3.yml
-rw-r--r--    1 ansadmin ansadmin      146 Oct    4 15:07 vars.yml
-rw-r--r--    1 ansadmin ansadmin      149 Oct    5 10:26 vars2.yml
-rw-r--r--    1 root          root              237 Oct    5 08:08 vars_multi.yml
-rw-r--r--    1 root          root              304 Oct    3 17:58 when.yaml
-rw-r--r--    1 root          root              316 Oct    4 09:32 when1.yaml
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ll
total 28
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    8 15:28 ./
drwxr-xr-x 15 ansadmin ansadmin 4096 Oct    8 15:27 ../
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ git ls-tree -r HEAD
fatal: not a git repository (or any of the parent directories): .git
ansadmin@svl200:~/tpansible$ git status
fatal: not a git repository (or any of the parent directories): .git
ansadmin@svl200:~/tpansible$ mv ../progetgit/.git/ .
ansadmin@svl200:~/tpansible$ ll
total 32
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    8 15:30 ./
drwxr-xr-x 15 ansadmin ansadmin 4096 Oct    8 15:27 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 15:13 .git/
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ exit
logout
ofi03@svl200:~$ ll
total 160100
drwxr-xr-x 23 ofi03 ofi03          4096 Oct    8 10:41 ./
drwxr-xr-x 11 root    root            4096 Oct    3 08:32 ../
-rw-------    1 ofi03 ofi03            364 Oct    8 10:41 .Xauthority
drwx------    4 ofi03 ofi03          4096 Oct    4 07:55 .ansible/
-rw-------    1 ofi03 ofi03        19067 Oct    8 01:04 .bash_history
-rw-r--r--    1 ofi03 ofi03            220 Aug 31 06:36 .bash_logout
-rw-r--r--    1 ofi03 ofi03          3771 Sep    2 08:39 .bashrc
drwx------    2 ofi03 ofi03          4096 Aug 31 08:04 .cache/
drwx------    3 ofi03 ofi03          4096 Aug 31 10:10 .config/
-rw-rw-r--    1 ofi03 ofi03              51 Oct    7 08:48 .gitconfig
drwxrwxr-x    3 ofi03 ofi03          4096 Sep    1 14:35 .local/
-rw-r--r--    1 ofi03 ofi03            932 Sep 30 09:14 .profile
-rw-rw-r--    1 ofi03 ofi03              66 Sep    1 14:35 .selected_editor
drwx------    2 ofi03 ofi03          4096 Oct    7 12:51 .ssh/
-rw-r--r--    1 ofi03 ofi03                0 Aug 31 10:12 .sudo_as_admin_successful
-rw-------    1 ofi03 ofi03        19513 Oct    7 10:16 .viminfo
drwxrwxr-x    3 exp2    ofi03          4096 Sep    5 13:32 Python/
drwxrwxr-x    4 ofi03 ofi03          4096 Sep    5 12:02 Unix/
-rw-rw-r--    1 ofi03 ofi03            192 Sep    5 13:29 Unix.tar.gz
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    7 14:16 am/
-rw-rw-r--    1 ofi03 ofi03              21 Sep    4 21:44 am.txt
-rw-rw-r--    1 ofi03 ofi03 11593900 Jul 14 13:13 apache-tomcat-9.0.65.tar.gz
drwxrw-rw-    3 root    ofi03          4096 Aug 31 12:05 backup/
drwxrwxr-x    8 ofi03 ofi03          4096 Sep    5 21:25 d1/
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    2 09:47 data/
-rw-rw-r--    1 ofi03 ofi03            198 Oct    6 12:49 dump.sql
-rw-------    1 ofi03 ofi03 41858954 Sep    8 08:17 dump1.hprof
-rw-rw-r--    1 ofi03 ofi03            138 Aug 31 12:39 etudiant.txt
-rw-rw-r--    1 ofi03 ofi03                0 Sep    5 12:26 exo1
-rw-rw-r--    1 ofi03 ofi03                0 Sep    5 12:26 exo2
-rw-------    1 ofi03 ofi03 33635764 Sep    8 09:32 heapdump.hprof
drwxr-xr-x    7 ofi03 ofi03          4096 Sep    7 12:48 hello.war/
-rw-rw-r--    1 ofi03 ofi03 75570057 Sep 30 09:11 instantclient-basic-linux.x64-
19.8.0.0.0dbru.zip
-rw-rw-r--    1 ofi03 ofi03      911254 Sep 30 09:12 instantclient-sqlplus-linux.x64-
19.8.0.0.0dbru.z                                                                     
ip
lrwxrwxrwx    1 ofi03 ofi03                4 Sep    4 13:05 lien -> tp1//
lrwxrwxrwx    1 ofi03 ofi03                7 Aug 31 12:01 lien_backup -> backup//
drwxrwxr-x    4 ofi03 ofi03          4096 Aug 31 09:58 list/
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    7 13:44 monappli/
-rw-------    1 root    root                34 Sep 12 01:06 nano.save
-rw-------    1 root    root                34 Sep 12 01:06 nano.save.1
-rw-------    1 root    root                  9 Oct    3 15:25 nano.save.2
-rw-------    1 root    root                  8 Oct    3 15:25 nano.save.3
-rw-rw-r--    1 ofi03 ofi03              36 Aug 31 12:45 nom.txt
-rw-rw-r--    1 ofi03 ofi03              36 Sep    1 15:42 nom1.txt
drwxrwxr-x    6 ofi03 ofi03          4096 Sep 12 23:37 postgresql-tomcat/
-rw-rw-r--    1 ofi03 ofi03        10240 Aug 31 13:40 profile.tar
-rw-rw-r--    1 ofi03 ofi03          1556 Aug 31 13:47 profile.tar.bz2
-rw-rw-r--    1 ofi03 ofi03          1612 Aug 31 13:46 profile.tar.xz
drwxrwxr-x    5 ofi03 ofi03          4096 Oct    7 13:54 projetgit/
-rw-rw-r--    1 ofi03 ofi03          1317 Oct    6 12:49 psql.yml
-rw-rw-r--    1 ofi03 ofi03                0 Sep    4 21:44 resultat.txt
-rw-rw-r--    1 ofi03 ofi03          4606 Sep    7 13:18 sample.war
-rwxrwxr-x    1 ofi03 ofi03              43 Sep    2 07:56 script0.sh*
-rwxrwxr-x    1 ofi03 ofi03            196 Sep    2 08:21 script1.sh*
-rwxrwxr-x    1 ofi03 ofi03            110 Sep    2 10:29 script10.sh*
-rwxrwxr-x    1 ofi03 ofi03            106 Sep    2 12:08 script11.sh*
-rwxrwxr-x    1 ofi03 ofi03            111 Sep    2 12:22 script12.sh*
-rwxrwxr-x    1 ofi03 ofi03            106 Sep    2 12:27 script13.sh*
-rw-rw-r--    1 ofi03 ofi03                0 Sep    2 12:40 script14
-rw-rw-r--    1 ofi03 ofi03                0 Sep    2 12:38 script14.sh
-rw-rw-r--    1 ofi03 ofi03                0 Sep    2 13:27 script15.sh
-rw-rw-r--    1 ofi03 ofi03                0 Sep    2 13:28 script17.sh
-rwxrwxr-x    1 ofi03 ofi03              66 Sep    2 13:07 script18.sh*
-rwxrwxr-x    1 ofi03 ofi03            102 Sep    2 13:16 script19.sh*
-rw-rw-r--    1 ofi03 ofi03              67 Sep    2 08:29 script2.sh
-rwxrwxr-x    1 ofi03 ofi03              94 Sep    2 13:26 script20.sh*
-rwxrwxr-x    1 ofi03 ofi03            128 Sep    2 13:37 script21.sh*
-rwxrwxr-x    1 ofi03 ofi03            162 Sep    2 13:50 script22.sh*
-rwxrwxr-x    1 ofi03 ofi03            220 Sep    2 14:05 script23.sh*
-rwxrwxr-x    1 ofi03 ofi03            195 Sep    2 09:03 script3.sh*
-rwxrwxr-x    1 ofi03 ofi03            104 Sep    2 09:34 script4.sh*
-rwxrwxr-x    1 ofi03 ofi03              48 Sep    2 09:45 script5.sh*
-rwxrwxr-x    1 ofi03 ofi03              91 Sep    2 10:14 script6.sh*
-rwxrwxr-x    1 ofi03 ofi03            106 Sep    2 10:13 script7.sh*
-rwxrwxr-x    1 ofi03 ofi03            135 Sep    2 10:23 script8.sh*
-rwxrwxr-x    1 ofi03 ofi03            110 Sep    2 10:25 script9.sh*
-rw-rw-r--    1 ofi03 ofi03              94 Sep    4 21:38 sed.txt
drwx------    3 ofi03 ofi03          4096 Sep    5 12:20 snap/
drw-------    2 ofi03 ofi03          4096 Aug 31 09:35 system/
-rwxr-xr-x    1 ofi03 ofi03          2738 Aug 31 09:41 system.log*
-rw-rw-r--    1 ofi03 ofi03        10240 Aug 31 13:38 system.tar
-rw-rw-r--    1 ofi03 ofi03            208 Sep    5 13:24 system.tar.bz2
-rw-rw-r--    1 ofi03 ofi03            192 Sep    5 13:22 system.tar.gz
-rw-rw-r--    1 ofi03 ofi03            228 Sep    5 13:23 system.tar.xz
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    2 13:29 targz/
-rw-r--r--    1 root    root                  0 Sep    1 09:31 test.log
-rw-rw-r--    1 ofi03 ofi03                0 Sep    1 15:20 test_ssh.log
drwxrwxr-x    2 ofi03 ofi03          4096 Sep    4 13:06 tp1/
drwxrwxr-x    3 ofi03 ofi03          4096 Sep    2 15:42 tp2/
-rw-------    1 ofi03 ofi03          2602 Sep    5 15:54 yes
-rw-r--r--    1 ofi03 ofi03            566 Sep    5 15:54 yes.pub
-rw-rw-r--    1 ofi03 ofi03          1543 Aug 31 13:52 {profile.tar.gz_old}
ofi03@svl200:~$ cd projetgit/
ofi03@svl200:~/projetgit$ ll
total 32
drwxrwxr-x    5 ofi03 ofi03 4096 Oct    7 13:54 ./
drwxr-xr-x 23 ofi03 ofi03 4096 Oct    8 10:41 ../
drwxrwxr-x    8 ofi03 ofi03 4096 Oct    7 13:58 .git/
-rw-r--r--    1 root    root        17 Oct    7 09:08 .gitignore
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
-rw-rw-r--    1 ofi03 ofi03      84 Oct    7 10:16 index.html
-rw-------    1 ofi03 ofi03        1 Oct    7 12:30 nano.save
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 14:08 projet1/
drwxrwxr-x    3 ofi03 ofi03 4096 Oct    7 14:13 projetmerge/
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:06 readme.md
-rw-rw-r--    1 ofi03 ofi03        0 Oct    7 09:07 tuto.pdf
ofi03@svl200:~/projetgit$
ofi03@svl200:~/projetgit$ cd
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
[email protected]: Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights


and the repository exists.
ansadmin@svl200:~/tpansible$ cd
ansadmin@svl200:~$ cat .ssh/
id_rsa              id_rsa.pub      known_hosts
ansadmin@svl200:~$ cat .ssh/id_rsa.pub
ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAABgQC+mSwnfLabQvto3xXof26d1FSVallOycWRUXofBs4lrFoDakRQlVS/
kQuygGr0FAudHvTJCMZ8SM8F2atIy4rrgWrBlysk1WJmqBr2X6Xj1GzjykWlezNrZYkbrTwZVtBG6hvuSKeNn
rdYxq4LW                                       
2DsgtNf2+ex+jGPW8K/cQHmrWG9IPBVpsRFwC0V50fvvsil4UYIUC3lfugRA1yduzPFYEU/
5rEmHvmxfVKZ8KxoEjEVJFgTLJZ0AX0OKLJuZVv+HiBcBVbRVnfk+LYz9R4FcjijoCFZMGNbVSJdi9IaqPVFk
a6zXZn6WItoiOs7t0TuJJCf/6sNJR                                       
drtvVc4Et7EwX3jP5/MTblLEPPYIaZUF3jT6qBPHUt+NQpGe/SBq1EFYziv84aU6CKvCe1uhIMJV1ekqr8B+c
VoL8TdUunvCWJ6y2UOGF1vqMoxz21L43X5dz+udXPvECb4HNyIX6sccXQ9pfBTHkMeVNypz2xQffSphudoeJi
Bc7pVlMOPvs= an                                        sadmin@svl200
ansadmin@svl200:~$ ^C
ansadmin@svl200:~$ git clone [email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible$ ll
total 36
drwxrwxr-x    7 ansadmin ansadmin 4096 Oct    8 16:07 ./
drwxr-xr-x 16 ansadmin ansadmin 4096 Oct    8 16:06 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 15:13 .git/
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ mkdir clone
ansadmin@svl200:~/tpansible$ cd clone/
ansadmin@svl200:~/tpansible/clone$ git clone [email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible/clone$ ll
total 12
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:07 ./
drwxrwxr-x 8 ansadmin ansadmin 4096 Oct    8 16:07 ../
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql/
ansadmin@svl200:~/tpansible/clone$
ansadmin@svl200:~/tpansible/clone$ cd ..
ansadmin@svl200:~/tpansible$ ll
total 40
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 16:07 ./
drwxr-xr-x 16 ansadmin ansadmin 4096 Oct    8 16:06 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 15:13 .git/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    8 16:07 clone/
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ cd role_psql/
ansadmin@svl200:~/tpansible/role_psql$ ll
total 12
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:07 ./
drwxrwxr-x 8 ansadmin ansadmin 4096 Oct    8 16:07 ../
drwxrwxr-x 7 ansadmin ansadmin 4096 Oct    8 16:07 .git/
ansadmin@svl200:~/tpansible/role_psql$ cd ./git
-bash: cd: ./git: No such file or directory
ansadmin@svl200:~/tpansible/role_psql$
ansadmin@svl200:~/tpansible/role_psql$ cd ..
ansadmin@svl200:~/tpansible$ ll
total 40
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 16:07 ./
drwxr-xr-x 16 ansadmin ansadmin 4096 Oct    8 16:06 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 15:13 .git/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    8 16:07 clone/
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ rm clone/
rm: cannot remove 'clone/': Is a directory
ansadmin@svl200:~/tpansible$ rm -r clone/
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ll
total 36
drwxrwxr-x    7 ansadmin ansadmin 4096 Oct    8 16:09 ./
drwxr-xr-x 16 ansadmin ansadmin 4096 Oct    8 16:06 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 15:13 .git/
-rw-rw-r--    1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ sudo vim psql.yml
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
-rw-rw-r-- 1 ansadmin ansadmin        0 Oct    8 15:11 fichier.txt
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql
ansadmin@svl200:~/tpansible$ rm fichier.txt
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql
ansadmin@svl200:~/tpansible$ git add .
error: 'role_psql/' does not have a commit checked out
fatal: adding files failed
ansadmin@svl200:~/tpansible$ git add role_psql/
error: 'role_psql/' does not have a commit checked out
fatal: adding files failed
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql
ansadmin@svl200:~/tpansible$ cd roles
ansadmin@svl200:~/tpansible/roles$ ls -lrt
total 4
drwxrwxr-x 10 ansadmin ansadmin 4096 Oct    7 19:29 postgres
ansadmin@svl200:~/tpansible/roles$
ansadmin@svl200:~/tpansible/roles$ cd ..
ansadmin@svl200:~/tpansible$ git branch
* master
ansadmin@svl200:~/tpansible$ git push origin master
fatal: 'origin' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights


and the repository exists.
ansadmin@svl200:~/tpansible$ cd ..
ansadmin@svl200:~$ git push tpansible
fatal: not a git repository (or any of the parent directories): .git
ansadmin@svl200:~$ git push tpansible master
fatal: not a git repository (or any of the parent directories): .git
ansadmin@svl200:~$ git push
.ansible/                      .profile                        debug.yaml           
git/                                ip.txt                            play-vars.yaml 
projet4/                        template1.yaml            vars_multi.yml
.bash_history              .ssh/                              debug1.yaml           
handler.yaml                item_users.yaml          play-vars.yml             
rep.yaml                        tpansible/                    when.yaml
.bash_logout                .viminfo                        exo2.yaml               
hello.yaml                    items.yaml                    progetgit/               
role_psql/                    var_dic.yml                  when1.yaml
.bashrc                          TP3/                                exo3.yaml       
hello.yml                      items_users.yaml        projet/                       
seq.yaml                        var_dic2.yml
.exo4.yaml.swp            TPansible/                    exo4.yaml                   
index.html                    list.yaml                      projet1/               
shell.yml                      var_dic_multi3.yml
.gitconfig                    cible1.txt                    fact.yaml               
index.html.j2              locale.yml                    projet2/                   
snap/                              vars.yml
.handler.yaml.swp      copie.yaml                    fact1.yaml                   
index.html1.j2            nginx.yaml                    projet3/                     
template.yaml              vars2.yml
ansadmin@svl200:~$ git push ip.txt
fatal: not a git repository (or any of the parent directories): .git
ansadmin@svl200:~$ git add tpansible/
fatal: not a git repository (or any of the parent directories): .git
ansadmin@svl200:~$ git add tpansible
fatal: not a git repository (or any of the parent directories): .git
ansadmin@svl200:~$
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql
ansadmin@svl200:~/tpansible$ git add .
error: 'role_psql/' does not have a commit checked out
fatal: adding files failed
ansadmin@svl200:~/tpansible$ git commit -m "role_psql"
On branch master
Changes not staged for commit:
    (use "git add/rm <file>..." to update what will be committed)
    (use "git restore <file>..." to discard changes in working directory)
                deleted:        fichier.txt

Untracked files:
    (use "git add <file>..." to include in what will be committed)
                group_vars/
                hosts.yml
                psql.yml
                role_psql/
                roles/

no changes added to commit (use "git add" and/or "git commit -a")
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ git add
Nothing specified, nothing added.
Maybe you wanted to say 'git add .'?
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:07 role_psql
ansadmin@svl200:~/tpansible$ cd role_psql/
ansadmin@svl200:~/tpansible/role_psql$ ls
ansadmin@svl200:~/tpansible/role_psql$ rm -r ../role_psql/
ansadmin@svl200:~/tpansible/role_psql$ cd ..
ansadmin@svl200:~/tpansible$ ls -lrt
total 20
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:25 role_psql
ansadmin@svl200:~/tpansible$ git add .
error: 'role_psql/' does not have a commit checked out
fatal: adding files failed
ansadmin@svl200:~/tpansible$ rm -r role_psql/
ansadmin@svl200:~/tpansible$ ls -lrt
total 20
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
ansadmin@svl200:~/tpansible$ git
ansadmin@svl200:~/tpansible$ git add .
ansadmin@svl200:~/tpansible$ git commit -m "mon pojet psql"
[master 5cda2ec] mon pojet psql
13 files changed, 199 insertions(+)
delete mode 100644 fichier.txt
create mode 100644 group_vars/all.yml
create mode 100644 hosts.yml
create mode 100644 psql.yml
create mode 100644 roles/postgres/README.md
create mode 100644 roles/postgres/defaults/main.yml
create mode 100644 roles/postgres/handlers/main.yml
create mode 100644 roles/postgres/meta/main.yml
create mode 100644 roles/postgres/tasks/main.yml
create mode 100644 roles/postgres/templates/index.html.j2
create mode 100644 roles/postgres/tests/inventory
create mode 100644 roles/postgres/tests/test.yml
create mode 100644 roles/postgres/vars/main.yml
ansadmin@svl200:~/tpansible$ git remote -v
ansadmin@svl200:~/tpansible$ git push origin master
fatal: 'origin' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights


and the repository exists.
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible$ git push origin master
fatal: 'origin' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights


and the repository exists.
ansadmin@svl200:~/tpansible$ cd ..
ansadmin@svl200:~$ git push origin master
fatal: not a git repository (or any of the parent directories): .git
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ git push . master
Everything up-to-date
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:28 role_psql
ansadmin@svl200:~/tpansible$ git push . master
Everything up-to-date
ansadmin@svl200:~/tpansible$ git remote -v
ansadmin@svl200:~/tpansible$ git clone https://gitlab.com/logwire9/role_psql.git
fatal: destination path 'role_psql' already exists and is not an empty directory.
ansadmin@svl200:~/tpansible$ mkdir psql_role
ansadmin@svl200:~/tpansible$ cd psql_role/
ansadmin@svl200:~/tpansible/psql_role$ git clone
https://gitlab.com/logwire9/role_psql.git
Cloning into 'role_psql'...
Username for 'https://gitlab.com': ^C
ansadmin@svl200:~/tpansible/psql_role$
ansadmin@svl200:~/tpansible/psql_role$ cd ..
ansadmin@svl200:~/tpansible$ ls -lrt
total 28
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:28 role_psql
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    8 16:33 psql_role
ansadmin@svl200:~/tpansible$ rm -r role_psql/ psql_role/
ansadmin@svl200:~/tpansible$ ls -lrt
total 20
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
ansadmin@svl200:~/tpansible$ git clone https://gitlab.com/logwire9/role_psql.git
Cloning into 'role_psql'...
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible$ git clone https://gitlab.com/logwire9/tpansible.git
Cloning into 'tpansible'...
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
remote: The project you were looking for could not be found or you don't have
permission to view it.
fatal: repository 'https://gitlab.com/logwire9/tpansible.git/' not found
ansadmin@svl200:~/tpansible$ cd ..
ansadmin@svl200:~$
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:34 role_psql
ansadmin@svl200:~/tpansible$ mv roles/ hosts_vars/ hosts
hosts.yml      hosts_vars/
ansadmin@svl200:~/tpansible$ mv roles/ hosts_vars/ hosts.yml psql.yml role_psql/
ansadmin@svl200:~/tpansible$ ls -lrt
total 8
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
drwxrwxr-x 5 ansadmin ansadmin 4096 Oct    8 16:37 role_psql
ansadmin@svl200:~/tpansible$ mv group_vars/ role_psql/
ansadmin@svl200:~/tpansible$ ls -lrt
total 4
drwxrwxr-x 6 ansadmin ansadmin 4096 Oct    8 16:38 role_psql
ansadmin@svl200:~/tpansible$ git clone https://gitlab.com/logwire9/role_psql.git
fatal: destination path 'role_psql' already exists and is not an empty directory.
ansadmin@svl200:~/tpansible$ mv role_psql/* .
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:39 role_psql
ansadmin@svl200:~/tpansible$ git clone https://gitlab.com/logwire9/role_psql.git
fatal: destination path 'role_psql' already exists and is not an empty directory.
ansadmin@svl200:~/tpansible$ cd role_psql/
ansadmin@svl200:~/tpansible/role_psql$ ls
ansadmin@svl200:~/tpansible/role_psql$ rm -r .
rm: refusing to remove '.' or '..' directory: skipping '.'
ansadmin@svl200:~/tpansible/role_psql$ cd ..
ansadmin@svl200:~/tpansible$ rm -r role_psql/
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ git clone https://gitlab.com/logwire9/role_psql.git
Cloning into 'role_psql'...
Username for 'https://gitlab.com': awisme123
Password for 'https://[email protected]':
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible$ ^C
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_psql    roles
ansadmin@svl200:~/tpansible$ git add .
error: 'role_psql/' does not have a commit checked out
fatal: adding files failed
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    7 20:56 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:40 role_psql
ansadmin@svl200:~/tpansible$ sudo vim psql.yml
ansadmin@svl200:~/tpansible$ rm roles_psql
rm: cannot remove 'roles_psql': No such file or directory
ansadmin@svl200:~/tpansible$ rm roles_psql
rm: cannot remove 'roles_psql': No such file or directory
ansadmin@svl200:~/tpansible$ rm role_psql/
rm: cannot remove 'role_psql/': Is a directory
ansadmin@svl200:~/tpansible$ rm role_psql/
rm: cannot remove 'role_psql/': Is a directory
ansadmin@svl200:~/tpansible$ rm -r role_psql/
ansadmin@svl200:~/tpansible$ ll
total 32
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    8 16:43 ./
drwxr-xr-x 16 ansadmin ansadmin 4096 Oct    8 16:06 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 16:42 .git/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    8 16:43 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ git add .
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ git commit -m "mon pojet psql"
On branch master
nothing to commit, working tree clean
ansadmin@svl200:~/tpansible$ git commit . -m "mon pojet psql"
On branch master
nothing to commit, working tree clean
ansadmin@svl200:~/tpansible$ git remote -v
ansadmin@svl200:~/tpansible$ git push . master
Everything up-to-date
ansadmin@svl200:~/tpansible$ git init
Reinitialized existing Git repository in /home/ansadmin/tpansible/.git/
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ ll
total 32
drwxrwxr-x    6 ansadmin ansadmin 4096 Oct    8 16:43 ./
drwxr-xr-x 16 ansadmin ansadmin 4096 Oct    8 16:06 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 16:48 .git/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    8 16:43 psql.yml
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ git add .
ansadmin@svl200:~/tpansible$ git commit . -m "mon pojet psql"
On branch master
nothing to commit, working tree clean
ansadmin@svl200:~/tpansible$ git commit -m "mon pojet psql"
On branch master
nothing to commit, working tree clean
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ git push .
fatal: The current branch master has no upstream branch.
To push the current branch and set the remote as upstream, use

        git push --set-upstream . master

ansadmin@svl200:~/tpansible$ git push


fatal: No configured push destination.
Either specify the URL from the command-line or configure a remote repository using
        git remote add <name> <url>

and then push using the remote name

        git push <name>

ansadmin@svl200:~/tpansible$ git push roles/


fatal: The current branch master has no upstream branch.
To push the current branch and set the remote as upstream, use

        git push --set-upstream roles/ master

ansadmin@svl200:~/tpansible$ git clone warning: You appear to have cloned an empty


repository.
fatal: Too many arguments.

usage: git clone [<options>] [--] <repo> [<dir>]

        -v, --verbose                  be more verbose


        -q, --quiet                      be more quiet
        --progress                        force progress reporting
        -n, --no-checkout          don't create a checkout
        --bare                                create a bare repository
        --mirror                            create a mirror repository (implies bare)
        -l, --local                      to clone from a local repository
        --no-hardlinks                don't use local hardlinks, always copy
        -s, --shared                    setup as shared repository
        --recursive ...              alias of --recurse-submodules
        --recurse-submodules[=<pathspec>]
                                                    initialize submodules in the
clone
        -j, --jobs <n>                number of submodules cloned in parallel
        --template <template-directory>
                                                    directory from which templates
will be used
        --reference <repo>        reference repository
        --reference-if-able <repo>
                                                    reference repository
        --dissociate                    use --reference only while cloning
        -o, --origin <name>      use <name> instead of 'origin' to track upstream
        -b, --branch <branch>
                                                    checkout <branch> instead of the
remote's HEAD
        -u, --upload-pack <path>
                                                    path to git-upload-pack on the
remote
        --depth <depth>              create a shallow clone of that depth
        --shallow-since <time>
                                                    create a shallow clone since a
specific time
        --shallow-exclude <revision>
                                                    deepen history of shallow clone,
excluding rev
        --single-branch              clone only one branch, HEAD or --branch
        --no-tags                          don't clone any tags, and make later
fetches not to follow them
        --shallow-submodules    any cloned submodules will be shallow
        --separate-git-dir <gitdir>
                                                    separate git dir from working
tree
        -c, --config <key=value>
                                                    set config inside the new
repository
        --server-option <server-specific>
                                                    option to transmit
        -4, --ipv4                        use IPv4 addresses only
        -6, --ipv6                        use IPv6 addresses only
        --filter <args>              object filtering
        --remote-submodules      any cloned submodules will use their remote-tracking
branch
        --sparse                            initialize sparse-checkout file to
include only files at root

ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible$ exit
logout
ofi03@svl200:~$ ls
Python                                              dump1.hprof                     
list                              profile.tar.bz2    script12.sh    script21.sh   
sed.txt                  test_ssh.log
Unix                                                  etudiant.txt                   
monappli                      profile.tar.xz      script13.sh    script22.sh    snap 
tp1
Unix.tar.gz                                    exo1                                 
nano.save                    projetgit                script14          script23.sh 
system                    tp2
am                                                      exo2                         
nano.save.1                psql.yml                  script14.sh    script3.sh     
system.log            yes
am.txt                                              heapdump.hprof                   
nano.save.2                resultat.txt          script15.sh    script4.sh     
system.tar            yes.pub
apache-tomcat-9.0.65.tar.gz    hello.war                                             
nano.save.3                sample.war              script17.sh    script5.sh     
system.tar.bz2    {profile.tar.gz_old}
backup                                              instantclient-basic-linux.x64-
19.8.0.0.0dbru.zip        nom.txt                        script0.sh             
script18.sh    script6.sh      system.tar.gz
d1                                                      instantclient-sqlplus-
linux.x64-19.8.0.0.0dbru.zip    nom1.txt                      script1.sh             
script19.sh    script7.sh      system.tar.xz
data                                                  lien                           
postgresql-tomcat    script10.sh            script2.sh      script8.sh      targz
dump.sql                                          lien_backup                       
profile.tar                script11.sh            script20.sh    script9.sh     
test.log
ofi03@svl200:~$ cd projetgit/
ofi03@svl200:~/projetgit$ ls
fichier.html    index.html    nano.save    projet1    projetmerge    readme.md   
tuto.pdf
ofi03@svl200:~/projetgit$ ls
fichier.html    index.html    nano.save    projet1    projetmerge    readme.md   
tuto.pdf
ofi03@svl200:~/projetgit$ ls -lrt
total 16
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 08:50 fichier.html
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 09:06 readme.md
-rw-rw-r-- 1 ofi03 ofi03        0 Oct    7 09:07 tuto.pdf
-rw-rw-r-- 1 ofi03 ofi03      84 Oct    7 10:16 index.html
-rw------- 1 ofi03 ofi03        1 Oct    7 12:30 nano.save
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 14:08 projet1
drwxrwxr-x 3 ofi03 ofi03 4096 Oct    7 14:13 projetmerge
ofi03@svl200:~/projetgit$ cd
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    8 16:43 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:53 role_psql
ansadmin@svl200:~/tpansible$ cd role_psql/
ansadmin@svl200:~/tpansible/role_psql$ git clone
[email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible/role_psql$
ansadmin@svl200:~/tpansible/role_psql$ ls -lrt
total 4
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:56 role_psql
ansadmin@svl200:~/tpansible/role_psql$ rm -r role_psql/
ansadmin@svl200:~/tpansible/role_psql$ ls
ansadmin@svl200:~/tpansible/role_psql$ git add .
ansadmin@svl200:~/tpansible/role_psql$ git commit -m "mon pojet psql"
On branch master

Initial commit

nothing to commit (create/copy files and use "git add" to track)


ansadmin@svl200:~/tpansible/role_psql$ cd ..
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    8 16:43 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:57 role_psql
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_psql    roles
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    8 16:43 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:57 role_psql
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls -lrt
total 24
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    7 19:04 roles
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars
drwxrwxr-x 2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars
-rw-r--r-- 1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
-rw-r--r-- 1 ansadmin ansadmin      87 Oct    8 16:43 psql.yml
drwxrwxr-x 3 ansadmin ansadmin 4096 Oct    8 16:57 role_psql
ansadmin@svl200:~/tpansible$ rm role_psql/
rm: cannot remove 'role_psql/': Is a directory
ansadmin@svl200:~/tpansible$ rm -r role_psql/
rm: remove write-protected regular file
'role_psql/.git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904'?
rm: cannot remove 'role_psql/.git/objects/4b': Directory not empty
ansadmin@svl200:~/tpansible$ rm -r role_psql
rm: remove write-protected regular file
'role_psql/.git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904'? y
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_psql.git
Cloning into 'role_psql'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_psql    roles
ansadmin@svl200:~/tpansible$ rm role_psql
rm: cannot remove 'role_psql': Is a directory
ansadmin@svl200:~/tpansible$ rm -r role_psql
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ git remote rename origin old-origin
fatal: No such remote: 'origin'
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    roles
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_postgres.git
Cloning into 'role_postgres'...
warning: You appear to have cloned an empty repository.
ansadmin@svl200:~/tpansible$ git remote rename origin old-origin
fatal: No such remote: 'origin'
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ git remote add origin
[email protected]:logwire9/role_postgres.git
ansadmin@svl200:~/tpansible$ git push -u origin --all
Enumerating objects: 27, done.
Counting objects: 100% (27/27), done.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (27/27), 3.43 KiB | 501.00 KiB/s, done.
Total 27 (delta 0), reused 0 (delta 0)
To gitlab.com:logwire9/role_postgres.git
* [new branch]            master -> master
Branch 'master' set up to track remote branch 'master' from 'origin'.
ansadmin@svl200:~/tpansible$ git push -u origin --tags
Everything up-to-date
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_postgres.git
fatal: destination path 'role_postgres' already exists and is not an empty directory.
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles
ansadmin@svl200:~/tpansible$ cd role_postgres/
ansadmin@svl200:~/tpansible/role_postgres$ ls
ansadmin@svl200:~/tpansible/role_postgres$ cd..
*cd..: command not found
ansadmin@svl200:~/tpansible/role_postgres$ cd ..
ansadmin@svl200:~/tpansible$ rm -r role_postgres/
ansadmin@svl200:~/tpansible$ git clone [email protected]:logwire9/role_postgres.git
Cloning into 'role_postgres'...
remote: Enumerating objects: 27, done.
remote: Counting objects: 100% (27/27), done.
remote: Compressing objects: 100% (12/12), done.
remote: Total 27 (delta 0), reused 0 (delta 0), pack-reused 0
Receiving objects: 100% (27/27), done.
ansadmin@svl200:~/tpansible$ git remote -v
origin    [email protected]:logwire9/role_postgres.git (fetch)
origin    [email protected]:logwire9/role_postgres.git (push)
ansadmin@svl200:~/tpansible$ cd
.git/                    group_vars/        hosts_vars/        role_postgres/ roles/
ansadmin@svl200:~/tpansible$ cd role_postgres/
ansadmin@svl200:~/tpansible/role_postgres$ git add .
ansadmin@svl200:~/tpansible/role_postgres$ git commit -m "mon pojet postgres"
On branch master
Your branch is up to date with 'origin/master'.

nothing to commit, working tree clean


ansadmin@svl200:~/tpansible/role_postgres$ cd ..
ansadmin@svl200:~/tpansible$ git add .
warning: adding embedded git repository: role_postgres
hint: You've added another git repository inside your current repository.
hint: Clones of the outer repository will not contain the contents of
hint: the embedded repository and will not know how to obtain it.
hint: If you meant to add a submodule, use:
hint:
hint:     git submodule add <url> role_postgres
hint:
hint: If you added this path by mistake, you can remove it from the
hint: index with:
hint:
hint:     git rm --cached role_postgres
hint:
hint: See "git help submodule" for more information.
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ git init
Reinitialized existing Git repository in /home/ansadmin/tpansible/.git/
ansadmin@svl200:~/tpansible$ git add .
ansadmin@svl200:~/tpansible$ git commit -m "mon pojet postgres"
[master 63a6e1f] mon pojet postgres
1 file changed, 1 insertion(+)
create mode 160000 role_postgres
ansadmin@svl200:~/tpansible$ git remote add origin
[email protected]:logwire9/role_postgres.git
fatal: remote origin already exists.
ansadmin@svl200:~/tpansible$ git remote -v
origin    [email protected]:logwire9/role_postgres.git (fetch)
origin    [email protected]:logwire9/role_postgres.git (push)
ansadmin@svl200:~/tpansible$ git push origin master
Enumerating objects: 3, done.
Counting objects: 100% (3/3), done.
Compressing objects: 100% (2/2), done.
Writing objects: 100% (2/2), 266 bytes | 266.00 KiB/s, done.
Total 2 (delta 1), reused 0 (delta 0)
To gitlab.com:logwire9/role_postgres.git
      5cda2ec..63a6e1f    master -> master
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ll
total 36
drwxrwxr-x    7 ansadmin ansadmin 4096 Oct    8 18:16 ./
drwxr-xr-x 16 ansadmin ansadmin 4096 Oct    8 16:06 ../
drwxrwxr-x    8 ansadmin ansadmin 4096 Oct    8 18:24 .git/
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 20:53 group_vars/
-rw-r--r--    1 ansadmin ansadmin    118 Oct    7 20:55 hosts.yml
drwxrwxr-x    2 ansadmin ansadmin 4096 Oct    7 19:13 hosts_vars/
-rw-r--r--    1 ansadmin ansadmin      87 Oct    8 16:43 psql.yml
drwxrwxr-x    5 ansadmin ansadmin 4096 Oct    8 18:16 role_postgres/
drwxrwxr-x    3 ansadmin ansadmin 4096 Oct    7 19:04 roles/
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/meta/main.yml
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml hosts.yml

PLAY [install postgres]


************************************************************************

TASK [Gathering Facts]


*************************************************************************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql-contrib]


**********************************************
ok: [146.59.158.16]

TASK [postgres : Package_python]


***************************************************************
ok: [146.59.158.16]

TASK [postgres : acl]


**************************************************************************
ok: [146.59.158.16]
TASK [postgres : Installation postgresql]
******************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


***************************************************************
ok: [146.59.158.16]

TASK [postgres : BD dbofi]


*********************************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


***************************************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbofi]


************************************
changed: [146.59.158.16]

TASK [postgres : Sauvegarde]


*******************************************************************
changed: [146.59.158.16]

TASK [postgres : BD dbapx]


*********************************************************************
ok: [146.59.158.16]

TASK [postgres : Import BD]


********************************************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        resc                                               
ued=0        ignored=0

ERROR! Syntax Error while loading YAML.


    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/tpansible/hosts.yml': line 2, column 11,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

all
    children:
                    ^ here
ansadmin@svl200:~/tpansible$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml hosts.yml

PLAY [install postgres]


************************************************************************

TASK [Gathering Facts]


*************************************************************************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql-contrib]


**********************************************
ok: [146.59.158.16]

TASK [postgres : Package_python]


***************************************************************
ok: [146.59.158.16]

TASK [postgres : acl]


**************************************************************************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql]


******************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


***************************************************************
ok: [146.59.158.16]

TASK [postgres : BD dbofi]


*********************************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


***************************************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbofi]


************************************
changed: [146.59.158.16]

TASK [postgres : Sauvegarde]


*******************************************************************
changed: [146.59.158.16]

TASK [postgres : BD dbapx]


*********************************************************************
ok: [146.59.158.16]

TASK [postgres : Import BD]


********************************************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        resc                                               
ued=0        ignored=0

ERROR! Syntax Error while loading YAML.


    mapping values are not allowed in this context

The error appears to be in '/home/ansadmin/tpansible/hosts.yml': line 2, column 11,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

all:i
    children:
                    ^ here
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml hosts.yml

PLAY [install postgres]


************************************************************************

TASK [Gathering Facts]


*************************************************************************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql-contrib]


**********************************************
ok: [146.59.158.16]

TASK [postgres : Package_python]


***************************************************************
ok: [146.59.158.16]

TASK [postgres : acl]


**************************************************************************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql]


******************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


***************************************************************
ok: [146.59.158.16]

TASK [postgres : BD dbofi]


*********************************************************************
ok: [146.59.158.16]
TASK [postgres : Start servicde]
***************************************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbofi]


************************************
changed: [146.59.158.16]

TASK [postgres : Sauvegarde]


*******************************************************************
changed: [146.59.158.16]

TASK [postgres : BD dbapx]


*********************************************************************
ok: [146.59.158.16]

TASK [postgres : Import BD]


********************************************************************
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        resc                                               
ued=0        ignored=0

ERROR! A playbook must be a list of plays, got a <class


'ansible.parsing.yaml.objects.AnsibleMap                                             
ping'> instead

The error appears to be in '/home/ansadmin/tpansible/hosts.yml': line 1, column 1,


but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

all:
^ here
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml hosts_vars
ERROR! the playbook: hosts_vars does not appear to be a file
ansadmin@svl200:~/tpansible$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


************************************************************************
TASK [Gathering Facts]
*************************************************************************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql-contrib]


**********************************************
^C [ERROR]: User interrupted execution
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
├── role_postgres
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── psql.yml
│   └── roles
│            └── postgres
│                    ├── README.md
│                    ├── defaults
│                    │   └── main.yml
│                    ├── handlers
│                    │   └── main.yml
│                    ├── meta
│                    │   └── main.yml
│                    ├── tasks
│                    │   └── main.yml
│                    ├── templates
│                    │   └── index.html.j2
│                    ├── tests
│                    │   ├── inventory
│                    │   └── test.yml
│                    └── vars
│                            └── main.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

23 directories, 24 files
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/
README.md    files/          meta/            templates/ vars/
defaults/    handlers/    tasks/          tests/
ansadmin@svl200:~/tpansible$ sudo vim roles/postgres/tasks/main.yml
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
├── role_postgres
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── psql.yml
│   └── roles
│            └── postgres
│                    ├── README.md
│                    ├── defaults
│                    │   └── main.yml
│                    ├── handlers
│                    │   └── main.yml
│                    ├── meta
│                    │   └── main.yml
│                    ├── tasks
│                    │   └── main.yml
│                    ├── templates
│                    │   └── index.html.j2
│                    ├── tests
│                    │   ├── inventory
│                    │   └── test.yml
│                    └── vars
│                            └── main.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

23 directories, 24 files
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles
ansadmin@svl200:~/tpansible$ mv roles/ ../
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── role_postgres
        ├── group_vars
        │   └── all.yml
        ├── hosts.yml
        ├── psql.yml
        └── roles
                └── postgres
                        ├── README.md
                        ├── defaults
                        │   └── main.yml
                        ├── handlers
                        │   └── main.yml
                        ├── meta
                        │   └── main.yml
                        ├── tasks
                        │   └── main.yml
                        ├── templates
                        │   └── index.html.j2
                        ├── tests
                        │   ├── inventory
                        │   └── test.yml
                        └── vars
                                └── main.yml

13 directories, 15 files
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
└── role_postgres
        ├── group_vars
        │   └── all.yml
        ├── hosts.yml
        ├── psql.yml
        └── roles
                └── postgres
                        ├── README.md
                        ├── defaults
                        │   └── main.yml
                        ├── handlers
                        │   └── main.yml
                        ├── meta
                        │   └── main.yml
                        ├── tasks
                        │   └── main.yml
                        ├── templates
                        │   └── index.html.j2
                        ├── tests
                        │   ├── inventory
                        │   └── test.yml
                        └── vars
                                └── main.yml

13 directories, 15 files
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres
ansadmin@svl200:~/tpansible$ mv group_vars/ hosts.yml hosts_vars/ psql.yml ../
ansadmin@svl200:~/tpansible$ tree
.
└── role_postgres
        ├── group_vars
        │   └── all.yml
        ├── hosts.yml
        ├── psql.yml
        └── roles
                └── postgres
                        ├── README.md
                        ├── defaults
                        │   └── main.yml
                        ├── handlers
                        │   └── main.yml
                        ├── meta
                        │   └── main.yml
                        ├── tasks
                        │   └── main.yml
                        ├── templates
                        │   └── index.html.j2
                        ├── tests
                        │   ├── inventory
                        │   └── test.yml
                        └── vars
                                └── main.yml

11 directories, 12 files
ansadmin@svl200:~/tpansible$ tree
.
└── role_postgres
        ├── group_vars
        │   └── all.yml
        ├── hosts.yml
        ├── psql.yml
        └── roles
                └── postgres
                        ├── README.md
                        ├── defaults
                        │   └── main.yml
                        ├── handlers
                        │   └── main.yml
                        ├── meta
                        │   └── main.yml
                        ├── tasks
                        │   └── main.yml
                        ├── templates
                        │   └── index.html.j2
                        ├── tests
                        │   ├── inventory
                        │   └── test.yml
                        └── vars
                                └── main.yml

11 directories, 12 files
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml
ERROR! the playbook: psql.yml could not be found
ansadmin@svl200:~/tpansible$ mv ../group_vars/ ../hosts.yml ../hosts_vars/
../psql.yml .
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml
ERROR! the role 'postgres' was not found in
/home/ansadmin/tpansible/roles:/home/ansadmin/.ansible/roles:/usr/share/ansible/
roles:/etc/ansible/roles:/home/ansadmin/tpansible

The error appears to be in '/home/ansadmin/tpansible/psql.yml': line 6, column 9, but


may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    roles:
            - postgres
                ^ here
ansadmin@svl200:~/tpansible$ mv ../roles/ .
ansadmin@svl200:~/tpansible$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
*************************************************************************************
***********

TASK [Gathering Facts]


*************************************************************************************
*************************************************************************************
************
ok: [146.59.158.16]
TASK [postgres : Installation postgresql-contrib]
*************************************************************************************
**********************************************************************
ok: [146.59.158.16]

TASK [postgres : Package_python]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]

TASK [postgres : acl]


*************************************************************************************
*************************************************************************************
*************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]

TASK [postgres : BD dbofi]


*************************************************************************************
*************************************************************************************
********
ok: [146.59.158.16]

TASK [postgres : Start servicde]


*************************************************************************************
*************************************************************************************
**
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbofi]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

TASK [postgres : Sauvegarde]


*************************************************************************************
*************************************************************************************
******
changed: [146.59.158.16]

TASK [postgres : BD dbapx]


*************************************************************************************
*************************************************************************************
********
ok: [146.59.158.16]

TASK [postgres : Import BD]


*************************************************************************************
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
************************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
├── role_postgres
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── psql.yml
│   └── roles
│            └── postgres
│                    ├── README.md
│                    ├── defaults
│                    │   └── main.yml
│                    ├── handlers
│                    │   └── main.yml
│                    ├── meta
│                    │   └── main.yml
│                    ├── tasks
│                    │   └── main.yml
│                    ├── templates
│                    │   └── index.html.j2
│                    ├── tests
│                    │   ├── inventory
│                    │   └── test.yml
│                    └── vars
│                            └── main.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── files
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

23 directories, 24 files
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles
ansadmin@svl200:~/tpansible$ cd role_postgres/
ansadmin@svl200:~/tpansible/role_postgres$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── psql.yml
└── roles
        └── postgres
                ├── README.md
                ├── defaults
                │   └── main.yml
                ├── handlers
                │   └── main.yml
                ├── meta
                │   └── main.yml
                ├── tasks
                │   └── main.yml
                ├── templates
                │   └── index.html.j2
                ├── tests
                │   ├── inventory
                │   └── test.yml
                └── vars
                        └── main.yml

10 directories, 12 files
ansadmin@svl200:~/tpansible/role_postgres$ ansible-playbook psql.yml

PLAY [install postgres]


*************************************************************************************
*************************************************************************************
***********

TASK [Gathering Facts]


*************************************************************************************
*************************************************************************************
************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql-contrib]


*************************************************************************************
**********************************************************************
ok: [146.59.158.16]

TASK [postgres : Package_python]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]

TASK [postgres : acl]


*************************************************************************************
*************************************************************************************
*************
ok: [146.59.158.16]

TASK [postgres : Installation postgresql]


*************************************************************************************
******************************************************************************
ok: [146.59.158.16]

TASK [postgres : Start servicde]


*************************************************************************************
*************************************************************************************
**
ok: [146.59.158.16]

TASK [postgres : BD dbofi]


*************************************************************************************
*************************************************************************************
********
ok: [146.59.158.16]

TASK [postgres : Start servicde]


*************************************************************************************
*************************************************************************************
**
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbofi]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

TASK [postgres : Sauvegarde]


*************************************************************************************
*************************************************************************************
******
changed: [146.59.158.16]
TASK [postgres : BD dbapx]
*************************************************************************************
*************************************************************************************
********
ok: [146.59.158.16]

TASK [postgres : Import BD]


*************************************************************************************
*************************************************************************************
*******
changed: [146.59.158.16]

TASK [postgres : Add some dummy data to our database dbapx]


*************************************************************************************
************************************************************
changed: [146.59.158.16]

PLAY RECAP
*************************************************************************************
*************************************************************************************
************************
146.59.158.16                            : ok=13    changed=5      unreachable=0   
failed=0        skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible/role_postgres$
ansadmin@svl200:~/tpansible/role_postgres$ ls
group_vars    hosts.yml    psql.yml    roles
ansadmin@svl200:~/tpansible/role_postgres$ roles

Command 'roles' not found, did you mean:

    command 'holes' from deb holes (0.1-4)

Try: apt install <deb name>

ansadmin@svl200:~/tpansible/role_postgres$ cd roles/
ansadmin@svl200:~/tpansible/role_postgres/roles$ l
postgres/
ansadmin@svl200:~/tpansible/role_postgres/roles$ ls
postgres
ansadmin@svl200:~/tpansible/role_postgres/roles$ exit
logout
ofi03@svl200:~$ history
        1    clear
        2    usermod -aG sudo etl3
        3    su - etl
        4    clear
        5    sudo su -
        6    ls -lrt
        7    chmod u=rw,g=rw,o=r system.log
        8    ls -lrt
        9    clear
      10    ls -lrt
      11    chmod 777 system.log
      12    ls -lrt
      13    chmod u=rw,g=rw,o=r system.log
      14    clear
      15    ls -lrt
      16    chmod a+rw system.log
      17    ls -lrt
      18    clear
      19    chmod 755 -R system.log
      20    ls -lrt
      21    cd
      22    cd profile/
      23    cd
      24    sudo touch test.log
      25    ls -lrt
      26    clear
      27    sudo systemctl start cron.service
      28    sudo systemctl is-active cron.service
      29    sudo systemctl stop cron.service
      30    sudo systemctl is-active cron.service
      31    sudo systemctl restart cron.service
      32    sudo systemctl is-active cron.service
      33    sudo systemctl -t help
      34    sudo systemctl list-init-files -t init services
      35    sudo systemctl list-init-files -t init service
      36    sudo systemctl list-init-files -t service
      37    sudo systemctl list-init-file -t service
      38    clear
      39    sudo systemctl list-unit-files -t service
      40    clear
      41    sudo systemctl list-unit -t service
      42    sudo systemctl list-units -t service
      43    clear
      44    sudo dpkg --get -selections
      45    sudo dpkg --get -selection
      46    sudo dpkg --get-selections
      47    sudo dpkg --get-selections | grep vim
      48    sudo dpkg --get-selections | grep ucf
      49    sudo dpkg -l cron
      50    sudo dpkg -l cron |grep ii
      51    sudo dpkg -l cron |grep ixgh
      52    sudo dpkg -r cron
      53    clear
      54    sudo apt update
      55    sudo get install zip
      56    sudo apt install zip
      57    sudo dpkg --get-selections zip
      58    sudo dpkg --get-selections
      59    sudo dpkg --get-selections | grep zip
      60    clear
      61    sudo apt update
      62    apt list --upgradable
      63    sudo apt upgrade
      64    sudo apt update
      65    cat /etc/apt/source.lists
      66    cat /etc/apt/source.list
      67    cat /etc/apt/sources.list
      68    sudo apt-cache search apache2
      69    sudo apt-cache show apache2
      70    sudo apt-cache find apache2
      71    sudo apt-cache print apache2
      72    sudo apt-cache view apache2
      73    sudo apt-cache depends apache2
      74    sudo apt-cache rdepends apache2
      75    clear
      76    crontab -e
      77    clear
      78    crontab -e
      79    clear
      80    crontab -e
      81    clear
      82    crontab -e
      83    clear
      84    crontab -
      85    clear
      86    crontab -e
      87    clear
      88    crontab -e
      89    cd
      90    ls
      91    clear
      92    ls
      93    crontab -e
      94    clear
      95    rm crontab -e
      96    clear
      97    sudo crontab -e
      98    clear
      99    vim a1.sh
    100    cd
    101    ls
    102    cd /etc/cloud/templates/
    103    ll
    104    cd ..
    105    ll
    106    cd
    107    cd /etc/cloud/templates/
    108    ll
    109    xclock
    110    cd
    111    xclock
    112    exit
    113    cd
    114    pwd
    115    mkdir Unix Python
    116    ls
    117    mkdir Unix/TP1 Unix/TP2
    118    cd Unix
    119    ls
    120    mkdir Python/TP1 Python/TP2
    121    cd
    122    mkdir Python/TP1 Python/TP2
    123    cd Python
    124    ls
    125    rm -r TP1 TP2
    126    ls
    127    cd
    128    cd Unix
    129    ls
    130    cp TP1 TP2 /Python
    131    cp TP1 TP2 ./Python
    132    cd
    133    cd Unix
    134    ls
    135    cp TP1 TP2 ../Python
    136    cp -r TP1 TP2 ../Python
    137    cd
    138    cd Python
    139    ls
    140    mkdir cd
    141    cd
    142    mkdir -r seance1 seance2 /Unix/TP1/
    143    mkdir /Unix/TP1/seance1 /Unix/TP1/seance2
    144    mkdir -p /Unix/TP1/seance1 /Unix/TP1/seance2
    145    cd
    146    cd Unix
    147    cd TP1
    148    ls
    149    mkdir seance1 seance2
    150    ls
    151    cd
    152    ls-lrt
    153    ls -lrt Python
    154    rmdir cd
    155    cdPython
    156    cd Python
    157    rmdir cd
    158    ls -lrt Pyton
    159    ls -lrt Python
    160    ls
    161    tree
    162    sudo snap install tree
    163    cd
    164    tree
    165    touch /Unix/TP1/seance1/exo{1,2}
    166    cd /Unix/TP1/seance
    167    cd /Unix/TP1/seance1
    168    cd
    169    ls
    170    cd Unix
    171    ls
    172    cd TP1
    173    ls
    174    cd seance1
    175    touch exo{1,2}
    176    cd
    177    cd Python
    178    ls
    179    cd
    180    cd TP2
    181    touch exo{1,2}
    182    tree
    183    cd /Python/TP2
    184    cd Python/TP2
    185    ls
    186    touch exo{1,2}
    187    ls
    188    tree
    189    cd
    190    tree
    191    cd
    192    tree
    193    cd Python/TP1
    194    ls
    195    cd ../Unix/TP2
    196    cd ./Unix/TP2
    197    cd
    198    cd Python/TP1
    199    ls
    200    cd /Unix/TP2
    201    cd ./Unix/TP2
    202    cd ../../Unix/TP2
    203    cd
    204    cd Python
    205    cd TP1
    206    rmdir TP1
    207    rmdir -r TP1
    208    ls
    209    rmdir ../TP1
    210    cd
    211    cd Python
    212    ls
    213    cd
    214    rmdir Python/TP2
    215    cd Python
    216    ls
    217    rmdir TP2
    218    rm -r TP2
    219    Tree
    220    cd
    221    Tree
    222    tree
    223    cd Python
    224    ls
    225    cd
    226    cd Unix/TP1
    227    ls
    228    mv Unix/TP1/seance1/exo1 Unix/TP1/exo1
    229    mv Unix/TP1/seance1/exo1 Unix/TP1
    230    cd
    231    cd Unix
    232    ls
    233    cd TP1
    234    ls
    235    cd seance1
    236    ls
    237    mv exo1 ../../TP1
    238    cd ../../
    239    ls
    240    cd TP1
    241    ls
    242    cd
    243    rm -R Unix/TP1/seance1 Unix/TP1/ex1
    244    rm -R Unix/TP1/seance1 Unix/TP1/exo1
    245    cd Unix
    246    ls
    247    cd TP1
    248    ls
    249    tree
    250    cd
    251    tree
    252    cd Pyhton/TP1
    253    cd Python/TP1
    254    cd Python
    255    cd Python/TP1/
    256    cd
    257    cd Python/TP1
    258    cd Python/TP1/
    259    cd Python
    260    ls
    261    cd Unix/TP1
    262    cd Unix
    263    cd
    264    cd Unix
    265    ls
    266    cd TP2
    267    ls
    268    cd TP1
    269    cd ../
    270    cd
    271    ls
    272    cd Unix
    273    ls
    274    cd TP2
    275    ls
    276    cd ../
    277    cd TP1
    278    ls
    279    rm -r seance2
    280    ls
    281    trecd
    282    tree
    283    *tree
    284    tree
    285    cd
    286    tree
    287    cd Python/Unix
    288    cd Python/Unix/
    289    cd Unix/TP1
    290    ls
    291    touch exo{1,2}
    292    ls
    293    cd
    294    tree
    295    sudo su -
    296    l
    297    cd Unix/TP1
    298    ls-lrt
    299    cd
    300    cd Unix
    301    ls -lrt
    302    sudo chown Exp1 TP1
    303    chown Exp1 TP1
    304    sudo chown Exp1 TP1
    305    cd
    306    sudo chown Exp1 TP1
    307    sudo chown exp1 TP1
    308    ls -lrt
    309    cat /etc/passwd
    310    sudo chown exp1 TP1
    311    sudo chown exp1 /Pthon/TP1
    312    sudo chown exp1 /TP1
    313    cat /etc/passwd | grep exp
    314    ls -lrt Unix
    315    sudo chown -R exp1 Unix/TP1
    316    ls -lrt Unix
    317    sudo chown -R exp2 Python/
    318    cd TP/
    319    cd TP1/
    320    cd TP2/
    321    sudo chown -R exp2 Python
    322    ls -lrt
    323    cd
    324    ls -lrt
    325    cdcd
    326    cd -lrt Python
    327    ls -lrt Python
    328    cd Unix/TP1/seance1
    329    cd Unix/TP2/seance1
    330    cd Unix
    331    ls
    332    cd TP1
    333    ls
    334    ls -s cd
    335    cd
    336    cd Unix/TP1/
    337    ls
    338    ls -s Unix/TP1/exo1 lien
    339    ls -s Unix/TP1/ lien
    340    cd
    341    sudo apt install zip
    342    tar -czvf system.tar.gz Unix
    343    tar -cJvf system.tar.xz Unix
    344    tar -cJvf system.tar.bz2 Unix
    345    tar -cjvf system.tar.bz2 Unix
    346    cd
    347    ls -lrt
    348    tar -czvf Unix.tar.gz
    349    tar -czvf Unix.tar.gz Unix
    350    cd
    351    ls
    352    cd Unix
    353    ls
    354    cd system
    355    cd
    356    cd system
    357    sudo cd system
    358    l
    359    cd
    360    tar -czvf Unix.tar.gz Unix
    361    tar -cxvf Unix.tar.gz Unix
    362    mkdir Python/data
    363    tar -cxvf Unix.tar.gz Python/data
    364    tar -cxvf Unix.tar.gz Python/data/
    365    su exp2
    366    sudo netsat -patune | grep ssh
    367    su - epx2
    368    su -epx2
    369    clear
    370    ssh-keygen -t rsa
    371    y
    372    ssh-keygen -t rsa
    373    ssh-copy-id -i /home/ofi03/.ssh/id_rsa.pub -p 55600 [email protected]
    374    ssh-copy-id -i /home/ofi03/.ssh/id_rsa.pub -p 55600 [email protected]
    375    ps -ef | grep tomcat
    376    cd /etc/systemd/system/
    377    vim tomcat.service
    378    sudo vim tomcat.service
    379    sudo systemctl restart tomcat.service
    380    sudo systemctl daemon-reload tomcat.service
    381    sudo systemctl daemon-reload
    382    sudo systemctl restart tomcat.service
    383    vim tomcat.service
    384    ps -ef | grep tomcat
    385    sudo cd /opt/tomcat/bin
    386    cd /opt/tomcat/bin
    387    sudo vim catalina.sh
    388    sudo vim setenv.sh
    389    sudo systemctl restart tomcat.service
    390    ps -ef | grep tomcat
    391    cd
    392    ps -ef | grep tomcat
    393    sudo systemctl status tomcat.service
    394    journalctl -u tomcat
    395    sudo journalctl -u tomcat
    396    nano /etc/systemd/system/tomcat.service
    397    sudo journalctl -u tomcat
    398    sudo systemctl restart tomcat.service
    399    ps -ef | grep tomcat
    400    journalctl -u tomcat
    401    ps -ef | grep tomcat
    402    sudo vim setenv.sh
    403    sudo systemctl daemon-reload
    404    sudo systemctl restart tomcat.service
    405    cd /opt/tomcat/bin
    406    sudo vim setenv.sh
    407    sudo systemctl restart tomcat.service
    408    ps -ef | grep tomcat
    409    sudo su -l tomcat -s /bin/bash -c 'jmap -dump:format=b, file=dump1.hprof
286223'
    410    ps -ef | grep tomcat
    411    sudo su -l tomcat -s /bin/bash -c 'jmap -dump:format=b, file=dump1.hprof
91901'
    412    sudo su -l tomcat -s /bin/bash -c 'jmap -dump:format=b,file=dump1.hprof
91901'
    413    ls -lrt
    414    cd /opt/tomcat
    415    ls -lrt
    416    cd
    417    ls -lrt
    418    cd /opt/tomcat
    419    mv dump1.hprof /home/ofi03/
    420    sudo mv dump1.hprof /home/ofi03/
    421    sudo chown ofi03:ofi03 /home/ofi03/dump1.hprof
    422    d /bin/setenv
    423    cd /bin
    424    sudo vim setenv.sh
    425    cd /bin/
    426    ls
    427    sudo vim setenv.sh
    428    cd /opt/
    429    ls-lrt
    430    ls -lrt
    431    cd /etc/postgresql/12/
    432    ls -lrt
    433    cd main
    434    ls -lrt
    435    sudo vim postgresql.conf
    436    cd
    437    cd /etc/postgresql/12/main
    438    ls -lrt
    439    sudo vim postgresql.conf
    440    cd /etc/postgresql/12/main
    441    ls -lrt
    442    sudo vim postgresql.conf
    443    ls -lrt
    444    sudo vim pg_hba.conf
    445    systemctl status postgresql
    446    ps -aux | grep postgresql
    447    pg_c
    448    sudo pg_ctlcluster 12 main status
    449    psql -h 146.59.156.114 -p 5432 postgres postgres
    450    sudo pg_ctlcluster 12 main status
    451    psql -h 146.59.156.114 -p 5432 postgres postgres
    452    systemctl restart postgresql
    453    psql -h 146.59.156.114 -p 5432 postgres postgres
    454    sudo vim pg_hba.conf
    455    psql -h 146.59.156.114 -p 5432 postgres postgres
    456    systemctl restart postgresql
    457    sudo pg_ctlcluster 12 main status
    458    psql -h 146.59.156.114 -p 5432 postgres postgres
    459    sudo su -
    460    sudo vim pg_hba.conf
    461    psql -h 146.59.156.114 -p 5432 postgres postgres
    462    sudo vim pg_hba.conf
    463    psql -h 146.59.156.114 -p 5432 postgres postgres
    464    sudo su -
    465    sudo vim pg_hba.conf
    466    cd
    467    cd /etc/postgresql/12/main/
    468    ls -lrt
    469    sudo vim pg_hba.conf
    470    cd /etc/postgresql/12/main/
    471    sudo vim pg_hba.conf
    472    cd /etc/postgresql/12/main/
    473    sudo vim pg_hba.conf
    474    sudo su -
    475    systemctl status tomcat
    476    shutdown
    477    systemctl shutdown tomcat
    478    cd /opt/tomcat
    479    ls -lrt
    480    shutdown
    481    systemctl stop tomcat
    482    systemctl status tomcat
    483    systemctl stop tomcat.service
    484    systemctl status tomcat
    485    sudo su -
    486    systemctl restart postgresql
    487    sudo su -
    488    systemctl restart postgresql
    489    systemctl status postgresql.service
    490    systemctl restart postgresql
    491    sudo su -
    492    systemctl status postgresql.service
    493    cd /etc/postgresql/12/main
    494    ls -lrt
    495    systemctl status postgresql.service
    496    sudo su -
    497    cd
    498    sudo apt install postgresql postgresql contrib
    499    sudo apt install postgresql postgresql-contrib
    500    ls -lrt
    501    cd /etc/postgresql/12/main
    502    sudo vim postgresql.conf
    503    cd
    504    sudo su -
    505    psql -h 146.59.156.114 -p 5432 postgres postgres
    506    sudo su -
    507    sudo postgresql
    508    sudo postgres
    509    sudo -    postgres
    510    sudo su -
    511    history
    512    sudo systemctl status apache2.service
    513    sudo systemctl start apache2.service
    514    sudo vim /etc/apache2/conf-available/security.conf
    515    cd /etc/apache2/sites-available
    516    ls
    517    sudo vim 01-www.secondsite.com.conf
    518    sudo vim 01-www.logwire.org.conf
    519    sudo htpasswd -c /etc/apache2/passwords Amadou
    520    sudo systemctl restart apache2.service
    521    sudo vim 01-www.logwire.org.conf
    522    sudo vim 01-www.secondsite.com.conf
    523    sudo vim 01-www.logwire.org.conf
    524    sudo vim 01-www.secondsite.com.conf
    525    sudo systemctl restart apache2.service
    526    ls
    527    cd /var/www/html/www.secondsite.com/top_secret/
    528    ls
    529    sudo vim index.html
    530    sudo systemctl restart apache2.service
    531    ls
    532    sudo vim index.html
    533    cd
    534    cd /etc/apache2/sites-available/
    535    ls -lrt
    536    sudo vim 01-www.secondsite.com.conf
    537    sudo vim 01-www.logwire.org.conf
    538    sudo vim 01-www.secondsite.com.conf
    539    sudo systemctl restart apache2.service
    540    sudo systemctl restart apache2.service
    541    sudo systemctl restart apache2.service
    542    sudo systemctl status apache2.service
    543    cd
    544    sudo systemctl status apache2
    545    sudo systemctl restart apache2.service
    546    sudo systemctl status apache2.service
    547    ss -lrtnp
    548    sudo systemctl restart apache2.service
    549    journalctl -xe
    550    sudo systemctl restart apache2.service
    551    sudo apt-get install apache2
    552    sudo systemctl status apache2.service
    553    sudo systemctl restart apache2.service
    554    sudo systemctl status apache2.service
    555    sudo systemctl status apache2.service
    556    sudo systemctl start apache2.service
    557    sudo systemctl restart apache2.service
    558    journalctl -xe
    559    sudo systemctl stop apache2.service
    560    sudo systemctl status apache2.service
    561    sudo systemctl restart apache2.service
    562    sudo apt-get install apache2
    563    sudo systemctl restart apache2.service
    564    sudo systemctl status apache2.service
    565    sudo systemctl restart apache2.service
    566    systemctl status apache2.service
    567    sudo systemctl start apache2.service
    568    systemctl status apache2.service
    569    sudo systemctl restart apache2.service
    570    sudo apt update
    571    sudo systemctl restart apache2.service
    572    sudo apt install default
    573    jdksudo apt install default
    574    sudo apt install default-jdk
    575    history
    576    cd /opt/tomcat/bin/
    577    ls
    578    ls -lrt
    579    cd ..
    580    ls -lrt
    581    cd conf
    582    ls -lrt
    583    sudo vim server.xml
    584    sudo systemctl status apache2.service
    585    sudo systemctl restart apache2.service
    586    ls -lrt
    587    sudo systemctl restart apache2.service
    588    sudo vim server.xml cd
    589    cd
    590    cd /var/www/html/www.secondsite.com/top_secret/
    591    ls
    592    sudo vim index.html
    593    cd ../../
    594    ls
    595    sudo vim index.html
    596    sudo systemctl restart apache2.service
    597    sudo systemctl start apache2.service
    598    systemctl status apache2.service
    599    journalctl -xe
    600    systemctl status apache2.service
    601    which lib
    602    systemctl stop apache2.service
    603    sudo systemctl status apache2.service
    604    ps -aux
    605    ps -aux |grep apache
    606    ss -lrtnp
    607    is-active apache-tomcat-9.0.65.tar.gz
    608    is active apache-tomcat-9.0.65.tar.gz
    609    activate apache-tomcat-9.0.65.tar.gz
    610    ss -lrtnp
    611    sudo systemctl restart apache2.service
    612    history
    613    clear
    614    history
    615    sudo systemctl restart apache2.service
    616    systemctl status apache2.service
    617    sudo systemctl restart apache2.service
    618    sudo apt-get purge apache2
    619    sudo apt-get install apache2
    620    sudo systemctl status apache2.service
    621    sudo systemctl restart apache2.service
    622    cd /etc/apache2/sites-available/
    623    ls
    624    sudo vim 01-www.secondsite.com.conf
    625    cd
    626    ls
    627    cd /var/www/html/www.secondsite.com/
    628    ls
    629    cd top_secret/
    630    ls
    631    sudo vim index.html
    632    sudo systemctl restart apache2.service
    633    cd
    634    sudo a2enmod
    635    sudo a2enmod ssl
    636    sudo systemctl restart apache2.service
    637    sudo
    638    openssl req x509 nodes days 365 newkey rsa:2048 keyout / ssl private
/apache selfsigned.key out
    639    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsign
    640    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    641    -help
    642    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    643    sudo nano /etc/apache2/sites
    644    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    645    sudo apachectl configtest
    646    sudo systemctl reload apache2.service
    647    sudo systemctl restart apache2.service
    648    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    649    sudo vim /etc/apache2/sites-available/01-www.logwire.org.conf
    650    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    651    sudo systemctl restart apache2.service
    652    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    653    sudo systemctl restart apache2.service
    654    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    655    sudo openssl -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    656    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    657    history
    658    sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout
/etc/ssl/private/apache-selfsigned.key-out /etc/ssl/certs/apache-selfsigned.crt
    659    history
    660    sudo systemctl restart apache2.service
    661    sudo vim /etc/apache2/sites-available/01-www.secondsite.com.conf
    662    sudo vim /opt/tomcat/conf/tomcat-users.xml
    663    sudo vim /opt/tomcat/conf
    664    sudo vim /opt/tomcat/conf/
    665    cd /opt/tomcat/conf/
    666    ls -lrt
    667    sudo vim logging.properties
    668    sudo vim context.xml
    669    sudo vim logging.properties
    670    cd ..
    671    ls -lrt
    672    history
    673    cd / | grep sentenv
    674    ls
    675    history | setenv
    676    cd /opt/
    677    ls
    678    cd /opt/tomcat
    679    ls
    680    cd conf
    681    ls
    682    cd ..
    683    ls
    684    cd conf
    685    ls
    686    cd
    687    ls
    688    cd ..
    689    ls
    690    cd
    691    cd /etc/
    692    ls
    693    cd systemd/system/
    694    ls
    695    cd
    696    cd /opt/tomat/
    697    cd
    698    cd /opt/tomat/
    699    cd /opt/tomcat/
    700    ls
    701    cd bin
    702    ls
    703    sudo vim setenv.sh
    704    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.git
    705    cd postgresql-tomcat/db
    706    cp init.sql /home/ubuntu
    707    sudo cp init.sql /home/ubuntu/
    708    su -postgres
    709    sudo su -postgres
    710    su - postgres
    711    sudo su - postgres
    712    su postgres
    713    sudo su postgres
    714    \q
    715    cd
    716    exit
    717    cd /opt/tomcat
    718    ls
    719    cd /opt/tomcat
    720    cd conf/
    721    ls
    722    sudo vim server.xml
    723    ls
    724    cd bin
    725    ls
    726    sudo vim setenv.sh
    727    cd /opt/systemd/
    728    cd /etc/systemd/
    729    cd system/
    730    ls
    731    sudo vim tomcat.service
    732    cd
    733    sudo vim /opt/tomcat/conf/tomcat-users.xml
    734    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.git
    735    cd postgresql-tomcat/db
    736    cp init.sql /home/ubuntu
    737    sudo cp init.sql /home/ubuntu
    738    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.git
    739    cd postgresql-tomcat/db
    740    sudo cp init.sql /home/ubuntu
    741    su -- postgres
    742    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.gitcd
    743    cd
    744    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.gitcd
    745    sudo systemctl restart postgresql
    746    sudo systemctl restart tomcat.service
    747    systemctl daemon-reload
    748    sudo systemctl daemon-reload
    749    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.gitcd
    750    git clone https://gitlab.com/houcemdevops/postgresql-tomcat.git
    751    cd postgresql-tomcat/db
    752    sudo cp init.sql /home/ubuntu
    753    su - postgres
    754    sudo su - postgres
    755    sudo vim /etc/prometheus/prometheus.yml
    756    dpkg -l apache2
    757    cd /etc/apache2/
    758    ls -lrt
    759    cd conf-available/
    760    ls -lrt
    761    cd
    762    find -Name "error.log"
    763    find -name "error.log"
    764    sudo find -name "error.log"
    765    sudo find -name "access.log"
    766    sudo find "access.log"
    767    find "access.log"
    768    sudo find "error.log"
    769    sudo find -name "error.log"
    770    sudo find -name / "error.log"
    771    sudo find -name "error.log" /
    772    cd /etc/apache2/
    773    ls -lrt
    774    sudo vim apache2.conf
    775    sudo vim conf-available/
    776    sudo vim envares
    777    cd
    778    cd /opt/tomcat/
    779    ls -lrt
    780    cd logs/
    781    ls -lrt
    782    cd catalina.out
    783    sudo vim catalina.out
    784    cd /opt/tomcat/
    785    ls -lrt
    786    cd conf/
    787    ls -lrt
    788    sudo vim server.xml
    789    sudo vim catalina.p
    790    sudo vim catalina
    791    sudo vim tomcat-users.xml
    792    sudo vim logging.properties
    793    sudo vim context.xml
    794    cd /etc/systemd/system/
    795    ls -lrt
    796    cd
    797    cd /opt/tomcat/
    798    ls -lrt
    799    cd bin
    800    ls -lrt
    801    ./version.sh
    802    cd
    803    df -h
    804    top
    805    free -h
    806    adduser oracle
    807    sudo adduser oracle
    808    id oracle
    809    sudo su - oracle
    810    sudo mkdir /opt/oracle
    811    sudo unzip instantclient-sqlplus-linux.x64-19.8.0.0.0dbru.zip -d
/opt/oracle/
    812    sudo vim ~/.profile
    813    sudo chown oracle:oracle /opt/oracle
    814    su - oracle
    815    sudo chown oracle:oracle -R /opt/oracle/instantclient_19_8
    816    sudo su - oracle
    817    sudo su - oracle
    818    sudo chown oracle:oracle -R /opt/oracle/instantclient_19_8
    819    sudo su - oracle
    820    history
    821    sqlplus ot_admin/ot_password@L0CAL_PDB1
    822    sudo su - oracle
    823    sudo apt install ansible
    824    ansible
    825    versionansible
    826    ansible --version
    827    sudo adduser ansadmin
    828    sudo nano /etc/
    829    sudo vim /etc/sudoers
    830    cd /etc/sudoers.d/
    831    sudo cd /etc/sudoers.d/
    832    cd /etc/sudoers.d/
    833    sudo su -
    834    sudo su - ansadmin
    835    sudo su - ansadmin
    836    ansible all -bm group -a "name=rennes"
    837    ansible all -bm group -a "name=rennes"
    838    sudo su - ansadmin
    839    sudo su - ansadmin
    840    ll
    841    cd projetgit/
    842    ll
    843    ssh
    844    ssh-keygen -t rsa
    845    git clone [email protected]:logwire9/projet1.git
    846    ssh-keygen -t rsa
    847    cd
    848    cat .ssh/id_rsa.pub
    849    ssh-rsa
AAAAB3NzaC1yc2EAAAADAQABAAABgQDRXIB324zopABpaxXK8QQKhwMWlILiCpMOnWZMzM5zejf2I0+eGYNGY
rva+6LjnvcmZDUHKcS+19LeNewqk3o41xzSF6r2/FkKEc0xbu7bpY5Gyzxjh0XiDMVIF                 
g3NjKBN17+9to5doSGYnbBU53IFFEhFSBr3jg2+UzzSbmW76ZNlr7wu5kD/yoROkN7eRVmfjt4PtzwK3sg8gG
EdhwDrgXlWkoYgw2BjoXtecnR27iXwFnFoMsr2By05GZ0Ap7lTdZVqsIAyBZyyAov2VJwzn/4rEu8RPjBL8 
WtGr5PCImmv0flcWiEYKY7EvDHb3e+wI8t0Bi+ExIU8ULifoOEYVXNH0mxM5RGVRFBrOFI654286qWe9PxYzi
oFJ/w8j0YqAtPKtA9E32zR9LN+cLtu7vUBrhPDFjBSNxO/+/iUR0Ig+R4mvfYWgontuICBvDQ5vC6zx9E/B 
vZsY21kopqh62KzqwsmJPe0benNsLMomNSMzh2zlKCIqJytSFIMtKk= ofi03@svl200
    850    cd projetgit/.
    851    git clone [email protected]:logwire9/projet1.git
    852    ll
    853    cd projet1/
    854    ll
    855    sudo vim conflit.txt
    856    sudo vim java.txt
    857    git add .
    858    git commit -m "ajout fichier java"
    859    git push conflit.txt
    860    git push
    861    sudo vim java.txt
    862    git add .
    863    git commit -m "modif fichier java"
    864    git push
    865    git pull
    866    sudo vim java.txt
    867    git add .
    868    git commit -m "modif fichier"
    869    git push
    870    git branch
    871    git bra
    872    git branch
    873    git branch dev
    874    git branch
    875    git checkout dev
    876    git branch
    877    ll
    878    git log --oneline
    879    git push conflit.txt
    880    sudo vim conflit.txt
    881    git add .
    882    git commit -m "modif fichier conflit"
    883    git push
    884    git push
    885    git commit -m "modif fichier conflit"
    886    git commit -m "modif fichier conflit.txt"
    887    git log --oneline --graph --decorate -all
    888    git dev --oneline --graph --decorate -all
    889    git log --oneline --graph --decorate --all
    890    git checkout master
    891    git merge dev
    892    git log --oneline --graph --decorate --all
    893    git push
    894    git log --oneline --graph --decorate --all
    895    cd ../../
    896    mkdir projetmerge
    897    cd projetmerge/
    898    git clone https://gitlab.com/logwire7/projet1.git
    899    git branch
    900    cd ..
    901    cd projetgit/
    902    mv ../projetmerge/ ..
    903    mv ../projetmerge/ .
    904    ll
    905    cd projetmerge/
    906    git branch
    907    git clone https://gitlab.com/logwire7/projet1.git
    908    git branch aaw
    909    git branch
    910    git checkout aaw
    911    git branch
    912    ll
    913    sudo vim aaw.txt
    914    git push origin aaw
    915    ll
    916    git branch
    917    cd
    918    cd projetgit/projet1/
    919    ll
    920    git
    921    git branch aaw
    922    git branch
    923    git checkout aaw
    924    ll
    925    sudo vim index.html
    926    git add .
    927    git commit -m "modif index"
    928    git push origin aaw
    929    git push origin master
    930    cd ..
    931    cd projetmerge/
    932    ll
    933    sudo vim aaw.txt
    934    ll
    935    sudo vim index.html
    936    git add .
    937    git commit -m "modif index"
    938    git push origin aaw
    939    git branch
    940    git branch aaw
    941    git branch
    942    git checkout aaw
    943    git push origin aaw
    944    git push origin master
    945    git tag
    946    ll
    947    git log --oneline
    948    git tag v1.2 45109db
    949    git log --oneline
    950    git tag v1.2 cea8cbf
    951    git push origin v1.2
    952    git tag v1.3 45109db
    953    git push origin v1.3
    954    sudo su - ansadmin
    955    history
    956    sudo su - ansadmin
    957    ll
    958    cd projetgit/
    959    ll
    960    cd
    961    sudo su - ansadmin
    962    ls
    963*
    964    ls
    965    ls -lrt
    966    cd
    967    sudo su - ansadmin
    968    history
ofi03@svl200:~$
ofi03@svl200:~$ sudo su - ansadmin
[sudo] password for ofi03:
ansadmin@svl200:~$ cd tpansible/
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles
ansadmin@svl200:~/tpansible$ ansible-galaxy init tomcat
- Role tomcat was created successfully
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles    tomcat
ansadmin@svl200:~/tpansible$ cd tomcat/
ansadmin@svl200:~/tpansible/tomcat$ tree
.
├── README.md
├── defaults
│   └── main.yml
├── files
├── handlers
│   └── main.yml
├── meta
│   └── main.yml
├── tasks
│   └── main.yml
├── templates
├── tests
│   ├── inventory
│   └── test.yml
└── vars
        └── main.yml

8 directories, 8 files
ansadmin@svl200:~/tpansible/tomcat$ rm -r ../tomcat/
ansadmin@svl200:~/tpansible/tomcat$
ansadmin@svl200:~/tpansible/tomcat$ cd ..
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles
ansadmin@svl200:~/tpansible$ cd roles/
ansadmin@svl200:~/tpansible/roles$ ls
postgres
ansadmin@svl200:~/tpansible/roles$ cp postgres/ tomcat
cp: -r not specified; omitting directory 'postgres/'
ansadmin@svl200:~/tpansible/roles$ cp -r postgres/ tomcat
ansadmin@svl200:~/tpansible/roles$ ls
postgres    tomcat
ansadmin@svl200:~/tpansible/roles$ tree
.
├── postgres
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   │   └── index.html.j2
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
└── tomcat
        ├── README.md
        ├── defaults
        │   └── main.yml
        ├── files
        ├── handlers
        │   └── main.yml
        ├── meta
        │   └── main.yml
        ├── tasks
        │   └── main.yml
        ├── templates
        │   └── index.html.j2
        ├── tests
        │   ├── inventory
        │   └── test.yml
        └── vars
                └── main.yml

18 directories, 18 files
ansadmin@svl200:~/tpansible/roles$ cd ..
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles
ansadmin@svl200:~/tpansible$ cp psql.yml tomcat.yml
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles   
tomcat.yml
ansadmin@svl200:~/tpansible$ cd roles
ansadmin@svl200:~/tpansible/roles$ ls
postgres    tomcat
ansadmin@svl200:~/tpansible/roles$ mv tomcat/ ../
ansadmin@svl200:~/tpansible/roles$ cd ..
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles    tomcat
tomcat.yml
ansadmin@svl200:~/tpansible$ mkdir roles1
ansadmin@svl200:~/tpansible$ mv -r tomcat tomcat.yml hosts_vars hosts.yml group_vars/
role
role_postgres/ roles/                  roles1/
ansadmin@svl200:~/tpansible$ mv -r tomcat tomcat.yml hosts_vars hosts.yml group_vars/
role1/
mv: invalid option -- 'r'
Try 'mv --help' for more information.
ansadmin@svl200:~/tpansible$ mv tomcat tomcat.yml hosts_vars hosts.yml group_vars/
role1/
mv: target 'role1/' is not a directory
ansadmin@svl200:~/tpansible$ mv -r tomcat tomcat.yml hosts_vars hosts.yml group_vars/
roles1/
mv: invalid option -- 'r'
Try 'mv --help' for more information.
ansadmin@svl200:~/tpansible$ mv tomcat tomcat.yml hosts_vars hosts.yml group_vars/
roles1/
ansadmin@svl200:~/tpansible$ ls
psql.yml    role_postgres    roles    roles1
ansadmin@svl200:~/tpansible$ cd roles1
ansadmin@svl200:~/tpansible/roles1$ ls
group_vars    hosts.yml    hosts_vars    tomcat    tomcat.yml
ansadmin@svl200:~/tpansible/roles1$ cp group_vars/ hosts_vars/ hosts.yml ../
cp: -r not specified; omitting directory 'group_vars/'
cp: -r not specified; omitting directory 'hosts_vars/'
ansadmin@svl200:~/tpansible/roles1$ cp -r group_vars/ hosts_vars/ hosts.yml ../
ansadmin@svl200:~/tpansible/roles1$ ls
group_vars    hosts.yml    hosts_vars    tomcat    tomcat.yml
ansadmin@svl200:~/tpansible/roles1$ cd ..
ansadmin@svl200:~/tpansible$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── psql.yml
├── role_postgres
│   ├── group_vars
│   │   └── all.yml
│   ├── hosts.yml
│   ├── psql.yml
│   └── roles
│            └── postgres
│                    ├── README.md
│                    ├── defaults
│                    │   └── main.yml
│                    ├── handlers
│                    │   └── main.yml
│                    ├── meta
│                    │   └── main.yml
│                    ├── tasks
│                    │   └── main.yml
│                    ├── templates
│                    │   └── index.html.j2
│                    ├── tests
│                    │   ├── inventory
│                    │   └── test.yml
│                    └── vars
│                            └── main.yml
├── roles
│   └── postgres
│            ├── README.md
│            ├── defaults
│            │   └── main.yml
│            ├── files
│            ├── handlers
│            │   └── main.yml
│            ├── meta
│            │   └── main.yml
│            ├── tasks
│            │   └── main.yml
│            ├── templates
│            │   └── index.html.j2
│            ├── tests
│            │   ├── inventory
│            │   └── test.yml
│            └── vars
│                    └── main.yml
└── roles1
        ├── group_vars
        │   └── all.yml
        ├── hosts.yml
        ├── hosts_vars
        ├── tomcat
        │   ├── README.md
        │   ├── defaults
        │   │   └── main.yml
        │   ├── files
        │   ├── handlers
        │   │   └── main.yml
        │   ├── meta
        │   │   └── main.yml
        │   ├── tasks
        │   │   └── main.yml
        │   ├── templates
        │   │   └── index.html.j2
        │   ├── tests
        │   │   ├── inventory
        │   │   └── test.yml
        │   └── vars
        │            └── main.yml
        └── tomcat.yml

35 directories, 36 files
ansadmin@svl200:~/tpansible$
ansadmin@svl200:~/tpansible$ ls
group_vars    hosts.yml    hosts_vars    psql.yml    role_postgres    roles    roles1
ansadmin@svl200:~/tpansible$ cd roles1
ansadmin@svl200:~/tpansible/roles1$ ls
group_vars    hosts.yml    hosts_vars    tomcat    tomcat.yml
ansadmin@svl200:~/tpansible/roles1$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── tomcat
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   │   └── index.html.j2
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
└── tomcat.yml
11 directories, 12 files
ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/templates/main.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/handlers/main.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/vars/main.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim group_vars/main.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim group_vars/all.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat.yml
ansadmin@svl200:~/tpansible/roles1$ ansible-playbook tomcat.yml
ERROR! Syntax Error while loading YAML.
    did not find expected '-' indicator

The error appears to be in '/home/ansadmin/tpansible/roles1/tomcat/tasks/main.yml':


line 7, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

    - name: install JDK 11


    ^ here
ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml
ansadmin@svl200:~/tpansible/roles1$ ansible-playbook tomcat.yml

PLAY [install postgres]


*************************************************************************************
*********************************

TASK [Gathering Facts]


*************************************************************************************
**********************************
ok: [146.59.158.16]

TASK [tomcat : Update and upgrade apt packages]


*************************************************************************************
*********
[WARNING]: The value True (type bool) in a string field was converted to 'True' (type
string). If this does not look like what you expect,
quote the entire value to ensure it does not change.
changed: [146.59.158.16]

TASK [tomcat : install JDK 11]


*************************************************************************************
**************************
ok: [146.59.158.16]

TASK [tomcat : add tomcat group]


*************************************************************************************
************************
changed: [146.59.158.16]

TASK [tomcat : add tomcat user]


*************************************************************************************
*************************
changed: [146.59.158.16]

TASK [tomcat : create /opt/tomcat directory]


*************************************************************************************
************
changed: [146.59.158.16]

TASK [tomcat : download & unarchive]


*************************************************************************************
********************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Failure downloading
http://apache.cs.utah.edu/tomcat/tomcat-9/v9.0.16/bin/apache                         
-tomcat-9.0.16.tar.gz, HTTP Error 404: Not Found"}

PLAY RECAP
*************************************************************************************
**********************************************
146.59.158.16                            : ok=6      changed=4      unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml


ansadmin@svl200:~/tpansible/roles1$ ansible-playbook tomcat.yml

PLAY [install postgres]


*************************************************************************************
*********************************

TASK [Gathering Facts]


*************************************************************************************
**********************************
ok: [146.59.158.16]

TASK [tomcat : Update and upgrade apt packages]


*************************************************************************************
*********
[WARNING]: The value True (type bool) in a string field was converted to 'True' (type
string). If this does not look like what you expect,
quote the entire value to ensure it does not change.
ok: [146.59.158.16]

TASK [tomcat : install JDK 11]


*************************************************************************************
**************************
ok: [146.59.158.16]

TASK [tomcat : add tomcat group]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [tomcat : add tomcat user]


*************************************************************************************
*************************
ok: [146.59.158.16]

TASK [tomcat : create /opt/tomcat directory]


*************************************************************************************
************
ok: [146.59.158.16]

TASK [tomcat : download & unarchive]


*************************************************************************************
********************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Failure downloading
http://apache.cs.utah.edu/tomcat/tomcat-9/v9.0.16/bin/apache                         
-tomcat-9.0.16.tar.gz, HTTP Error 404: Not Found"}

PLAY RECAP
*************************************************************************************
**********************************************
146.59.158.16                            : ok=6      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml


ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml
ansadmin@svl200:~/tpansible/roles1$ $ ansible-playbook -i hosts tomcat.yml
$: command not found
ansadmin@svl200:~/tpansible/roles1$ $ ansible-playbook -i hosts.yml tomcat.yml
$: command not found
ansadmin@svl200:~/tpansible/roles1$ $ ansible-playbook tomcat.yml
$: command not found
ansadmin@svl200:~/tpansible/roles1$ ansible-playbook tomcat.yml

PLAY [install postgres]


*************************************************************************************
*********************************

TASK [Gathering Facts]


*************************************************************************************
**********************************
ok: [146.59.158.16]

TASK [tomcat : Update and upgrade apt packages]


*************************************************************************************
*********
[WARNING]: The value True (type bool) in a string field was converted to 'True' (type
string). If this does not look like what you expect,
quote the entire value to ensure it does not change.
ok: [146.59.158.16]

TASK [tomcat : install JDK 11]


*************************************************************************************
**************************
ok: [146.59.158.16]

TASK [tomcat : add tomcat group]


*************************************************************************************
************************
ok: [146.59.158.16]

TASK [tomcat : add tomcat user]


*************************************************************************************
*************************
ok: [146.59.158.16]

TASK [tomcat : create /opt/tomcat directory]


*************************************************************************************
************
ok: [146.59.158.16]

TASK [tomcat : download & unarchive]


*************************************************************************************
********************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Failure downloading
http://apache.cs.utah.edu/tomcat/tomcat-9/v9.0.16/bin/apache                         
-tomcat-9.0.16.tar.gz, HTTP Error 404: Not Found"}

PLAY RECAP
*************************************************************************************
**********************************************
146.59.158.16                            : ok=6      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible/roles1$ ansible-playbook -i hosts.yml tomcat.yml

PLAY [install postgres]


*************************************************************************************
*********************************

TASK [Gathering Facts]


*************************************************************************************
**********************************
ok: [client1]

TASK [tomcat : Update and upgrade apt packages]


*************************************************************************************
*********
[WARNING]: The value True (type bool) in a string field was converted to 'True' (type
string). If this does not look like what you expect,
quote the entire value to ensure it does not change.
ok: [client1]

TASK [tomcat : install JDK 11]


*************************************************************************************
**************************
ok: [client1]

TASK [tomcat : add tomcat group]


*************************************************************************************
************************
ok: [client1]

TASK [tomcat : add tomcat user]


*************************************************************************************
*************************
ok: [client1]

TASK [tomcat : create /opt/tomcat directory]


*************************************************************************************
************
ok: [client1]

TASK [tomcat : download & unarchive]


*************************************************************************************
********************
fatal: [client1]: FAILED! => {"changed": false, "msg": "Failure downloading
http://apache.cs.utah.edu/tomcat/tomcat-9/v9.0.16/bin/apache-tomca                   
t-9.0.16.tar.gz, HTTP Error 404: Not Found"}

PLAY RECAP
*************************************************************************************
**********************************************
client1                                        : ok=6      changed=0       
unreachable=0        failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible/roles1$
ansadmin@svl200:~/tpansible/roles1$ ansible-playbook -i hosts.yml tomcat.yml

PLAY [install postgres]


*************************************************************************************
*********************************

TASK [Gathering Facts]


*************************************************************************************
**********************************
ok: [client1]

TASK [tomcat : Update and upgrade apt packages]


*************************************************************************************
*********
[WARNING]: The value True (type bool) in a string field was converted to 'True' (type
string). If this does not look like what you expect,
quote the entire value to ensure it does not change.
ok: [client1]

TASK [tomcat : install JDK 11]


*************************************************************************************
**************************
ok: [client1]

TASK [tomcat : add tomcat group]


*************************************************************************************
************************
ok: [client1]

TASK [tomcat : add tomcat user]


*************************************************************************************
*************************
ok: [client1]

TASK [tomcat : create /opt/tomcat directory]


*************************************************************************************
************
ok: [client1]

TASK [tomcat : download & unarchive]


*************************************************************************************
********************
fatal: [client1]: FAILED! => {"changed": false, "msg": "Failure downloading
http://apache.cs.utah.edu/tomcat/tomcat-9/v9.0.16/bin/apache-tomca                   
t-9.0.16.tar.gz, HTTP Error 404: Not Found"}

PLAY RECAP
*************************************************************************************
**********************************************
client1                                        : ok=6      changed=0       
unreachable=0        failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible/roles1$ sudo vim hosts.yml


ansadmin@svl200:~/tpansible/roles1$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── tomcat
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   │   └── index.html.j2
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
└── tomcat.yml

11 directories, 12 files
ansadmin@svl200:~/tpansible/roles1$ sudo vim hosts.yml
ansadmin@svl200:~/tpansible/roles1$ sudo vim group_vars/all.yml
ansadmin@svl200:~/tpansible/roles1$ cd
ansadmin@svl200:~$ cat .ssh/
id_rsa              id_rsa.pub      known_hosts
ansadmin@svl200:~$ cat .ssh/known_hosts
|1|RVVdjR0l/PNc9uQtwHvh8wChn74=|qaOQ1MbunrHtMa1/JHNrG9YMgkA= ecdsa-sha2-nistp256
AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBOn8ceAE4                       
EDAWwmXkogeKexuv0b82zK+3VenUUR8P2cicoaQSsQ83fldYHzqhVSP5x98ZhqkHaHMgBkSMZY8rBQ=
|1|yH6mRVh7VbDKKf+RzUKEpvtxLQE=|x7Vrxym8rZqA86xoD7+2tFzW5fs= ecdsa-sha2-nistp256
AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBI/DltbME                       
I4mx39YGnOyDuwfMsI0a4+UzPIcDIB5BPxI0o5sj1ih/x5dFcEV97lpOtwDf36oTm2L+7kjomYRfv0=
|1|8qnhZ1lMwFyptzzeZNXUBKXLZRo=|1qgR6JWO3e0cdcdbcyEe0Bem+AU= ecdsa-sha2-nistp256
AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBOn8ceAE4                       
EDAWwmXkogeKexuv0b82zK+3VenUUR8P2cicoaQSsQ83fldYHzqhVSP5x98ZhqkHaHMgBkSMZY8rBQ=
|1|bUTvvb+ASxW5/PBY0gTe84rR6yE=|xYQPo3dV3CDjDz4Ggx9uKlapH38= ecdsa-sha2-nistp256
AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBI/DltbME                       
I4mx39YGnOyDuwfMsI0a4+UzPIcDIB5BPxI0o5sj1ih/x5dFcEV97lpOtwDf36oTm2L+7kjomYRfv0=
|1|euO5ysYD6dgRDVJGHrYdCICMDAo=|xlE5RAwFDRGNV05CO6SBp+9jytU= ecdsa-sha2-nistp256
AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBG8PqcXsS                       
h5Vvwivd1pQOPOLalsVxzMqJYhflwpyK1oYSR/oqbA4cCbBmZa8D9zWU/m6E/2Xytm2sA3VBOzONlw=
|1|LUKyysrrI5CJEWLBy6YfGWBVaao=|cy70o20KxHND15WCQrdJxKqsAq4= ecdsa-sha2-nistp256
AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBFSMqzJeV                       
9rUzU4kWitGjeR4PWSa29SPqJ1fVkhtj3Hw9xjLVXVYrU9QlYWrOLXBpQ6KWjbjTDTdDkoohFzgbEY=
|1|RT26KX64H7b/dkbyt7/9GvUeiEQ=|2JFdtSYjZuhqKInvEmdmf+9A/mA= ecdsa-sha2-nistp256
AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBFSMqzJeV                       
9rUzU4kWitGjeR4PWSa29SPqJ1fVkhtj3Hw9xjLVXVYrU9QlYWrOLXBpQ6KWjbjTDTdDkoohFzgbEY=
ansadmin@svl200:~$ pwd
/home/ansadmin
ansadmin@svl200:~$ cat /home/ansadmin/.ssh/known_hosts ^C
ansadmin@svl200:~$ sudo vim group_vars/all.yml
ansadmin@svl200:~$ cd tpansible/
.git/                    group_vars/        hosts_vars/        role_postgres/ roles/ 
roles1/
ansadmin@svl200:~$ cd tpansible/role
role_postgres/ roles/                  roles1/
ansadmin@svl200:~$ cd tpansible/roles1/
group_vars/ hosts_vars/ tomcat/
ansadmin@svl200:~$ cd tpansible/roles1/group_vars/
ansadmin@svl200:~/tpansible/roles1/group_vars$ sudo vim all.yml
ansadmin@svl200:~/tpansible/roles1/group_vars$
ansadmin@svl200:~/tpansible/roles1/group_vars$ cd ..
ansadmin@svl200:~/tpansible/roles1$ tree
.
├── group_vars
│   └── all.yml
├── hosts.yml
├── hosts_vars
├── tomcat
│   ├── README.md
│   ├── defaults
│   │   └── main.yml
│   ├── files
│   ├── handlers
│   │   └── main.yml
│   ├── meta
│   │   └── main.yml
│   ├── tasks
│   │   └── main.yml
│   ├── templates
│   │   └── index.html.j2
│   ├── tests
│   │   ├── inventory
│   │   └── test.yml
│   └── vars
│            └── main.yml
└── tomcat.yml

11 directories, 12 files
ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml
ansadmin@svl200:~/tpansible/roles1$ ansible-playbook tomcat.yml

PLAY [install postgres]


*************************************************************************************
***********************************************************

TASK [Gathering Facts]


*************************************************************************************
************************************************************
ok: [146.59.158.16]

TASK [tomcat : Update and upgrade apt packages]


*************************************************************************************
***********************************
[WARNING]: The value True (type bool) in a string field was converted to 'True' (type
string). If this does not look like what you expect, quote the entire value to
ensure it does not change.
ok: [146.59.158.16]

TASK [tomcat : install JDK 11]


*************************************************************************************
****************************************************
ok: [146.59.158.16]

TASK [tomcat : add tomcat group]


*************************************************************************************
**************************************************
ok: [146.59.158.16]

TASK [tomcat : add tomcat user]


*************************************************************************************
***************************************************
ok: [146.59.158.16]

TASK [tomcat : create /opt/tomcat directory]


*************************************************************************************
**************************************
ok: [146.59.158.16]

TASK [tomcat : download & unarchive]


*************************************************************************************
**********************************************
fatal: [146.59.158.16]: FAILED! => {"changed": false, "msg": "Failure downloading
https://downloads.apache.org/tomcat/tomcat-10/v10.0.16/bin/apache-tomcat-
10.0.16.tar.g                                                                       
z, HTTP Error 404: Not Found"}
PLAY RECAP
*************************************************************************************
************************************************************************
146.59.158.16                            : ok=6      changed=0        unreachable=0 
failed=1      skipped=0        rescued=0        ignored=0

ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml


ansadmin@svl200:~/tpansible/roles1$ sudo vim tomcat/tasks/main.yml
ansadmin@svl200:~/tpansible/roles1$ cd /bin
ansadmin@svl200:/bin$ ls
NF                                                                        ntfsfix
VGAuthService                                                  ntfsinfo
X11                                                                      ntfsls
'['                                                                        ntfsmove
aa-enabled                                                        ntfsrecover
aa-exec                                                              ntfssecaudit
ab                                                                       
ntfstruncate
activate-global-python-argcomplete3      ntfsusermap
add-apt-repository                                        ntfswipe
addpart                                                              numfmt
ansible                                                              oclock
ansible-config                                                od
ansible-connection                                        oem-getlogs
ansible-console                                              on_ac_power
ansible-doc                                                      openssl
ansible-galaxy                                                openvt
ansible-inventory                                          os-prober
ansible-playbook                                            pack200
ansible-pull                                                    pager
ansible-vault                                                  parallel
apport-bug                                                        partx
apport-cli                                                        passwd
apport-collect                                                paste
apport-unpack                                                  pastebinit
appres                                                                patch
apropos                                                              pathchk
apt                                                                      pbget
apt-add-repository                                        pbput
apt-cache                                                          pbputs
apt-cdrom                                                          pdb3
apt-config                                                        pdb3.8
apt-extracttemplates                                    pee
apt-ftparchive                                                peekfd
apt-get                                                              perl
apt-key                                                              perl5.30-
x86_64-linux-gnu
apt-mark                                                            perl5.30.0
apt-sortpkgs                                                    perlbug
arch                                                                    perldoc
at                                                                        perlivp
atobm                                                                  perlthanks
atq                                                                      pftp
atrm                                                                   
pg_archivecleanup
automat-visualize3                                        pg_basebackup
awk                                                                      pg_buildext
b2sum                                                                  pg_config
base32                                                                pg_conftool
base64                                                               
pg_createcluster
basename                                                            pg_ctlcluster
bash                                                                   
pg_dropcluster
bashbug                                                              pg_dump
batch                                                                  pg_dumpall
bc                                                                        pg_isready
bitmap                                                                pg_lsclusters
bmtoa                                                                  pg_receivewal
boltctl                                                              pg_receivexlog
bootctl                                                              pg_recvlogical
bsd-from                                                            pg_renamecluster
bsd-write                                                          pg_restore
btrfs                                                                 
pg_upgradecluster
btrfs-convert                                                  pg_virtualenv
btrfs-find-root                                              pgbench
btrfs-image                                                      pgrep
btrfs-map-logical                                          pic
btrfs-select-super                                        pico
btrfsck                                                              piconv
btrfstune                                                          pidof
bunzip2                                                              pidstat
busctl                                                                pinentry
busybox                                                              pinentry-curses
byobu                                                                  ping
byobu-config                                                    ping4
byobu-ctrl-a                                                    ping6
byobu-disable                                                  pinky
byobu-disable-prompt                                    pkaction
byobu-enable                                                    pkcheck
byobu-enable-prompt                                      pkcon
byobu-export                                                    pkexec
byobu-janitor                                                  pkill
byobu-keybindings                                          pkmon
byobu-launch                                                    pkttyagent
byobu-launcher                                                pl2pm
byobu-launcher-install                                pldd
byobu-launcher-uninstall                            plymouth
byobu-layout                                                    pmap
byobu-prompt                                                    pod2html
byobu-quiet                                                      pod2man
byobu-reconnect-sockets                              pod2text
byobu-screen                                                    pod2usage
byobu-select-backend                                    podchecker
byobu-select-profile                                    podselect
byobu-select-session                                    pollinate
byobu-shell                                                      pr
byobu-silent                                                    preconv
byobu-status                                                    print
byobu-status-detail                                      printenv
byobu-tmux                                                        printerbanner
byobu-ugraph                                                    printf
byobu-ulevel                                                    prlimit
bzcat                                                                  prometheus
bzcmp                                                                  prometheus-
node-exporter
bzdiff                                                                promtool
bzegrep                                                              prove
bzexe                                                                  prtstat
bzfgrep                                                              ps
bzgrep                                                                psfaddtable
bzip2                                                                  psfgettable
bzip2recover                                                    psfstriptable
bzless                                                                psfxtable
bzmore                                                                pslog
c_rehash                                                            psql
cal                                                                      pstree
calendar                                                            pstree.x11
captoinfo                                                          ptar
cat                                                                      ptardiff
catchsegv                                                          ptargrep
catman                                                                ptx
cautious-launcher                                          purge-old-kernels
cftp3                                                                  pwd
chage                                                                  pwdx
chardet3                                                            py3clean
chardetect3                                                      py3compile
chattr                                                                py3versions
chcon                                                                  pydoc3
check-language-support                                pydoc3.8
checkgid                                                            pygettext3
chfn                                                                    pygettext3.8
chgrp                                                                  pyhtmlizer3
chmod                                                                  pyjwt3
choom                                                                  python-
argcomplete-check-easy-install-script3
chown                                                                  python-
argcomplete-tcsh3
chronic                                                              python3
chrt                                                                    python3.8
chsh                                                                    rbash
chvt                                                                    rcp
cifsiostat                                                        rdma
ckbcomp                                                              readlink
ckeygen3                                                            realpath
cksum                                                                  red
clear                                                                  register-
python-argcomplete3
clear_console                                                  reindexdb
cloud-id                                                            rename.ul
cloud-init                                                        rendercheck
cloud-init-per                                                renice
clusterdb                                                          rescan-scsi-
bus.sh
cmp                                                                      reset
codepage                                                            resizecons
col                                                                      resizepart
col1                                                                    resolvectl
col2                                                                    rev
col3                                                                    rgrep
col4                                                                    rlogin
col5                                                                    rm
col6                                                                    rmdir
col7                                                                    rmic
col8                                                                    rmid
col9                                                                    rmiregistry
colcrt                                                                rnano
colrm                                                                  rotatelogs
column                                                                routef
combine                                                              routel
comm                                                                    rrsync
compose                                                              rsh
conch3                                                                rsync
corelist                                                            rtstat
cp                                                                        run-
mailcap
cpan                                                                    run-one
cpan5.30-x86_64-linux-gnu                          run-one-constantly
cpio                                                                    run-one-
until-failure
createdb                                                            run-one-until-
success
createlang                                                        run-parts
createuser                                                        run-this-one
crontab                                                              runcon
csplit                                                                rview
ctail                                                                  rvim
ctstat                                                                sadf
curl                                                                    sar
cut                                                                      sar.sysstat
cvtsudoers                                                        savelog
dash                                                                    sbattach
date                                                                    sbkeysync
dbus-cleanup-sockets                                    sbsiglist
dbus-daemon                                                      sbsign
dbus-monitor                                                    sbvarsign
dbus-run-session                                            sbverify
dbus-send                                                          scp
dbus-update-activation-environment        screen
dbus-uuidgen                                                    screendump
dbxtool                                                              script
dd                                                                       
scriptreplay
deallocvt                                                         
scsi_logging_level
deb-systemd-helper                                        scsi_mandat
deb-systemd-invoke                                        scsi_readcap
debconf                                                              scsi_ready
debconf-apt-progress                                    scsi_satl
debconf-communicate                                      scsi_start
debconf-copydb                                                scsi_stop
debconf-escape                                                scsi_temperature
debconf-set-selections                                sdiff
debconf-show                                                    sed
debian-distro-info                                        see
delpart                                                              select-editor
delv                                                                    sensible-
browser
df                                                                        sensible-
editor
dfu-tool                                                            sensible-pager
dh_bash-completion                                        seq
diff                                                                    serialver
diff3                                                                  setarch
dig                                                                      seten.sh
dir                                                                      setenv.sh
dircolors                                                          setfont
dirmngr                                                              setkeycodes
dirmngr-client                                                setleds
dirname                                                              setlogcons
distro-info                                                      setmetamode
dmesg                                                                  setpci
dnsdomainname                                                  setpriv
do-release-upgrade                                        setsid
domainname                                                        setterm
dpkg                                                                    setupcon
dpkg-deb                                                            sftp
dpkg-divert                                                      sg
dpkg-maintscript-helper                              sg_bg_ctl
dpkg-query                                                       
sg_compare_and_write
dpkg-split                                                        sg_copy_results
dpkg-statoverride                                          sg_dd
dpkg-trigger                                                    sg_decode_sense
dropdb                                                               
sg_emc_trespass
droplang                                                            sg_format
dropuser                                                            sg_get_config
du                                                                       
sg_get_lba_status
dumpkeys                                                            sg_ident
eatmydata                                                          sg_inq
ec2metadata                                                      sg_logs
echo                                                                    sg_luns
ed                                                                        sg_map
edit                                                                    sg_map26
editor                                                                sg_modes
editres                                                              sg_opcodes
efibootdump                                                      sg_persist
efibootmgr                                                        sg_prevent
egrep                                                                  sg_raw
eject                                                                  sg_rbuf
enc2xs                                                                sg_rdac
encguess                                                            sg_read
env                                                                     
sg_read_attr
envsubst                                                           
sg_read_block_limits
eqn                                                                     
sg_read_buffer
errno                                                                  sg_read_long
ex                                                                        sg_readcap
expand                                                                sg_reassign
expiry                                                                sg_referrals
expr                                                                    sg_rep_zones
factor                                                                sg_requests
faillog                                                              sg_reset
fallocate                                                          sg_reset_wp
false                                                                  sg_rmsn
fcgistarter                                                      sg_rtpg
fgconsole                                                          sg_safte
fgrep                                                                  sg_sanitize
file                                                                   
sg_sat_identify
finalrd                                                             
sg_sat_phy_event
fincore                                                             
sg_sat_read_gplog
find                                                                   
sg_sat_set_features
findmnt                                                              sg_scan
flock                                                                  sg_seek
fmt                                                                      sg_senddiag
fold                                                                    sg_ses
free                                                                   
sg_ses_microcode
from                                                                    sg_start
ftp                                                                      sg_stpg
funzip                                                                sg_stream_ctl
fuser                                                                  sg_sync
fusermount                                                        sg_test_rwbuf
fwupdagent                                                        sg_timestamp
fwupdate                                                            sg_turs
fwupdmgr                                                            sg_unmap
fwupdtool                                                          sg_verify
gapplication                                                    sg_vpd
gawk                                                                    sg_wr_mode
gdbus                                                                 
sg_write_buffer
geqn                                                                   
sg_write_long
getconf                                                              sg_write_same
getent                                                               
sg_write_verify
getkeycodes                                                      sg_write_x
getopt                                                                sg_xcopy
gettext                                                              sg_zone
gettext.sh                                                        sginfo
ginstall-info                                                  sgm_dd
gio                                                                      sgp_dd
gio-querymodules                                            sh
git                                                                      sha1sum
git-receive-pack                                            sha224sum
git-shell                                                          sha256sum
git-upload-archive                                        sha384sum
git-upload-pack                                              sha512sum
glib-compile-schemas                                    shasum
gpasswd                                                              showconsolefont
gpg                                                                      showkey
gpg-agent                                                          shred
gpg-connect-agent                                          shuf
gpg-wks-server                                                skill
gpg-zip                                                              slabtop
gpgcompose                                                        sleep
gpgconf                                                              slogin
gpgparsemail                                                    snap
gpgsm                                                                  snapctl
gpgsplit                                                            snapfuse
gpgtar                                                                snice
gpgv                                                                    soelim
gpic                                                                    sort
grep                                                                    sos
gresource                                                          sos-collector
groff                                                                  sosreport
grog                                                                    splain
grops                                                                  split
grotty                                                                splitfont
groups                                                                sponge
growpart                                                            ss
grub-editenv                                                    ssh
grub-file                                                          ssh-add
grub-fstest                                                      ssh-agent
grub-glue-efi                                                  ssh-argv0
grub-kbdcomp                                                    ssh-copy-id
grub-menulst2cfg                                            ssh-import-id
grub-mkfont                                                      ssh-import-id-gh
grub-mkimage                                                    ssh-import-id-lp
grub-mklayout                                                  ssh-keygen
grub-mknetdir                                                  ssh-keyscan
grub-mkpasswd-pbkdf2                                    stat
grub-mkrelpath                                                static-sh
grub-mkrescue                                                  stdbuf
grub-mkstandalone                                          strace
grub-mount                                                        strace-log-merge
grub-ntldr-img                                                stty
grub-render-label                                          su
grub-script-check                                          sudo
grub-syslinux2cfg                                          sudoedit
gsettings                                                          sudoreplay
gtbl                                                                    sum
gunzip                                                                symcryptrun
gzexe                                                                  sync
gzip                                                                    systemctl
h2ph                                                                    systemd
h2xs                                                                    systemd-
analyze
hd                                                                        systemd-
ask-password
head                                                                    systemd-cat
helpztags                                                          systemd-cgls
hexdump                                                              systemd-cgtop
host                                                                    systemd-
delta
hostid                                                                systemd-
detect-virt
hostname                                                            systemd-escape
hostnamectl                                                      systemd-hwdb
htcacheclean                                                    systemd-id128
htdbm                                                                  systemd-
inhibit
htdigest                                                            systemd-machine-
id-setup
htop                                                                    systemd-
mount
htpasswd                                                            systemd-notify
hwe-support-status                                        systemd-path
i386                                                                    systemd-
resolve
ico                                                                      systemd-run
iconv                                                                  systemd-
socket-activate
id                                                                        systemd-
stdio-bridge
ifdata                                                                systemd-
sysusers
ifne                                                                    systemd-
tmpfiles
info                                                                    systemd-tty-
ask-password-agent
infobrowser                                                      systemd-umount
infocmp                                                              tabs
infotocap                                                          tac
install                                                              tail
install-info                                                    tapestat
instmodsh                                                          tar
ionice                                                                taskset
iostat                                                                tbl
ip                                                                        tee
ipcmk                                                                  telnet
ipcrm                                                                  telnet.netkit
ipcs                                                                    tempfile
iptables-xml                                                    test
ischroot                                                            tic
iscsiadm                                                            time
isutf8                                                                timedatectl
jaotc                                                                  timeout
jar                                                                      tkconch3
jarsigner                                                          tload
java                                                                    tmux
javac                                                                  toe
javadoc                                                              top
javap                                                                  touch
jcmd                                                                    tput
jconsole                                                            tr
jdb                                                                      tracepath
jdeprscan                                                          traceroute6
jdeps                                                                 
traceroute6.iputils
jexec                                                                  transset
jfr                                                                      trial3
jhsdb                                                                  troff
jimage                                                                true
jinfo                                                                  truncate
jjs                                                                      ts
jlink                                                                  tsdb
jmap                                                                    tset
jmod                                                                    tsort
join                                                                    tty
journalctl                                                        twist3
jps                                                                      twistd3
jrunscript                                                        tzselect
js                                                                        ua
jshell                                                                ubuntu-
advantage
json_pp                                                              ubuntu-bug
jsondiff                                                            ubuntu-core-
launcher
jsonpatch                                                          ubuntu-distro-
info
jsonpatch-jsondiff                                        ubuntu-security-status
jsonpointer                                                      ucf
jsonschema                                                        ucfq
jstack                                                                ucfr
jstat                                                                  udevadm
jstatd                                                                udisksctl
kbd_mode                                                            ul
kbdinfo                                                              ulockmgr_server
kbxutil                                                              umount
keep-one-running                                            uname
kernel-install                                                unattended-upgrade
keyring                                                              unattended-
upgrades
keytool                                                              uncompress
kill                                                                    unexpand
killall                                                              unicode_start
kmod                                                                    unicode_stop
kmodsign                                                            uniq
landscape-sysinfo                                          unlink
last                                                                    unlz4
lastb                                                                  unlzma
lastlog                                                              unmkinitramfs
lcf                                                                      unpack200
lckdo                                                                  unshare
ldd                                                                      unsquashfs
less                                                                    unxz
lessecho                                                            unzip
lessfile                                                            unzipsfx
lesskey                                                              update-
alternatives
lesspipe                                                            update-mime-
database
lexgrog                                                              updatedb
libnetcfg                                                          updatedb.mlocate
link                                                                    uptime
linux-boot-prober                                          usb-devices
linux-check-removal                                      usbhid-dump
linux-update-symlinks                                  usbreset
linux-version                                                  users
linux32                                                              utmpdump
linux64                                                              uuidgen
listres                                                              uuidparse
ln                                                                        vacuumdb
lnstat                                                                vacuumlo
loadkeys                                                            vcs-run
loadunimap                                                        vdir
locale                                                                vi
locale-check                                                    vidir
localectl                                                          view
localedef                                                          viewres
locate                                                                vigpg
logger                                                                vim
login                                                                  vim.basic
loginctl                                                            vim.tiny
logname                                                              vimdiff
logresolve                                                        vimtutor
look                                                                    vipe
lorder                                                                vm-support
lowntfs-3g                                                        vmhgfs-fuse
ls                                                                        vmstat
lsattr                                                                vmtoolsd
lsb_release                                                      vmware-alias-import
lsblk                                                                  vmware-
checkvm
lscpu                                                                  vmware-
hgfsclient
lshw                                                                    vmware-
namespace-cmd
lsinitramfs                                                      vmware-rpctool
lsipc                                                                  vmware-
toolbox-cmd
lslocks                                                              vmware-vgauth-
cmd
lslogins                                                            vmware-vmblock-
fuse
lsmem                                                                  vmware-
xferlogs
lsmod                                                                  volname
lsns                                                                    w
lsof                                                                    w.procps
lspci                                                                  wall
lspgpot                                                              watch
lsusb                                                                  watchgnupg
ltrace                                                                wc
luit                                                                    wdctl
lz4                                                                      wget
lz4c                                                                    whatis
lz4cat                                                                whereis
lzcat                                                                  which
lzcmp                                                                  whiptail
lzdiff                                                                who
lzegrep                                                              whoami
lzfgrep                                                              wifi-status
lzgrep                                                                write
lzless                                                                x11perf
lzma                                                                    x11perfcomp
lzmainfo                                                            x86_64
lzmore                                                                xargs
mailmail3                                                          xauth
man                                                                      xbiff
man-recode                                                        xcalc
mandb                                                                  xclipboard
manifest                                                            xclock
manpath                                                              xconsole
mapscrn                                                              xcursorgen
mawk                                                                    xcutsel
mcookie                                                              xdg-user-dir
md5sum                                                                xdg-user-dirs-
update
md5sum.textutils                                            xditview
mdig                                                                    xdpyinfo
mesa-overlay-control.py                              xdriinfo
mesg                                                                    xedit
migrate-pubring-from-classic-gpg            xev
miniterm                                                            xeyes
mispipe                                                              xfd
mk_modmap                                                          xfontsel
mkdir                                                                  xgc
mkfifo                                                                xkill
mknod                                                                  xload
mksquashfs                                                        xlogo
mktemp                                                                xlsatoms
mlocate                                                              xlsclients
mmcli                                                                  xlsfonts
mokutil                                                              xmag
more                                                                    xman
mount                                                                  xmessage
mountpoint                                                        xmore
mpstat                                                                xprop
mt                                                                        xsubpp
mt-gnu                                                                xvinfo
mtr                                                                      xwd
mtr-packet                                                        xwininfo
mv                                                                        xwud
namei                                                                  xxd
nano                                                                    xz
nawk                                                                    xzcat
nc                                                                        xzcmp
nc.openbsd                                                        xzdiff
ncal                                                                    xzegrep
neqn                                                                    xzfgrep
netcat                                                                xzgrep
netkit-ftp                                                        xzless
networkctl                                                        xzmore
networkd-dispatcher                                      yes
newgrp                                                                ypdomainname
ngettext                                                            zcat
nice                                                                    zcmp
nisdomainname                                                  zdiff
nl                                                                        zdump
node                                                                    zegrep
nodejs                                                                zfgrep
nohup                                                                  zforce
nproc                                                                  zgrep
nroff                                                                  zip
nsenter                                                              zipcloak
nslookup                                                            zipdetails
nstat                                                                  zipgrep
nsupdate                                                            zipinfo
ntfs-3g                                                              zipnote
ntfs-3g.probe                                                  zipsplit
ntfscat                                                              zless
ntfscluster                                                      zmore
ntfscmp                                                              znew
ntfsdecrypt                                                      zrun
ntfsfallocate
ansadmin@svl200:/bin$ ls -lrt
total 193204
-rwxr-xr-x 1 root      root                3592 Jan 15    2014    run-one
lrwxrwxrwx 1 root      root                      7 Jan 15    2014    run-this-one ->
run-one
lrwxrwxrwx 1 root      root                      7 Jan 15    2014    run-one-until-
success -> run-one
lrwxrwxrwx 1 root      root                      7 Jan 15    2014    run-one-until-
failure -> run-one
lrwxrwxrwx 1 root      root                      7 Jan 15    2014    run-one-
constantly -> run-one
lrwxrwxrwx 1 root      root                      7 Jan 15    2014    keep-one-running
-> run-one
-rwxr-xr-x 1 root      root                1577 Jan 21    2017    linux-boot-prober
-rwxr-xr-x 1 root      root                4551 Jan 31    2017    os-prober
-rwxr-xr-x 1 root      root              14720 Apr 21    2017    time
-rwxr-xr-x 1 root      root              93584 Apr 21    2017    zipsplit
-rwxr-xr-x 1 root      root              89488 Apr 21    2017    zipnote
-rwxr-xr-x 1 root      root              93816 Apr 21    2017    zipcloak
-rwxr-xr-x 1 root      root            216256 Apr 21    2017    zip
-rwxr-xr-x 1 root      root                1081 Aug 28    2017    lspgpot
-rwxr-xr-x 1 root      root                8744 May 29    2018    pollinate
-rwxr-xr-x 1 root      root                2806 Oct 29    2018    eatmydata
-rwxr-xr-x 1 root      root                  152 Nov 12    2018    batch
lrwxrwxrwx 1 root      root                      2 Nov 12    2018    atrm -> at
lrwxrwxrwx 1 root      root                      2 Nov 12    2018    atq -> at
-rwsr-sr-x 1 daemon daemon          55560 Nov 12    2018    at
-rwxr-xr-x 1 root      root              10722 Dec 14    2018    ucfr
-rwxr-xr-x 1 root      root              19367 Dec 14    2018    ucfq
-rwxr-xr-x 1 root      root              40685 Dec 14    2018    ucf
-rwxr-xr-x 1 root      root                7786 Dec 14    2018    lcf
-rwxr-xr-x 1 root      root            121288 Dec 22    2018    sed
-rwxr-xr-x 1 root      root            101064 Jan 14    2019    bc
-rwxr-xr-x 1 root      root              26696 Jan 24    2019    xdg-user-dirs-update
-rwxr-xr-x 1 root      root                  234 Jan 24    2019    xdg-user-dir
-rwxr-xr-x 1 root      root            308560 Feb    1    2019    ltrace
-rwxr-xr-x 1 root      root                2518 Feb 20    2019    zrun
-rwxr-xr-x 1 root      root                1400 Feb 20    2019    vipe
-rwxr-xr-x 1 root      root                4878 Feb 20    2019    vidir
-rwxr-xr-x 1 root      root                4615 Feb 20    2019    ts
-rwxr-xr-x 1 root      root              18424 Feb 20    2019    sponge
-rwxr-xr-x 1 root      root              14328 Feb 20    2019    pee
-rwxr-xr-x 1 root      root              14328 Feb 20    2019    parallel
-rwxr-xr-x 1 root      root              14328 Feb 20    2019    mispipe
-rwxr-xr-x 1 root      root              14328 Feb 20    2019    lckdo
-rwxr-xr-x 1 root      root              14328 Feb 20    2019    isutf8
-rwxr-xr-x 1 root      root              14328 Feb 20    2019    ifne
-rwxr-xr-x 1 root      root              26984 Feb 20    2019    ifdata
-rwxr-xr-x 1 root      root              22776 Feb 20    2019    errno
-rwxr-xr-x 1 root      root                3047 Feb 20    2019    combine
-rwxr-xr-x 1 root      root                2180 Feb 20    2019    chronic
-rwxr-xr-x 1 root      root            109256 Feb 24    2019    netkit-ftp
-rwxr-xr-x 1 root      root                1821 Mar 18    2019    strace-log-merge
-rwxr-xr-x 1 root      root              51296 Apr    8    2019    sdiff
-rwxr-xr-x 1 root      root              67800 Apr    8    2019    diff3
-rwxr-xr-x 1 root      root            219480 Apr    8    2019    diff
-rwxr-xr-x 1 root      root              51296 Apr    8    2019    cmp
-rwxr-xr-x 1 root      root              52456 Apr 12    2019    mokutil
-rwxr-xr-x 1 root      root                  530 May    9    2019    unicode_stop
-rwxr-xr-x 1 root      root                2762 May    9    2019    unicode_start
-rwxr-xr-x 1 root      root              14328 May    9    2019    splitfont
-rwxr-xr-x 1 root      root              18504 May    9    2019    showkey
-rwxr-xr-x 1 root      root              18504 May    9    2019    showconsolefont
-rwxr-xr-x 1 root      root              14440 May    9    2019    setmetamode
-rwxr-xr-x 1 root      root              14408 May    9    2019    setlogcons
-rwxr-xr-x 1 root      root              14392 May    9    2019    setleds
-rwxr-xr-x 1 root      root              14408 May    9    2019    setkeycodes
-rwxr-xr-x 1 root      root              47240 May    9    2019    setfont
-rwxr-xr-x 1 root      root              14328 May    9    2019    screendump
-rwxr-xr-x 1 root      root              22664 May    9    2019    resizecons
-rwxr-xr-x 1 root      root              22520 May    9    2019    psfxtable
lrwxrwxrwx 1 root      root                      9 May    9    2019    psfstriptable
-> psfxtable
lrwxrwxrwx 1 root      root                      9 May    9    2019    psfgettable ->
psfxtable
lrwxrwxrwx 1 root      root                      9 May    9    2019    psfaddtable ->
psfxtable
-rwxr-xr-x 1 root      root              22968 May    9    2019    openvt
-rwxr-xr-x 1 root      root              16163 May    9    2019    mk_modmap
-rwxr-xr-x 1 root      root              26760 May    9    2019    mapscrn
-rwxr-xr-x 1 root      root              34952 May    9    2019    loadunimap
-rwxr-xr-x 1 root      root            215624 May    9    2019    loadkeys
-rwxr-xr-x 1 root      root              14408 May    9    2019    kbdinfo
-rwxr-xr-x 1 root      root              14408 May    9    2019    kbd_mode
-rwxr-xr-x 1 root      root              14408 May    9    2019    getkeycodes
-rwxr-xr-x 1 root      root              14408 May    9    2019    fgconsole
-rwxr-xr-x 1 root      root            178712 May    9    2019    dumpkeys
-rwxr-xr-x 1 root      root              14408 May    9    2019    deallocvt
-rwxr-xr-x 1 root      root              14328 May    9    2019    codepage
-rwxr-xr-x 1 root      root              14408 May    9    2019    chvt
-rwxr-xr-x 1 root      root                4430 Jun 21    2019    deb-systemd-invoke
-rwxr-xr-x 1 root      root              21328 Jun 21    2019    deb-systemd-helper
-rwxr-xr-x 1 root      root              14488 Jul    8    2019    volname
-rwxr-xr-x 1 root      root              35680 Jul    8    2019    eject
-rwxr-xr-x 1 root      root              51440 Jul 16    2019    updatedb.mlocate
-rwxr-sr-x 1 root      mlocate        47344 Jul 16    2019    mlocate
-rwxr-xr-x 1 root      root            129816 Jul 18    2019    dash
lrwxrwxrwx 1 root      root                    17 Jul 20    2019    on_ac_power ->
/sbin/on_ac_power
-rwxr-xr-x 1 root      root            195096 Jul 26    2019    patch
-rwxr-xr-x 1 root      root                2569 Aug    3    2019    pbput
-rwxr-xr-x 1 root      root              16515 Aug    3    2019    pastebinit
lrwxrwxrwx 1 root      root                      5 Aug    3    2019    pbputs ->
pbput
lrwxrwxrwx 1 root      root                      5 Aug    3    2019    pbget -> pbput
-rwxr-xr-x 1 root      root                1827 Aug    3    2019    debconf-show
-rwxr-xr-x 1 root      root                2935 Aug    3    2019    debconf-set-
selections
-rwxr-xr-x 1 root      root                  647 Aug    3    2019    debconf-escape
-rwxr-xr-x 1 root      root                1719 Aug    3    2019    debconf-copydb
-rwxr-xr-x 1 root      root                  608 Aug    3    2019    debconf-
communicate
-rwxr-xr-x 1 root      root              11541 Aug    3    2019    debconf-apt-
progress
-rwxr-xr-x 1 root      root                2859 Aug    3    2019    debconf
-rwxr-xr-x 2 root      root            186664 Aug 16    2019    zipinfo
-rwxr-xr-x 1 root      root                2953 Aug 16    2019    zipgrep
-rwxr-xr-x 1 root      root              84248 Aug 16    2019    unzipsfx
-rwxr-xr-x 2 root      root            186664 Aug 16    2019    unzip
-rwxr-xr-x 1 root      root              26776 Aug 16    2019    funzip
-rwxr-xr-x 1 root      root              39296 Aug 20    2019    mtr-packet
-rwxr-xr-x 1 root      root              82176 Aug 20    2019    mtr
-rwxr-xr-x 1 root      root              56288 Aug 25    2019    xauth
-rwxr-xr-x 1 root      root                3638 Aug 25    2019    lsb_release
-rwxr-xr-x 1 root      root                8564 Sep    3    2019    lesspipe
-rwxr-xr-x 1 root      root                4877 Sep    4    2019    bzexe
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    yes
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    whoami
-rwxr-xr-x 1 root      root              59768 Sep    5    2019    who
-rwxr-xr-x 1 root      root              47456 Sep    5    2019    wc
-rwxr-xr-x 1 root      root            142144 Sep    5    2019    vdir
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    users
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    unlink
-rwxr-xr-x 1 root      root              51576 Sep    5    2019    uniq
-rwxr-xr-x 1 root      root              43384 Sep    5    2019    unexpand
-rwxr-xr-x 1 root      root              39288 Sep    5    2019    uname
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    tty
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    tsort
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    truncate
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    true
-rwxr-xr-x 1 root      root              51544 Sep    5    2019    tr
-rwxr-xr-x 1 root      root            100728 Sep    5    2019    touch
-rwxr-xr-x 1 root      root              43800 Sep    5    2019    timeout
-rwxr-xr-x 1 root      root              55640 Sep    5    2019    test
-rwxr-xr-x 1 root      root              43384 Sep    5    2019    tee
-rwxr-xr-x 1 root      root              72088 Sep    5    2019    tail
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    tac
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    sync
-rwxr-xr-x 1 root      root              47456 Sep    5    2019    sum
-rwxr-xr-x 1 root      root              84344 Sep    5    2019    stty
-rwxr-xr-x 1 root      root              51544 Sep    5    2019    stdbuf
-rwxr-xr-x 1 root      root              88440 Sep    5    2019    stat
-rwxr-xr-x 1 root      root              60184 Sep    5    2019    split
-rwxr-xr-x 1 root      root            117376 Sep    5    2019    sort
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    sleep
-rwxr-xr-x 1 root      root              59736 Sep    5    2019    shuf
-rwxr-xr-x 1 root      root              63864 Sep    5    2019    shred
-rwxr-xr-x 1 root      root              67960 Sep    5    2019    sha512sum
-rwxr-xr-x 1 root      root              67960 Sep    5    2019    sha384sum
-rwxr-xr-x 1 root      root              59768 Sep    5    2019    sha256sum
-rwxr-xr-x 1 root      root              59768 Sep    5    2019    sha224sum
-rwxr-xr-x 1 root      root              51576 Sep    5    2019    sha1sum
-rwxr-xr-x 1 root      root              51544 Sep    5    2019    seq
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    runcon
-rwxr-xr-x 1 root      root              47448 Sep    5    2019    rmdir
-rwxr-xr-x 1 root      root              72056 Sep    5    2019    rm
-rwxr-xr-x 1 root      root              51576 Sep    5    2019    realpath
-rwxr-xr-x 1 root      root              51544 Sep    5    2019    readlink
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    pwd
-rwxr-xr-x 1 root      root              80280 Sep    5    2019    ptx
-rwxr-xr-x 1 root      root              59736 Sep    5    2019    printf
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    printenv
-rwxr-xr-x 1 root      root              76216 Sep    5    2019    pr
-rwxr-xr-x 1 root      root              43384 Sep    5    2019    pinky
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    pathchk
-rwxr-xr-x 1 root      root              43384 Sep    5    2019    paste
-rwxr-xr-x 1 root      root              72056 Sep    5    2019    od
-rwxr-xr-x 1 root      root              67992 Sep    5    2019    numfmt
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    nproc
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    nohup
-rwxr-xr-x 1 root      root              43448 Sep    5    2019    nl
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    nice
-rwxr-xr-x 1 root      root            149888 Sep    5    2019    mv
-rwxr-xr-x 1 root      root              47448 Sep    5    2019    mktemp
-rwxr-xr-x 1 root      root              72024 Sep    5    2019    mknod
-rwxr-xr-x 1 root      root              67928 Sep    5    2019    mkfifo
-rwxr-xr-x 1 root      root              88408 Sep    5    2019    mkdir
lrwxrwxrwx 1 root      root                      6 Sep    5    2019   
md5sum.textutils -> md5sum
-rwxr-xr-x 1 root      root              47480 Sep    5    2019    md5sum
-rwxr-xr-x 1 root      root            142144 Sep    5    2019    ls
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    logname
-rwxr-xr-x 1 root      root              76160 Sep    5    2019    ln
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    link
-rwxr-xr-x 1 root      root              55672 Sep    5    2019    join
-rwxr-xr-x 1 root      root            158112 Sep    5    2019    install
-rwxr-xr-x 1 root      root              47480 Sep    5    2019    id
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    hostid
-rwxr-xr-x 1 root      root              47480 Sep    5    2019    head
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    groups
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    fold
-rwxr-xr-x 1 root      root              47448 Sep    5    2019    fmt
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    false
-rwxr-xr-x 1 root      root              80248 Sep    5    2019    factor
-rwxr-xr-x 1 root      root              55640 Sep    5    2019    expr
-rwxr-xr-x 1 root      root              43384 Sep    5    2019    expand
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    env
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    echo
-rwxr-xr-x 1 root      root            108920 Sep    5    2019    du
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    dirname
-rwxr-xr-x 1 root      root              47456 Sep    5    2019    dircolors
-rwxr-xr-x 1 root      root            142144 Sep    5    2019    dir
-rwxr-xr-x 1 root      root              93128 Sep    5    2019    df
-rwxr-xr-x 1 root      root              80256 Sep    5    2019    dd
-rwxr-xr-x 1 root      root            108920 Sep    5    2019    date
-rwxr-xr-x 1 root      root              47480 Sep    5    2019    cut
-rwxr-xr-x 1 root      root              55672 Sep    5    2019    csplit
-rwxr-xr-x 1 root      root            153976 Sep    5    2019    cp
-rwxr-xr-x 1 root      root              43384 Sep    5    2019    comm
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    cksum
-rwxr-xr-x 1 root      root              72024 Sep    5    2019    chown
-rwxr-xr-x 1 root      root              63864 Sep    5    2019    chmod
-rwxr-xr-x 1 root      root              72024 Sep    5    2019    chgrp
-rwxr-xr-x 1 root      root              72024 Sep    5    2019    chcon
-rwxr-xr-x 1 root      root              43416 Sep    5    2019    cat
-rwxr-xr-x 1 root      root              39256 Sep    5    2019    basename
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    base64
-rwxr-xr-x 1 root      root              43352 Sep    5    2019    base32
-rwxr-xr-x 1 root      root              59768 Sep    5    2019    b2sum
-rwxr-xr-x 1 root      root              39288 Sep    5    2019    arch
-rwxr-xr-x 1 root      root              59736 Sep    5    2019 '['
-rwxr-xr-x 1 root      root                1004 Sep    5    2019    jsonpatch-
jsondiff
-rwxr-xr-x 1 root      root                3662 Sep    5    2019    jsonpatch
-rwxr-xr-x 1 root      root                1297 Sep    5    2019    bzmore
lrwxrwxrwx 1 root      root                      6 Sep    5    2019    bzless ->
bzmore
-rwxr-xr-x 1 root      root              18584 Sep    5    2019    bzip2recover
-rwxr-xr-x 3 root      root              39144 Sep    5    2019    bzip2
-rwxr-xr-x 1 root      root                3775 Sep    5    2019    bzgrep
lrwxrwxrwx 1 root      root                      6 Sep    5    2019    bzfgrep ->
bzgrep
lrwxrwxrwx 1 root      root                      6 Sep    5    2019    bzegrep ->
bzgrep
-rwxr-xr-x 1 root      root                2227 Sep    5    2019    bzdiff
lrwxrwxrwx 1 root      root                      6 Sep    5    2019    bzcmp ->
bzdiff
-rwxr-xr-x 3 root      root              39144 Sep    5    2019    bzcat
-rwxr-xr-x 3 root      root              39144 Sep    5    2019    bunzip2
-rwxr-xr-x 1 root      root              14640 Oct    1    2019    usbreset
-rwxr-xr-x 1 root      root              31112 Oct    1    2019    usbhid-dump
-rwxr-xr-x 1 root      root                4100 Oct    1    2019    usb-devices
-rwxr-xr-x 1 root      root            248328 Oct    1    2019    lsusb
-rwxr-xr-x 1 root      root            118008 Oct 10    2019    install-info
-rwxr-xr-x 1 root      root            317176 Oct 10    2019    info
lrwxrwxrwx 1 root      root                    12 Oct 10    2019    ginstall-info ->
install-info
lrwxrwxrwx 1 root      root                    11 Oct 18    2019    see -> run-
mailcap
-rwxr-xr-x 1 root      root              18487 Oct 18    2019    run-mailcap
lrwxrwxrwx 1 root      root                    11 Oct 18    2019    print -> run-
mailcap
lrwxrwxrwx 1 root      root                    11 Oct 18    2019    edit -> run-
mailcap
lrwxrwxrwx 1 root      root                    11 Oct 18    2019    compose -> run-
mailcap
-rwxr-xr-x 1 root      root                  853 Oct 18    2019    cautious-launcher
-rwxr-xr-x 1 root      root                  125 Oct 27    2019    perldoc
-rwxr-xr-x 1 root      root            711136 Nov    3    2019    gawk
lrwxrwxrwx 1 root      root                      8 Nov    7    2019    ypdomainname -
> hostname
lrwxrwxrwx 1 root      root                      8 Nov    7    2019    nisdomainname
-> hostname
-rwxr-xr-x 1 root      root              26856 Nov    7    2019    hostname
lrwxrwxrwx 1 root      root                      8 Nov    7    2019    domainname ->
hostname
lrwxrwxrwx 1 root      root                      8 Nov    7    2019    dnsdomainname
-> hostname
lrwxrwxrwx 1 root      root                      6 Nov 12    2019    pstree.x11 ->
pstree
-rwxr-xr-x 1 root      root              36008 Nov 12    2019    pstree
-rwxr-xr-x 1 root      root              14488 Nov 12    2019    pslog
-rwxr-xr-x 1 root      root              22760 Nov 12    2019    prtstat
-rwxr-xr-x 1 root      root              14488 Nov 12    2019    peekfd
-rwxr-xr-x 1 root      root              32024 Nov 12    2019    killall
-rwxr-xr-x 1 root      root              40184 Nov 12    2019    fuser
-rwxr-xr-x 1 root      root                  452 Nov 17    2019    sensible-pager
-rwxr-xr-x 1 root      root                1169 Nov 17    2019    sensible-editor
-rwxr-xr-x 1 root      root                1230 Nov 17    2019    sensible-browser
-rwxr-xr-x 1 root      root                2442 Nov 17    2019    select-editor
-rwxr-xr-x 1 root      root            189304 Dec    4    2019    htop
-rwxr-xr-x 1 root      root                2558 Dec    4    2019    apport-bug
-rwxr-xr-x 1 root      root                  946 Dec    7    2019    which
-rwxr-xr-x 1 root      root              14360 Dec    7    2019    tempfile
-rwxr-xr-x 1 root      root              10481 Dec    7    2019    savelog
-rwxr-xr-x 1 root      root              27144 Dec    7    2019    run-parts
-rwxr-xr-x 1 root      root              14536 Dec    7    2019    ischroot
-rwxr-xr-x 1 root      root                  389 Dec 17    2019    chardetect3
lrwxrwxrwx 1 root      root                    11 Dec 17    2019    chardet3 ->
chardetect3
-rwxr-xr-x 1 root      root          9959288 Jan 13    2020    tsdb
-rwxr-xr-x 1 root      root        18683896 Jan 13    2020    promtool
-rwxr-xr-x 1 root      root        36739384 Jan 13    2020    prometheus
-rwxr-xr-x 1 root      root                    30 Jan 16    2020    rgrep
-rwxr-xr-x 1 root      root              27104 Jan 16    2020    file
-rwxr-xr-x 1 root      root                  397 Jan 23    2020    jsonschema
-rwxr-xr-x 1 root      root                1838 Jan 24    2020    jsonpointer
-rwxr-xr-x 1 root      root                2446 Jan 26    2020    dh_bash-completion
-rwxr-xr-x 1 root      root            199136 Jan 29    2020    grep
-rwxr-xr-x 1 root      root                    28 Jan 29    2020    fgrep
-rwxr-xr-x 1 root      root                    28 Jan 29    2020    egrep
-rwxr-xr-x 1 root      root                2514 Jan 30    2020    helpztags
-rwxr-xr-x 1 root      root              26776 Jan 30    2020    traceroute6.iputils
-rwxr-xr-x 1 root      root              18584 Jan 30    2020    tracepath
lrwxrwxrwx 1 root      root                      4 Jan 30    2020    ping6 -> ping
lrwxrwxrwx 1 root      root                      4 Jan 30    2020    ping4 -> ping
-rwxr-xr-x 1 root      root              72776 Jan 30    2020    ping
-rwxr-xr-x 1 root      root              35098 Feb    3    2020    miniterm
lrwxrwxrwx 1 root      root                      1 Feb    8    2020    X11 -> .
-rwxr-xr-x 1 root      root            168800 Feb 13    2020    ss
lrwxrwxrwx 1 root      root                      6 Feb 13    2020    rtstat -> lnstat
-rwxr-xr-x 1 root      root                1656 Feb 13    2020    routel
-rwxr-xr-x 1 root      root                  208 Feb 13    2020    routef
-rwxr-xr-x 1 root      root            133360 Feb 13    2020    rdma
-rwxr-xr-x 1 root      root              80112 Feb 13    2020    nstat
-rwxr-xr-x 1 root      root              31240 Feb 13    2020    lnstat
-rwxr-xr-x 1 root      root            611960 Feb 13    2020    ip
lrwxrwxrwx 1 root      root                      6 Feb 13    2020    ctstat -> lnstat
lrwxrwxrwx 1 root      root                    14 Feb 13    2020    pidof ->
/sbin/killall5
-rwxr-xr-x 1 root      root              23440 Feb 13    2020    ubuntu-distro-info
lrwxrwxrwx 1 root      root                    18 Feb 13    2020    distro-info ->
ubuntu-distro-info
-rwxr-xr-x 1 root      root              23440 Feb 13    2020    debian-distro-info
-rwxr-sr-x 1 root      crontab        43720 Feb 13    2020    crontab
-rwxr-xr-x 1 root      root              10658 Feb 14    2020    ssh-copy-id
-rwxr-xr-x 1 root      root            437792 Feb 15    2020    btrfstune
lrwxrwxrwx 1 root      root                      5 Feb 15    2020    btrfsck -> btrfs
-rwxr-xr-x 1 root      root            441888 Feb 15    2020    btrfs-select-super
-rwxr-xr-x 1 root      root            441888 Feb 15    2020    btrfs-map-logical
-rwxr-xr-x 1 root      root            462368 Feb 15    2020    btrfs-image
-rwxr-xr-x 1 root      root            433760 Feb 15    2020    btrfs-find-root
-rwxr-xr-x 1 root      root            466464 Feb 15    2020    btrfs-convert
-rwxr-xr-x 1 root      root            819296 Feb 15    2020    btrfs
-rwxr-xr-x 1 root      root            162552 Feb 16    2020    mawk
-rwxr-xr-x 1 root      root                2107 Feb 17    2020    wifi-status
-rwxr-xr-x 1 root      root                2640 Feb 17    2020    vigpg
-rwxr-xr-x 1 root      root                1149 Feb 17    2020    purge-old-kernels
-rwxr-xr-x 1 root      root                1942 Feb 17    2020    manifest
-rwxr-xr-x 1 root      root                  960 Feb 17    2020    ctail
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    col9 -> col1
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    col8 -> col1
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    col7 -> col1
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    col6 -> col1
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    col5 -> col1
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    col4 -> col1
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    col3 -> col1
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    col2 -> col1
-rwxr-xr-x 1 root      root                  963 Feb 17    2020    col1
-rwxr-xr-x 1 root      root              11996 Feb 17    2020    byobu-ulevel
-rwxr-xr-x 1 root      root                4667 Feb 17    2020    byobu-ugraph
lrwxrwxrwx 1 root      root                      5 Feb 17    2020    byobu-tmux ->
byobu
-rwxr-xr-x 1 root      root                1207 Feb 17    2020    byobu-status-detail
-rwxr-xr-x 1 root      root                6015 Feb 17    2020    byobu-status
-rwxr-xr-x 1 root      root                1306 Feb 17    2020    byobu-silent
-rwxr-xr-x 1 root      root                1600 Feb 17    2020    byobu-shell
-rwxr-xr-x 1 root      root                1012 Feb 17    2020    byobu-select-
session
-rwxr-xr-x 1 root      root                5123 Feb 17    2020    byobu-select-
profile
-rwxr-xr-x 1 root      root                1452 Feb 17    2020    byobu-select-
backend
lrwxrwxrwx 1 root      root                      5 Feb 17    2020    byobu-screen ->
byobu
-rwxr-xr-x 1 root      root                3298 Feb 17    2020    byobu-reconnect-
sockets
-rwxr-xr-x 1 root      root                1410 Feb 17    2020    byobu-quiet
-rwxr-xr-x 1 root      root                1156 Feb 17    2020    byobu-prompt
-rwxr-xr-x 1 root      root                3348 Feb 17    2020    byobu-layout
-rwxr-xr-x 1 root      root                1561 Feb 17    2020    byobu-launcher-
uninstall
-rwxr-xr-x 1 root      root                2459 Feb 17    2020    byobu-launcher-
install
-rwxr-xr-x 1 root      root                1910 Feb 17    2020    byobu-launcher
-rwxr-xr-x 1 root      root                3329 Feb 17    2020    byobu-launch
-rwxr-xr-x 1 root      root                1506 Feb 17    2020    byobu-keybindings
-rwxr-xr-x 1 root      root                6440 Feb 17    2020    byobu-janitor
-rwxr-xr-x 1 root      root                1351 Feb 17    2020    byobu-export
-rwxr-xr-x 1 root      root                1453 Feb 17    2020    byobu-enable-prompt
-rwxr-xr-x 1 root      root                1182 Feb 17    2020    byobu-enable
-rwxr-xr-x 1 root      root                1341 Feb 17    2020    byobu-disable-
prompt
-rwxr-xr-x 1 root      root                1295 Feb 17    2020    byobu-disable
-rwxr-xr-x 1 root      root                4774 Feb 17    2020    byobu-ctrl-a
-rwxr-xr-x 1 root      root                  996 Feb 17    2020    byobu-config
-rwxr-xr-x 1 root      root                8363 Feb 17    2020    byobu
lrwxrwxrwx 1 root      root                      4 Feb 17    2020    NF -> col1
-rwxr-xr-x 1 root      root              76152 Feb 18    2020    xargs
-rwxr-xr-x 1 root      root            320160 Feb 18    2020    find
-rwxr-xr-x 1 root      root              34984 Feb 18    2020    whiptail
-rwxr-xr-x 1 root      root              44312 Feb 19    2020    efibootmgr
-rwxr-xr-x 1 root      root              22680 Feb 19    2020    efibootdump
-rwxr-xr-x 1 root      root        12196632 Feb 21    2020    prometheus-node-
exporter
-rwxr-xr-x 1 root      root                    89 Feb 22    2020    red
-rwxr-xr-x 1 root      root              55504 Feb 22    2020    ed
-rwxr-xr-x 1 root      root              43176 Feb 24    2020    sgp_dd
-rwxr-xr-x 1 root      root              34976 Feb 24    2020    sgm_dd
-rwxr-xr-x 1 root      root              73576 Feb 24    2020    sginfo
-rwxr-xr-x 1 root      root              15000 Feb 24    2020    sg_zone
-rwxr-xr-x 1 root      root              43176 Feb 24    2020    sg_xcopy
-rwxr-xr-x 1 root      root              56776 Feb 24    2020    sg_write_x
-rwxr-xr-x 1 root      root              23176 Feb 24    2020    sg_write_verify
-rwxr-xr-x 1 root      root              27400 Feb 24    2020    sg_write_same
-rwxr-xr-x 1 root      root              14952 Feb 24    2020    sg_write_long
-rwxr-xr-x 1 root      root              27752 Feb 24    2020    sg_write_buffer
-rwxr-xr-x 1 root      root              23112 Feb 24    2020    sg_wr_mode
-rwxr-xr-x 1 root      root            116920 Feb 24    2020    sg_vpd
-rwxr-xr-x 1 root      root              19176 Feb 24    2020    sg_verify
-rwxr-xr-x 1 root      root              23144 Feb 24    2020    sg_unmap
-rwxr-xr-x 1 root      root              14856 Feb 24    2020    sg_turs
-rwxr-xr-x 1 root      root              19128 Feb 24    2020    sg_timestamp
-rwxr-xr-x 1 root      root              14792 Feb 24    2020    sg_test_rwbuf
-rwxr-xr-x 1 root      root              14856 Feb 24    2020    sg_sync
-rwxr-xr-x 1 root      root              23080 Feb 24    2020    sg_stream_ctl
-rwxr-xr-x 1 root      root              23112 Feb 24    2020    sg_stpg
-rwxr-xr-x 1 root      root              19144 Feb 24    2020    sg_start
-rwxr-xr-x 1 root      root              31976 Feb 24    2020    sg_ses_microcode
-rwxr-xr-x 1 root      root            122648 Feb 24    2020    sg_ses
-rwxr-xr-x 1 root      root              27688 Feb 24    2020    sg_senddiag
-rwxr-xr-x 1 root      root              19176 Feb 24    2020    sg_seek
-rwxr-xr-x 1 root      root              18592 Feb 24    2020    sg_scan
-rwxr-xr-x 1 root      root              18984 Feb 24    2020    sg_sat_set_features
-rwxr-xr-x 1 root      root              19016 Feb 24    2020    sg_sat_read_gplog
-rwxr-xr-x 1 root      root              19304 Feb 24    2020    sg_sat_phy_event
-rwxr-xr-x 1 root      root              23112 Feb 24    2020    sg_sat_identify
-rwxr-xr-x 1 root      root              27496 Feb 24    2020    sg_sanitize
-rwxr-xr-x 1 root      root              23080 Feb 24    2020    sg_safte
-rwxr-xr-x 1 root      root              14792 Feb 24    2020    sg_rtpg
-rwxr-xr-x 1 root      root              14696 Feb 24    2020    sg_rmsn
-rwxr-xr-x 1 root      root              14792 Feb 24    2020    sg_reset_wp
-rwxr-xr-x 1 root      root              14856 Feb 24    2020    sg_reset
-rwxr-xr-x 1 root      root              14920 Feb 24    2020    sg_requests
-rwxr-xr-x 1 root      root              27224 Feb 24    2020    sg_rep_zones
-rwxr-xr-x 1 root      root              14856 Feb 24    2020    sg_referrals
-rwxr-xr-x 1 root      root              14856 Feb 24    2020    sg_reassign
-rwxr-xr-x 1 root      root              23176 Feb 24    2020    sg_readcap
-rwxr-xr-x 1 root      root              14888 Feb 24    2020    sg_read_long
-rwxr-xr-x 1 root      root              27464 Feb 24    2020    sg_read_buffer
-rwxr-xr-x 1 root      root              14728 Feb 24    2020    sg_read_block_limits
-rwxr-xr-x 1 root      root              37352 Feb 24    2020    sg_read_attr
-rwxr-xr-x 1 root      root              26784 Feb 24    2020    sg_read
-rwxr-xr-x 1 root      root              18600 Feb 24    2020    sg_rdac
-rwxr-xr-x 1 root      root              23112 Feb 24    2020    sg_rbuf
-rwxr-xr-x 1 root      root              31400 Feb 24    2020    sg_raw
-rwxr-xr-x 1 root      root              14696 Feb 24    2020    sg_prevent
-rwxr-xr-x 1 root      root              36792 Feb 24    2020    sg_persist
-rwxr-xr-x 1 root      root              35688 Feb 24    2020    sg_opcodes
-rwxr-xr-x 1 root      root              46712 Feb 24    2020    sg_modes
-rwxr-xr-x 1 root      root              27192 Feb 24    2020    sg_map26
-rwxr-xr-x 1 root      root              18584 Feb 24    2020    sg_map
-rwxr-xr-x 1 root      root              23176 Feb 24    2020    sg_luns
-rwxr-xr-x 1 root      root            154488 Feb 24    2020    sg_logs
-rwxr-xr-x 1 root      root            126456 Feb 24    2020    sg_inq
-rwxr-xr-x 1 root      root              14792 Feb 24    2020    sg_ident
-rwxr-xr-x 1 root      root              19176 Feb 24    2020    sg_get_lba_status
-rwxr-xr-x 1 root      root              36088 Feb 24    2020    sg_get_config
-rwxr-xr-x 1 root      root              35976 Feb 24    2020    sg_format
-rwxr-xr-x 1 root      root              14488 Feb 24    2020    sg_emc_trespass
-rwxr-xr-x 1 root      root              23144 Feb 24    2020    sg_decode_sense
-rwxr-xr-x 1 root      root              51376 Feb 24    2020    sg_dd
-rwxr-xr-x 1 root      root              23704 Feb 24    2020    sg_copy_results
-rwxr-xr-x 1 root      root              23304 Feb 24    2020    sg_compare_and_write
-rwxr-xr-x 1 root      root              14696 Feb 24    2020    sg_bg_ctl
-rwxr-xr-x 1 root      root                  936 Feb 24    2020    scsi_temperature
-rwxr-xr-x 1 root      root                1474 Feb 24    2020    scsi_stop
-rwxr-xr-x 1 root      root                1285 Feb 24    2020    scsi_start
-rwxr-xr-x 1 root      root                3857 Feb 24    2020    scsi_satl
-rwxr-xr-x 1 root      root                1121 Feb 24    2020    scsi_ready
-rwxr-xr-x 1 root      root                1327 Feb 24    2020    scsi_readcap
-rwxr-xr-x 1 root      root                3602 Feb 24    2020    scsi_mandat
-rwxr-xr-x 1 root      root                8585 Feb 24    2020    scsi_logging_level
-rwxr-xr-x 1 root      root              39064 Feb 24    2020    rescan-scsi-bus.sh
-rwxr-xr-x 1 root      root              56536 Feb 25    2020    whatis
-rwxr-xr-x 1 root      root              39632 Feb 25    2020    manpath
-rwxr-xr-x 1 root      root            142432 Feb 25    2020    mandb
-rwxr-xr-x 1 root      root              27544 Feb 25    2020    man-recode
-rwxr-xr-x 1 root      root            119632 Feb 25    2020    man
-rwxr-xr-x 1 root      root            101320 Feb 25    2020    lexgrog
-rwxr-xr-x 1 root      root              39616 Feb 25    2020    catman
lrwxrwxrwx 1 root      root                      6 Feb 25    2020    apropos ->
whatis
-rwxr-xr-x 1 root      root                6912 Feb 25    2020    vcs-run
-rwxr-xr-x 1 root      root              24522 Feb 25    2020    growpart
-rwxr-xr-x 1 root      root                7295 Feb 25    2020    ec2metadata
-rwxr-xr-x 1 root      root              31040 Feb 26    2020    tset
-rwxr-xr-x 1 root      root              26968 Feb 26    2020    tput
-rwxr-xr-x 1 root      root              22840 Feb 26    2020    toe
-rwxr-xr-x 1 root      root              92584 Feb 26    2020    tic
-rwxr-xr-x 1 root      root              18744 Feb 26    2020    tabs
lrwxrwxrwx 1 root      root                      4 Feb 26    2020    reset -> tset
lrwxrwxrwx 1 root      root                      3 Feb 26    2020    infotocap -> tic
-rwxr-xr-x 1 root      root              63880 Feb 26    2020    infocmp
-rwxr-xr-x 1 root      root              14656 Feb 26    2020    clear
lrwxrwxrwx 1 root      root                      3 Feb 26    2020    captoinfo -> tic
lrwxrwxrwx 1 root      root                    28 Feb 28    2020    iptables-xml ->
../sbin/xtables-legacy-multi
-rwxr-xr-x 1 root      root                  785 Feb 28    2020    ssh-import-id-lp
-rwxr-xr-x 1 root      root                  785 Feb 28    2020    ssh-import-id-gh
-rwxr-xr-x 1 root      root                  409 Feb 28    2020    ssh-import-id
-rwxr-xr-x 1 root      root              35120 Feb 28    2020    xwud
-rwxr-xr-x 1 root      root              39232 Feb 28    2020    xwd
-rwxr-xr-x 1 root      root              19024 Feb 28    2020    xmore
-rwxr-xr-x 1 root      root              83152 Feb 28    2020    xman
-rwxr-xr-x 1 root      root              49584 Feb 28    2020    xmag
-rwxr-xr-x 1 root      root              27920 Feb 28    2020    xlogo
-rwxr-xr-x 1 root      root              27648 Feb 28    2020    xload
-rwxr-xr-x 1 root      root              80304 Feb 28    2020    xgc
-rwxr-xr-x 1 root      root              32560 Feb 28    2020    xeyes
-rwxr-xr-x 1 root      root            689512 Feb 28    2020    xedit
-rwxr-xr-x 1 root      root            110736 Feb 28    2020    xditview
-rwxr-xr-x 1 root      root              23184 Feb 28    2020    xcutsel
-rwxr-xr-x 1 root      root              22832 Feb 28    2020    xcursorgen
-rwxr-xr-x 1 root      root              27936 Feb 28    2020    xconsole
-rwxr-xr-x 1 root      root              66704 Feb 28    2020    xclock
-rwxr-xr-x 1 root      root              27296 Feb 28    2020    xclipboard
-rwxr-xr-x 1 root      root              48624 Feb 28    2020    xcalc
-rwxr-xr-x 1 root      root              24768 Feb 28    2020    xbiff
-rwxr-xr-x 1 root      root                2807 Feb 28    2020    x11perfcomp
-rwxr-xr-x 1 root      root            202200 Feb 28    2020    x11perf
-rwxr-xr-x 1 root      root              23336 Feb 28    2020    transset
-rwxr-xr-x 1 root      root              61392 Feb 28    2020    rendercheck
-rwxr-xr-x 1 root      root              28384 Feb 28    2020    oclock
-rwxr-xr-x 1 root      root              51648 Feb 28    2020    ico
-rwxr-xr-x 1 root      root              14664 Feb 28    2020    bmtoa
-rwxr-xr-x 1 root      root            108944 Feb 28    2020    bitmap
-rwxr-xr-x 1 root      root              14640 Feb 28    2020    atobm
-rwxr-xr-x 1 root      root              51592 Feb 29    2020    xwininfo
-rwxr-xr-x 1 root      root              18744 Feb 29    2020    xvinfo
-rwxr-xr-x 1 root      root              49768 Feb 29    2020    xprop
-rwxr-xr-x 1 root      root              27840 Feb 29    2020    xmessage
-rwxr-xr-x 1 root      root              27032 Feb 29    2020    xlsfonts
-rwxr-xr-x 1 root      root              18752 Feb 29    2020    xlsclients
-rwxr-xr-x 1 root      root              14648 Feb 29    2020    xlsatoms
-rwxr-xr-x 1 root      root              14648 Feb 29    2020    xkill
-rwxr-xr-x 1 root      root              49056 Feb 29    2020    xfontsel
-rwxr-xr-x 1 root      root              41024 Feb 29    2020    xfd
-rwxr-xr-x 1 root      root              35488 Feb 29    2020    xev
-rwxr-xr-x 1 root      root              14648 Feb 29    2020    xdriinfo
-rwxr-xr-x 1 root      root              44104 Feb 29    2020    xdpyinfo
-rwxr-xr-x 1 root      root              32016 Feb 29    2020    viewres
-rwxr-xr-x 1 root      root              53680 Feb 29    2020    luit
-rwxr-xr-x 1 root      root              15080 Feb 29    2020    listres
-rwxr-xr-x 1 root      root              74448 Feb 29    2020    editres
-rwxr-xr-x 1 root      root              14648 Feb 29    2020    appres
-rwxr-xr-x 1 root      root              18584 Mar    7    2020    ulockmgr_server
-rwsr-xr-x 1 root      root              39144 Mar    7    2020    fusermount
-rwxr-xr-x 1 root      root              43664 Mar    9    2020    nc.openbsd
lrwxrwxrwx 1 root      root                      9 Mar 13    2020    python3 ->
python3.8
lrwxrwxrwx 1 root      root                    12 Mar 13    2020    pygettext3 ->
pygettext3.8
lrwxrwxrwx 1 root      root                      8 Mar 13    2020    pydoc3 ->
pydoc3.8
lrwxrwxrwx 1 root      root                    31 Mar 13    2020    py3versions ->
../share/python3/py3versions.py
-rwxr-xr-x 1 root      root              12120 Mar 13    2020    py3compile
-rwxr-xr-x 1 root      root                7813 Mar 13    2020    py3clean
lrwxrwxrwx 1 root      root                      6 Mar 13    2020    pdb3 -> pdb3.8
-rwxr-xr-x 1 root      root                  385 Mar 14    2020    keyring
lrwxrwxrwx 1 root      root                      7 Mar 16    2020    ansible-vault ->
ansible
lrwxrwxrwx 1 root      root                      7 Mar 16    2020    ansible-pull ->
ansible
lrwxrwxrwx 1 root      root                      7 Mar 16    2020    ansible-playbook
-> ansible
lrwxrwxrwx 1 root      root                      7 Mar 16    2020    ansible-
inventory -> ansible
lrwxrwxrwx 1 root      root                      7 Mar 16    2020    ansible-galaxy -
> ansible
lrwxrwxrwx 1 root      root                      7 Mar 16    2020    ansible-doc ->
ansible
lrwxrwxrwx 1 root      root                      7 Mar 16    2020    ansible-console
-> ansible
lrwxrwxrwx 1 root      root                    79 Mar 16    2020    ansible-
connection ->
../lib/python3/dist-packages/ansible/cli/scripts/ansible_connection_cli_stub.py
lrwxrwxrwx 1 root      root                      7 Mar 16    2020    ansible-config -
> ansible
lrwxrwxrwx 1 root      root                    68 Mar 16    2020    ansible ->
../lib/python3/dist-packages/ansible/cli/scripts/ansible_cli_stub.py
-rwxr-xr-x 1 root      root            753568 Mar 21    2020    troff
-rwxr-xr-x 1 root      root            141832 Mar 21    2020    tbl
-rwxr-xr-x 1 root      root              47624 Mar 21    2020    soelim
-rwxr-xr-x 1 root      root              68104 Mar 21    2020    preconv
-rwxr-xr-x 1 root      root            221536 Mar 21    2020    pic
-rwxr-xr-x 1 root      root                3293 Mar 21    2020    nroff
-rwxr-xr-x 1 root      root                  913 Mar 21    2020    neqn
lrwxrwxrwx 1 root      root                      3 Mar 21    2020    gtbl -> tbl
-rwxr-xr-x 1 root      root            132672 Mar 21    2020    grotty
-rwxr-xr-x 1 root      root            186304 Mar 21    2020    grops
-rwxr-xr-x 1 root      root                2776 Mar 21    2020    grog
-rwxr-xr-x 1 root      root            124448 Mar 21    2020    groff
lrwxrwxrwx 1 root      root                      3 Mar 21    2020    gpic -> pic
lrwxrwxrwx 1 root      root                      3 Mar 21    2020    geqn -> eqn
-rwxr-xr-x 1 root      root            206336 Mar 21    2020    eqn
-rwxr-xr-x 1 root      root                  402 Mar 21    2020    automat-visualize3
-rwxr-xr-x 1 root      root              43240 Mar 22    2020    ngettext
-rwxr-xr-x 1 root      root                4629 Mar 22    2020    gettext.sh
-rwxr-xr-x 1 root      root              43240 Mar 22    2020    gettext
-rwxr-xr-x 1 root      root              43240 Mar 22    2020    envsubst
-rwxr-xr-x 1 root      root              68240 Mar 22    2020    pinentry-curses
-rwxr-xr-x 1 root      root            115376 Mar 23    2020    telnet.netkit
-rwxr-xr-x 1 root      root              59768 Mar 24    2020    update-mime-database
-rwxr-xr-x 1 root      root              39233 Mar 27    2020    setupcon
-rwxr-xr-x 1 root      root            149904 Mar 27    2020    ckbcomp
-rwxr-xr-x 1 root      root              18600 Mar 30    2020    ul
-rwxr-xr-x 1 root      root              22680 Mar 30    2020    printerbanner
-rwxr-xr-x 1 root      root              37832 Mar 30    2020    ncal
-rwxr-xr-x 1 root      root                2885 Mar 30    2020    lorder
-rwxr-xr-x 1 root      root              14728 Mar 30    2020    look
-rwxr-xr-x 1 root      root              35072 Mar 30    2020    hexdump
lrwxrwxrwx 1 root      root                      7 Mar 30    2020    hd -> hexdump
-rwxr-xr-x 1 root      root              14504 Mar 30    2020    column
-rwxr-xr-x 1 root      root              14488 Mar 30    2020    colrm
-rwxr-xr-x 1 root      root              14488 Mar 30    2020    colcrt
-rwxr-xr-x 1 root      root              18584 Mar 30    2020    col
-rwxr-xr-x 1 root      root              35464 Mar 30    2020    calendar
lrwxrwxrwx 1 root      root                      4 Mar 30    2020    cal -> ncal
-rwxr-sr-x 1 root      tty                14488 Mar 30    2020    bsd-write
-rwxr-xr-x 1 root      root              14488 Mar 30    2020    bsd-from
lrwxrwxrwx 1 root      root                      4 Mar 31    2020    nodejs -> node
-rwxr-xr-x 1 root      root              14416 Mar 31    2020    node
-rwxr-xr-x 1 root      root                5191 Apr    1    2020    kernel-install
lrwxrwxrwx 1 root      root                      4 Apr 10    2020    rnano -> nano
-rwxr-xr-x 1 root      root            320136 Apr 10    2020    nano
-rwxr-xr-x 1 root      root                2665 Apr 14    2020    register-python-
argcomplete3
-rwxr-xr-x 1 root      root                  314 Apr 14    2020    python-
argcomplete-tcsh3
-rwxr-xr-x 1 root      root                2555 Apr 14    2020    python-argcomplete-
check-easy-install-script3
-rwxr-xr-x 1 root      root                3452 Apr 14    2020    activate-global-
python-argcomplete3
-rwxr-xr-x 1 root      root          1583592 Apr 16    2020    strace
-rwxr-xr-x 1 root      root              35344 May 19    2020    aa-exec
-rwxr-xr-x 1 root      root              31248 May 19    2020    aa-enabled
-rwxr-xr-x 1 root      root                6320 Jun 25    2020    linux-update-
symlinks
-rwxr-xr-x 1 root      root                4090 Jun 25    2020    linux-check-removal
-rwxr-xr-x 1 root      root              24288 Jul    1    2020    lesskey
lrwxrwxrwx 1 root      root                      8 Jul    1    2020    lessfile ->
lesspipe
-rwxr-xr-x 1 root      root              14656 Jul    1    2020    lessecho
-rwxr-xr-x 1 root      root            180064 Jul    1    2020    less
-rwxr-xr-x 1 root      root              33434 Aug 24    2020    pg_upgradecluster
-rwxr-xr-x 1 root      root                5887 Aug 24    2020    pg_renamecluster
-rwxr-xr-x 1 root      root                5268 Aug 24    2020    pg_lsclusters
-rwxr-xr-x 1 root      root                6262 Aug 24    2020    pg_conftool
-rwxr-xr-x 1 root      root                1229 Aug 24    2020    pg_config
-rwxr-xr-x 1 root      root                9707 Aug 24    2020    pg_buildext
-rwxr-xr-x 1 root      root                7859 Aug 24    2020    pg_virtualenv
-rwxr-xr-x 1 root      root                7603 Aug 24    2020    pg_dropcluster
-rwxr-xr-x 1 root      root              23919 Aug 24    2020    pg_ctlcluster
-rwxr-xr-x 1 root      root              34684 Aug 24    2020    pg_createcluster
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    vacuumlo ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    vacuumdb ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    reindexdb ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    psql ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pgbench ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_restore ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_recvlogical ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_receivexlog ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_receivewal ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_isready ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_dumpall ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_dump ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_basebackup ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    pg_archivecleanup
-> ../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    dropuser ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    droplang ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    dropdb ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    createuser ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    createlang ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    createdb ->
../share/postgresql-common/pg_wrapper
lrwxrwxrwx 1 root      root                    37 Aug 24    2020    clusterdb ->
../share/postgresql-common/pg_wrapper
-rwxr-xr-x 1 root      root                2152 Sep 10    2020    finalrd
-rwxr-xr-x 1 root      root              22840 Sep 23    2020    pkmon
-rwxr-xr-x 1 root      root              76088 Sep 23    2020    pkcon
-rwxr-xr-x 1 root      root                2771 Sep 27    2020    check-language-
support
-rwxr-xr-x 1 root      root              50718 Oct 19    2020    zipdetails
-rwxr-xr-x 1 root      root                5164 Oct 19    2020    xsubpp
-rwxr-xr-x 1 root      root              19150 Oct 19    2020    splain
-rwxr-xr-x 1 root      root                9976 Oct 19    2020    shasum
-rwxr-xr-x 1 root      root                4392 Oct 19    2020    ptargrep
-rwxr-xr-x 1 root      root                2628 Oct 19    2020    ptardiff
-rwxr-xr-x 1 root      root                3549 Oct 19    2020    ptar
-rwxr-xr-x 1 root      root              13655 Oct 19    2020    prove
-rwxr-xr-x 1 root      root                2527 Oct 19    2020    podselect
-rwxr-xr-x 1 root      root                3658 Oct 19    2020    podchecker
-rwxr-xr-x 1 root      root                3948 Oct 19    2020    pod2usage
-rwxr-xr-x 1 root      root              10803 Oct 19    2020    pod2text
-rwxr-xr-x 1 root      root              15034 Oct 19    2020    pod2man
-rwxr-xr-x 1 root      root                4134 Oct 19    2020    pod2html
-rwxr-xr-x 1 root      root                4533 Oct 19    2020    pl2pm
-rwxr-xr-x 1 root      root                8357 Oct 19    2020    piconv
-rwxr-xr-x 2 root      root              46366 Oct 19    2020    perlthanks
-rwxr-xr-x 1 root      root              10864 Oct 19    2020    perlivp
-rwxr-xr-x 2 root      root              46366 Oct 19    2020    perlbug
-rwxr-xr-x 2 root      root          3478464 Oct 19    2020    perl5.30.0
-rwxr-xr-x 1 root      root              14648 Oct 19    2020    perl5.30-x86_64-
linux-gnu
-rwxr-xr-x 2 root      root          3478464 Oct 19    2020    perl
-rwxr-xr-x 1 root      root              15775 Oct 19    2020    libnetcfg
-rwxr-xr-x 1 root      root                4667 Oct 19    2020    json_pp
-rwxr-xr-x 1 root      root                4370 Oct 19    2020    instmodsh
-rwxr-xr-x 1 root      root              60866 Oct 19    2020    h2xs
-rwxr-xr-x 1 root      root              29224 Oct 19    2020    h2ph
-rwxr-xr-x 1 root      root                3066 Oct 19    2020    encguess
-rwxr-xr-x 1 root      root              42111 Oct 19    2020    enc2xs
-rwxr-xr-x 1 root      root                8176 Oct 19    2020    cpan5.30-x86_64-
linux-gnu
-rwxr-xr-x 1 root      root                8155 Oct 19    2020    cpan
-rwxr-xr-x 1 root      root              15088 Oct 19    2020    corelist
-rwxr-xr-x 1 root      root              51352 Nov    2    2020    plymouth
-rwxr-xr-x 1 root      root            861384 Dec 17    2020    lshw
-rwxr-xr-x 1 root      root            175744 Dec 25    2020    lsof
-rwxr-xr-x 1 root      root                3060 Jan    6    2021    migrate-pubring-
from-classic-gpg
-rwxr-xr-x 1 root      root              64512 Jan 19    2021    sudoreplay
lrwxrwxrwx 1 root      root                      4 Jan 19    2021    sudoedit -> sudo
-rwsr-xr-x 1 root      root            166056 Jan 19    2021    sudo
-rwxr-xr-x 1 root      root            273096 Jan 19    2021    cvtsudoers
-rwxr-xr-x 1 root      root            474280 Feb 23    2021    screen
lrwxrwxrwx 1 root      root                    14 Mar 18    2021    iscsiadm ->
/sbin/iscsiadm
-rwxr-xr-x 1 root      root                  706 Mar 18    2021    lsinitramfs
-rwxr-xr-x 1 root      root              30960 Mar 31    2021    setpci
-rwxr-xr-x 1 root      root              94160 Mar 31    2021    lspci
-rwxr-xr-x 1 root      root            692192 Apr 22    2021    tmux
lrwxrwxrwx 1 root      root                      3 May 20    2021    unlz4 -> lz4
lrwxrwxrwx 1 root      root                      3 May 20    2021    lz4cat -> lz4
lrwxrwxrwx 1 root      root                      3 May 20    2021    lz4c -> lz4
-rwxr-xr-x 1 root      root            190704 May 20    2021    lz4
-rwxr-xr-x 1 root      root                3676 Jun 18    2021    unmkinitramfs
-rwxr-xr-x 1 root      root                2698 Jul    7    2021    linux-version
-rwxr-xr-x 1 root      root              31112 Jul 12    2021    gsettings
-rwxr-xr-x 1 root      root              22840 Jul 12    2021    gresource
lrwxrwxrwx 1 root      root                    53 Jul 12    2021    glib-compile-
schemas -> ../lib/x86_64-linux-gnu/glib-2.0/glib-compile-schemas
lrwxrwxrwx 1 root      root                    49 Jul 12    2021    gio-querymodules
-> ../lib/x86_64-linux-gnu/glib-2.0/gio-querymodules
-rwxr-xr-x 1 root      root              92568 Jul 12    2021    gio
-rwxr-xr-x 1 root      root              51592 Jul 12    2021    gdbus
-rwxr-xr-x 1 root      root              22920 Jul 12    2021    gapplication
-rwxr-xr-x 1 root      root              43480 Aug    9    2021    tapestat
-rwxr-xr-x 1 root      root            139976 Aug    9    2021    sar.sysstat
-rwxr-xr-x 1 root      root            362120 Aug    9    2021    sadf
-rwxr-xr-x 1 root      root              68056 Aug    9    2021    pidstat
-rwxr-xr-x 1 root      root              59864 Aug    9    2021    mpstat
-rwxr-xr-x 1 root      root              63960 Aug    9    2021    iostat
-rwxr-xr-x 1 root      root              43480 Aug    9    2021    cifsiostat
-rwxr-xr-x 1 root      root              88864 Aug 25    2021    mt-gnu
-rwxr-xr-x 1 root      root            165504 Aug 25    2021    cpio
-rwxr-xr-x 1 root      root              59776 Sep    6    2021    udisksctl
-rwxr-xr-x 1 root      root              27208 Sep    9    2021    watch
-rwxr-xr-x 1 root      root              22760 Sep    9    2021    w.procps
-rwxr-xr-x 1 root      root              39168 Sep    9    2021    vmstat
-rwxr-xr-x 1 root      root              14568 Sep    9    2021    uptime
-rwxr-xr-x 1 root      root            129072 Sep    9    2021    top
-rwxr-xr-x 1 root      root              22776 Sep    9    2021    tload
lrwxrwxrwx 1 root      root                      5 Sep    9    2021    snice -> skill
-rwxr-xr-x 1 root      root              22768 Sep    9    2021    slabtop
-rwxr-xr-x 1 root      root              30952 Sep    9    2021    skill
-rwxr-xr-x 1 root      root              14568 Sep    9    2021    pwdx
-rwxr-xr-x 1 root      root            137688 Sep    9    2021    ps
-rwxr-xr-x 1 root      root              35064 Sep    9    2021    pmap
lrwxrwxrwx 1 root      root                      5 Sep    9    2021    pkill -> pgrep
-rwxr-xr-x 1 root      root              30968 Sep    9    2021    pgrep
-rwxr-xr-x 1 root      root              30952 Sep    9    2021    kill
-rwxr-xr-x 1 root      root              26864 Sep    9    2021    free
-rwxr-xr-x 1 root      root            114808 Oct 12    2021    unsquashfs
-rwxr-xr-x 1 root      root            210904 Oct 12    2021    mksquashfs
lrwxrwxrwx 1 root      root                    18 Oct 26    2021    apt-add-
repository -> add-apt-repository
-rwxr-xr-x 1 root      root                7415 Oct 26    2021    add-apt-repository
-rwxr-xr-x 1 root      root            544472 Nov 12    2021    wget
lrwxrwxrwx 1 root      root                      7 Nov 24    2021    static-sh ->
busybox
-rwxr-xr-x 1 root      root          2172376 Nov 24    2021    busybox
-rwxr-xr-x 1 root      root                5807 Nov 24    2021    mesa-overlay-
control.py
-rwxr-xr-x 1 root      root            759056 Jan 11    2022    grub-syslinux2cfg
-rwxr-xr-x 1 root      root            278224 Jan 11    2022    grub-script-check
-rwxr-xr-x 1 root      root            819968 Jan 11    2022    grub-render-label
lrwxrwxrwx 1 root      root                    34 Jan 11    2022    grub-ntldr-img ->
../lib/grub/i386-pc/grub-ntldr-img
-rwxr-xr-x 1 root      root            746288 Jan 11    2022    grub-mount
-rwxr-xr-x 1 root      root            489328 Jan 11    2022    grub-mkstandalone
-rwxr-xr-x 1 root      root            977200 Jan 11    2022    grub-mkrescue
-rwxr-xr-x 1 root      root            245328 Jan 11    2022    grub-mkrelpath
-rwxr-xr-x 1 root      root            254160 Jan 11    2022    grub-mkpasswd-pbkdf2
-rwxr-xr-x 1 root      root            411200 Jan 11    2022    grub-mknetdir
-rwxr-xr-x 1 root      root            258224 Jan 11    2022    grub-mklayout
-rwxr-xr-x 1 root      root            357328 Jan 11    2022    grub-mkimage
-rwxr-xr-x 1 root      root            274864 Jan 11    2022    grub-mkfont
-rwxr-xr-x 1 root      root            233600 Jan 11    2022    grub-menulst2cfg
-rwxr-xr-x 1 root      root                1681 Jan 11    2022    grub-kbdcomp
-rwxr-xr-x 1 root      root            249712 Jan 11    2022    grub-glue-efi
-rwxr-xr-x 1 root      root            923488 Jan 11    2022    grub-fstest
-rwxr-xr-x 1 root      root            799104 Jan 11    2022    grub-file
-rwxr-xr-x 1 root      root            253968 Jan 11    2022    grub-editenv
-rwxr-xr-x 1 root      root              23756 Jan 14    2022    ubuntu-security-
status
-rwxr-xr-x 1 root      root              10830 Jan 14    2022    hwe-support-status
lrwxrwxrwx 1 root      root                      4 Jan 28    2022    lsmod -> kmod
-rwxr-xr-x 1 root      root            174424 Jan 28    2022    kmod
lrwxrwxrwx 1 root      root                      7 Feb    7    2022    x86_64 ->
setarch
-rwxr-xr-x 1 root      root              35496 Feb    7    2022    whereis
-rwxr-xr-x 1 root      root              35048 Feb    7    2022    wdctl
-rwxr-sr-x 1 root      tty                35048 Feb    7    2022    wall
-rwxr-xr-x 1 root      root              39144 Feb    7    2022    uuidparse
-rwxr-xr-x 1 root      root              14568 Feb    7    2022    uuidgen
-rwxr-xr-x 1 root      root              30952 Feb    7    2022    utmpdump
-rwxr-xr-x 1 root      root              43448 Feb    7    2022    unshare
-rwsr-xr-x 1 root      root              39144 Feb    7    2022    umount
-rwxr-xr-x 1 root      root              35048 Feb    7    2022    taskset
-rwsr-xr-x 1 root      root              67816 Feb    7    2022    su
-rwxr-xr-x 1 root      root              47336 Feb    7    2022    setterm
-rwxr-xr-x 1 root      root              14568 Feb    7    2022    setsid
-rwxr-xr-x 1 root      root              47344 Feb    7    2022    setpriv
-rwxr-xr-x 1 root      root              27136 Feb    7    2022    setarch
-rwxr-xr-x 1 root      root              30952 Feb    7    2022    scriptreplay
-rwxr-xr-x 1 root      root              55528 Feb    7    2022    script
-rwxr-xr-x 1 root      root              14568 Feb    7    2022    rev
-rwxr-xr-x 1 root      root              63720 Feb    7    2022    resizepart
-rwxr-xr-x 1 root      root              14568 Feb    7    2022    renice
-rwxr-xr-x 1 root      root              22760 Feb    7    2022    rename.ul
-rwxr-xr-x 1 root      root              39672 Feb    7    2022    prlimit
-rwxr-xr-x 1 root      root            121072 Feb    7    2022    partx
-rwxr-xr-x 1 root      root              35256 Feb    7    2022    nsenter
-rwxr-xr-x 1 root      root              35048 Feb    7    2022    namei
-rwxr-xr-x 1 root      root              14568 Feb    7    2022    mountpoint
-rwsr-xr-x 1 root      root              55528 Feb    7    2022    mount
-rwxr-xr-x 1 root      root              43160 Feb    7    2022    more
-rwxr-xr-x 1 root      root              14568 Feb    7    2022    mesg
-rwxr-xr-x 1 root      root              35120 Feb    7    2022    mcookie
-rwxr-xr-x 1 root      root              51440 Feb    7    2022    lsns
-rwxr-xr-x 1 root      root              67816 Feb    7    2022    lsmem
-rwxr-xr-x 1 root      root              67816 Feb    7    2022    lslogins
-rwxr-xr-x 1 root      root              39480 Feb    7    2022    lslocks
-rwxr-xr-x 1 root      root              96488 Feb    7    2022    lsipc
-rwxr-xr-x 1 root      root            100584 Feb    7    2022    lscpu
-rwxr-xr-x 1 root      root            133352 Feb    7    2022    lsblk
-rwxr-xr-x 1 root      root              52040 Feb    7    2022    logger
lrwxrwxrwx 1 root      root                      7 Feb    7    2022    linux64 ->
setarch
lrwxrwxrwx 1 root      root                      7 Feb    7    2022    linux32 ->
setarch
lrwxrwxrwx 1 root      root                      4 Feb    7    2022    lastb -> last
-rwxr-xr-x 1 root      root              47336 Feb    7    2022    last
-rwxr-xr-x 1 root      root              67816 Feb    7    2022    ipcs
-rwxr-xr-x 1 root      root              35048 Feb    7    2022    ipcrm
-rwxr-xr-x 1 root      root              35120 Feb    7    2022    ipcmk
-rwxr-xr-x 1 root      root              30952 Feb    7    2022    ionice
lrwxrwxrwx 1 root      root                      7 Feb    7    2022    i386 ->
setarch
-rwxr-xr-x 1 root      root              22760 Feb    7    2022    getopt
-rwxr-xr-x 1 root      root              35128 Feb    7    2022    flock
-rwxr-xr-x 1 root      root              73128 Feb    7    2022    findmnt
-rwxr-xr-x 1 root      root              35096 Feb    7    2022    fincore
-rwxr-xr-x 1 root      root              35048 Feb    7    2022    fallocate
-rwxr-xr-x 1 root      root              84440 Feb    7    2022    dmesg
-rwxr-xr-x 1 root      root              30952 Feb    7    2022    delpart
-rwxr-xr-x 1 root      root              39144 Feb    7    2022    chrt
-rwxr-xr-x 1 root      root              51432 Feb    7    2022    choom
-rwxr-xr-x 1 root      root              30952 Feb    7    2022    addpart
-rwxr-xr-x 1 root      root                  624 Feb 14    2022    landscape-sysinfo
-rwxr-xr-x 1 root      root            388016 Feb 21    2022    fwupdtool
-rwxr-xr-x 1 root      root            190768 Feb 21    2022    fwupdmgr
-rwxr-xr-x 1 root      root              84408 Feb 21    2022    fwupdate
lrwxrwxrwx 1 root      root                      8 Feb 21    2022    fwupdagent ->
fwupdmgr
-rwxr-xr-x 1 root      root            108848 Feb 21    2022    dfu-tool
-rwxr-xr-x 1 root      root              26928 Feb 21    2022    dbxtool
-rwxr-xr-x 1 root      root              18744 Feb 21    2022    pkttyagent
-rwsr-xr-x 1 root      root              31032 Feb 21    2022    pkexec
-rwxr-xr-x 1 root      root              22912 Feb 21    2022    pkcheck
-rwxr-xr-x 1 root      root              18744 Feb 21    2022    pkaction
-rwxr-xr-x 1 root      root            154440 Feb 25    2022    boltctl
-rwxr-xr-x 1 root      root              63984 Mar 10    2022    sbverify
-rwxr-xr-x 1 root      root              68208 Mar 10    2022    sbvarsign
-rwxr-xr-x 1 root      root              59952 Mar 10    2022    sbsign
-rwxr-xr-x 1 root      root              59952 Mar 10    2022    sbsiglist
-rwxr-xr-x 1 root      root              68304 Mar 10    2022    sbkeysync
-rwxr-xr-x 1 root      root              59888 Mar 10    2022    sbattach
-rwxr-xr-x 1 root      root              22824 Mar 10    2022    kmodsign
lrwxrwxrwx 1 root      root                      6 Mar 14    2022    sg -> newgrp
-rwsr-xr-x 1 root      root              68208 Mar 14    2022    passwd
-rwsr-xr-x 1 root      root              44784 Mar 14    2022    newgrp
-rwxr-xr-x 1 root      root              57104 Mar 14    2022    login
-rwxr-xr-x 1 root      root              32416 Mar 14    2022    lastlog
-rwsr-xr-x 1 root      root              88464 Mar 14    2022    gpasswd
-rwxr-xr-x 1 root      root              23136 Mar 14    2022    faillog
-rwxr-sr-x 1 root      shadow          31312 Mar 14    2022    expiry
-rwsr-xr-x 1 root      root              53040 Mar 14    2022    chsh
-rwsr-xr-x 1 root      root              85064 Mar 14    2022    chfn
-rwxr-sr-x 1 root      shadow          84512 Mar 14    2022    chage
-rwxr-xr-x 1 root      root            448112 Mar 15    2022    tar
-rwxr-xr-x 1 root      root                  384 Mar 21    2022    twistd3
-rwxr-xr-x 1 root      root                  382 Mar 21    2022    twist3
-rwxr-xr-x 1 root      root                  382 Mar 21    2022    trial3
-rwxr-xr-x 1 root      root                  386 Mar 21    2022    tkconch3
-rwxr-xr-x 1 root      root                  392 Mar 21    2022    pyhtmlizer3
-rwxr-xr-x 1 root      root                  388 Mar 21    2022    mailmail3
-rwxr-xr-x 1 root      root                  382 Mar 21    2022    conch3
-rwxr-xr-x 1 root      root                  386 Mar 21    2022    ckeygen3
-rwxr-xr-x 1 root      root                  380 Mar 21    2022    cftp3
-rwxr-xr-x 1 root      root            465208 Mar 30    2022    ssh-keyscan
-rwxr-xr-x 1 root      root            477488 Mar 30    2022    ssh-keygen
-rwxr-xr-x 1 root      root                1455 Mar 30    2022    ssh-argv0
-rwxr-sr-x 1 root      ssh              350504 Mar 30    2022    ssh-agent
-rwxr-xr-x 1 root      root            370976 Mar 30    2022    ssh-add
-rwxr-xr-x 1 root      root            789448 Mar 30    2022    ssh
lrwxrwxrwx 1 root      root                      3 Mar 30    2022    slogin -> ssh
-rwxr-xr-x 1 root      root            170504 Mar 30    2022    sftp
-rwxr-xr-x 1 root      root            117040 Mar 30    2022    scp
-rwxr-xr-x 1 root      root              26840 Apr    7    2022    zdump
-rwxr-xr-x 1 root      root              15378 Apr    7    2022    tzselect
-rwxr-xr-x 1 root      root              22904 Apr    7    2022    pldd
-rwxr-xr-x 1 root      root            334808 Apr    7    2022    localedef
-rwxr-xr-x 1 root      root              58944 Apr    7    2022    locale
-rwxr-xr-x 1 root      root                5427 Apr    7    2022    ldd
-rwxr-xr-x 1 root      root              68000 Apr    7    2022    iconv
-rwxr-xr-x 1 root      root              39576 Apr    7    2022    getent
-rwxr-xr-x 1 root      root              35112 Apr    7    2022    getconf
-rwxr-xr-x 1 root      root                3330 Apr    7    2022    catchsegv
-rwxr-xr-x 1 root      root            263440 Apr    8    2022    mmcli
-rwxr-xr-x 1 root      root                4577 Apr    8    2022    znew
-rwxr-xr-x 1 root      root                1842 Apr    8    2022    zmore
-rwxr-xr-x 1 root      root                2206 Apr    8    2022    zless
-rwxr-xr-x 1 root      root                8103 Apr    8    2022    zgrep
-rwxr-xr-x 1 root      root                2081 Apr    8    2022    zforce
-rwxr-xr-x 1 root      root                    29 Apr    8    2022    zfgrep
-rwxr-xr-x 1 root      root                    29 Apr    8    2022    zegrep
-rwxr-xr-x 1 root      root                5898 Apr    8    2022    zdiff
-rwxr-xr-x 1 root      root                1678 Apr    8    2022    zcmp
-rwxr-xr-x 1 root      root                1984 Apr    8    2022    zcat
-rwxr-xr-x 2 root      root                2346 Apr    8    2022    uncompress
-rwxr-xr-x 1 root      root              97496 Apr    8    2022    gzip
-rwxr-xr-x 1 root      root                6447 Apr    8    2022    gzexe
-rwxr-xr-x 2 root      root                2346 Apr    8    2022    gunzip
-rwxr-xr-x 1 root      root                2161 Apr    8    2022    xzmore
-rwxr-xr-x 1 root      root                1802 Apr    8    2022    xzless
-rwxr-xr-x 1 root      root                5902 Apr    8    2022    xzgrep
lrwxrwxrwx 1 root      root                      6 Apr    8    2022    xzfgrep ->
xzgrep
lrwxrwxrwx 1 root      root                      6 Apr    8    2022    xzegrep ->
xzgrep
-rwxr-xr-x 1 root      root                6632 Apr    8    2022    xzdiff
lrwxrwxrwx 1 root      root                      6 Apr    8    2022    xzcmp ->
xzdiff
lrwxrwxrwx 1 root      root                      2 Apr    8    2022    xzcat -> xz
-rwxr-xr-x 1 root      root              80384 Apr    8    2022    xz
lrwxrwxrwx 1 root      root                      2 Apr    8    2022    unxz -> xz
-rwxr-xr-x 1 root      root              14568 Apr    8    2022    lzmainfo
lrwxrwxrwx 1 root      root                      4 Apr 18 09:14    rbash -> bash
-rwxr-xr-x 1 root      root              14568 Apr 18 09:14    clear_console
-rwxr-xr-x 1 root      root                6794 Apr 18 09:14    bashbug
-rwxr-xr-x 1 root      root          1183448 Apr 18 09:14    bash
-rwxr-xr-x 1 root      root            941264 Apr 21 12:54    udevadm
-rwxr-xr-x 1 root      root              47328 Apr 21 12:54    timedatectl
lrwxrwxrwx 1 root      root                    13 Apr 21 12:54    systemd-umount ->
systemd-mount
-rwxr-xr-x 1 root      root              30944 Apr 21 12:54    systemd-tty-ask-
password-agent
-rwxr-xr-x 1 root      root              88480 Apr 21 12:54    systemd-tmpfiles
-rwxr-xr-x 1 root      root              55824 Apr 21 12:54    systemd-sysusers
-rwxr-xr-x 1 root      root              22760 Apr 21 12:54    systemd-stdio-bridge
-rwxr-xr-x 1 root      root              26848 Apr 21 12:54    systemd-socket-
activate
-rwxr-xr-x 1 root      root              59824 Apr 21 12:54    systemd-run
lrwxrwxrwx 1 root      root                    10 Apr 21 12:54    systemd-resolve ->
resolvectl
-rwxr-xr-x 1 root      root              18656 Apr 21 12:54    systemd-path
-rwxr-xr-x 1 root      root              18664 Apr 21 12:54    systemd-notify
-rwxr-xr-x 1 root      root              51664 Apr 21 12:54    systemd-mount
-rwxr-xr-x 1 root      root              26952 Apr 21 12:54    systemd-machine-id-
setup
-rwxr-xr-x 1 root      root              22776 Apr 21 12:54    systemd-inhibit
-rwxr-xr-x 1 root      root              22752 Apr 21 12:54    systemd-id128
-rwxr-xr-x 1 root      root            109072 Apr 21 12:54    systemd-hwdb
-rwxr-xr-x 1 root      root              22752 Apr 21 12:54    systemd-escape
-rwxr-xr-x 1 root      root              18656 Apr 21 12:54    systemd-detect-virt
-rwxr-xr-x 1 root      root              26848 Apr 21 12:54    systemd-delta
-rwxr-xr-x 1 root      root              39160 Apr 21 12:54    systemd-cgtop
-rwxr-xr-x 1 root      root              22864 Apr 21 12:54    systemd-cgls
-rwxr-xr-x 1 root      root              18664 Apr 21 12:54    systemd-cat
-rwxr-xr-x 1 root      root              14680 Apr 21 12:54    systemd-ask-password
-rwxr-xr-x 1 root      root          1587584 Apr 21 12:54    systemd-analyze
lrwxrwxrwx 1 root      root                    20 Apr 21 12:54    systemd ->
/lib/systemd/systemd
-rwxr-xr-x 1 root      root            996584 Apr 21 12:54    systemctl
-rwxr-xr-x 1 root      root            129408 Apr 21 12:54    resolvectl
-rwxr-xr-x 1 root      root              76008 Apr 21 12:54    networkctl
-rwxr-xr-x 1 root      root              59736 Apr 21 12:54    loginctl
-rwxr-xr-x 1 root      root              26848 Apr 21 12:54    localectl
-rwxr-xr-x 1 root      root              80120 Apr 21 12:54    journalctl
-rwxr-xr-x 1 root      root              26848 Apr 21 12:54    hostnamectl
-rwxr-xr-x 1 root      root              88416 Apr 21 12:54    busctl
-rwxr-xr-x 1 root      root              63840 Apr 21 12:54    bootctl
-rwxr-xr-x 1 root      root              14480 Apr 29 12:03    dbus-uuidgen
-rwxr-xr-x 1 root      root              14480 Apr 29 12:03    dbus-update-
activation-environment
-rwxr-xr-x 1 root      root              30864 Apr 29 12:03    dbus-send
-rwxr-xr-x 1 root      root              14480 Apr 29 12:03    dbus-run-session
-rwxr-xr-x 1 root      root              30864 Apr 29 12:03    dbus-monitor
-rwxr-xr-x 1 root      root            249032 Apr 29 12:03    dbus-daemon
-rwxr-xr-x 1 root      root              14480 Apr 29 12:03    dbus-cleanup-sockets
-rwxr-xr-x 1 root      root              20185 May    4 13:49    networkd-dispatcher
lrwxrwxrwx 1 root      root                    10 May 10 13:23    ubuntu-bug ->
apport-bug
-rwxr-xr-x 1 root      root                8573 May 10 13:23    oem-getlogs
-rwxr-xr-x 1 root      root                2068 May 10 13:23    apport-unpack
lrwxrwxrwx 1 root      root                    10 May 10 13:23    apport-collect ->
apport-bug
-rwxr-xr-x 1 root      root              13367 May 10 13:23    apport-cli
lrwxrwxrwx 1 root      root                    25 May 11 04:38    ubuntu-core-
launcher -> ../lib/snapd/snap-confine
-rwxr-xr-x 1 root      root              43304 May 11 04:38    snapfuse
lrwxrwxrwx 1 root      root                    20 May 11 04:38    snapctl ->
../lib/snapd/snapctl
-rwxr-xr-x 1 root      root        24575600 May 11 04:38    snap
-rwxr-xr-x 1 root      root                2108 May 18 16:04    cloud-init-per
lrwxrwxrwx 1 root      root                    18 May 19 17:38    unattended-upgrades
-> unattended-upgrade
-rwxr-xr-x 1 root      root              99313 May 19 17:38    unattended-upgrade
-rwxr-xr-x 1 root      root              47504 May 24 13:08    apt-sortpkgs
-rwxr-xr-x 1 root      root              63960 May 24 13:08    apt-mark
-rwxr-xr-x 1 root      root              27931 May 24 13:08    apt-key
-rwxr-xr-x 1 root      root              47576 May 24 13:08    apt-get
-rwxr-xr-x 1 root      root            281056 May 24 13:08    apt-ftparchive
-rwxr-xr-x 1 root      root              27104 May 24 13:08    apt-extracttemplates
-rwxr-xr-x 1 root      root              27016 May 24 13:08    apt-config
-rwxr-xr-x 1 root      root              31192 May 24 13:08    apt-cdrom
-rwxr-xr-x 1 root      root              88536 May 24 13:08    apt-cache
-rwxr-xr-x 1 root      root              18824 May 24 13:08    apt
-rwxr-xr-x 1 root      root              55712 May 25 11:14    update-alternatives
-rwxr-xr-x 1 root      root              84472 May 25 11:14    dpkg-trigger
-rwxr-xr-x 1 root      root              63760 May 25 11:14    dpkg-statoverride
-rwxr-xr-x 1 root      root            125424 May 25 11:14    dpkg-split
-rwxr-xr-x 1 root      root            166488 May 25 11:14    dpkg-query
-rwxr-xr-x 1 root      root              20514 May 25 11:14    dpkg-maintscript-
helper
-rwxr-xr-x 1 root      root            154208 May 25 11:14    dpkg-divert
-rwxr-xr-x 1 root      root            178728 May 25 11:14    dpkg-deb
-rwxr-xr-x 1 root      root            309944 May 25 11:14    dpkg
-rwxr-xr-x 1 root      root              14656 Jun    2 00:59    lsattr
-rwxr-xr-x 1 root      root              14656 Jun    2 00:59    chattr
-rwxr-xr-x 1 root      root              56104 Jun    6 18:09    ntfswipe
-rwxr-xr-x 1 root      root              39096 Jun    6 18:09    ntfsusermap
-rwxr-xr-x 1 root      root              43200 Jun    6 18:09    ntfstruncate
-rwxr-xr-x 1 root      root              97024 Jun    6 18:09    ntfssecaudit
-rwxr-xr-x 1 root      root            121096 Jun    6 18:09    ntfsrecover
-rwxr-xr-x 1 root      root              39176 Jun    6 18:09    ntfsmove
-rwxr-xr-x 1 root      root              36184 Jun    6 18:09    ntfsls
-rwxr-xr-x 1 root      root              59672 Jun    6 18:09    ntfsinfo
-rwxr-xr-x 1 root      root              47376 Jun    6 18:09    ntfsfix
-rwxr-xr-x 1 root      root              39184 Jun    6 18:09    ntfsfallocate
-rwxr-xr-x 1 root      root              51480 Jun    6 18:09    ntfsdecrypt
-rwxr-xr-x 1 root      root              39176 Jun    6 18:09    ntfscmp
-rwxr-xr-x 1 root      root              39176 Jun    6 18:09    ntfscluster
-rwxr-xr-x 1 root      root              35080 Jun    6 18:09    ntfscat
-rwxr-xr-x 1 root      root              14568 Jun    6 18:09    ntfs-3g.probe
-rwxr-xr-x 1 root      root            162704 Jun    6 18:09    ntfs-3g
-rwxr-xr-x 1 root      root            121712 Jun    6 18:09    lowntfs-3g
-rwxr-xr-x 1 root      root              26856 Jun 14 13:30    rotatelogs
-rwxr-xr-x 1 root      root              14496 Jun 14 13:30    logresolve
-rwxr-xr-x 1 root      root              26776 Jun 14 13:30    htpasswd
-rwxr-xr-x 1 root      root              14488 Jun 14 13:30    htdigest
-rwxr-xr-x 1 root      root              26776 Jun 14 13:30    htdbm
-rwxr-xr-x 1 root      root              39072 Jun 14 13:30    htcacheclean
-rwxr-xr-x 1 root      root              14488 Jun 14 13:30    fcgistarter
-rwxr-xr-x 1 root      root              14488 Jun 14 13:30    checkgid
-rwxr-xr-x 1 root      root              59736 Jun 14 13:30    ab
-rwxr-xr-x 1 root      root                  394 Jun 15 16:34    cloud-init
-rwxr-xr-x 1 root      root                  390 Jun 15 16:34    cloud-id
-rwxr-xr-x 1 root      root          5502744 Jun 22 20:18    python3.8
-rwxr-xr-x 1 root      root              21535 Jun 22 20:18    pygettext3.8
-rwxr-xr-x 1 root      root                    79 Jun 22 20:18    pydoc3.8
lrwxrwxrwx 1 root      root                    23 Jun 22 20:18    pdb3.8 ->
../lib/python3.8/pdb.py
-rwxr-xr-x 1 root      root            753336 Jul    4 11:24    openssl
-rwxr-xr-x 1 root      root                6806 Jul    4 11:24    c_rehash
-rwxr-xr-x 1 root      root              18744 Jul    4 16:20    watchgnupg
-rwxr-xr-x 1 root      root            125984 Jul    4 16:20    symcryptrun
-rwxr-xr-x 1 root      root            179168 Jul    4 16:20    kbxutil
-rwxr-xr-x 1 root      root            457880 Jul    4 16:20    gpgv
-rwxr-xr-x 1 root      root            155264 Jul    4 16:20    gpgtar
-rwxr-xr-x 1 root      root              88840 Jul    4 16:20    gpgsplit
-rwxr-xr-x 1 root      root            519416 Jul    4 16:20    gpgsm
-rwxr-xr-x 1 root      root              35200 Jul    4 16:20    gpgparsemail
-rwxr-xr-x 1 root      root            178848 Jul    4 16:20    gpgconf
-rwxr-xr-x 1 root      root            895272 Jul    4 16:20    gpgcompose
-rwxr-xr-x 1 root      root                3516 Jul    4 16:20    gpg-zip
-rwxr-xr-x 1 root      root            208072 Jul    4 16:20    gpg-wks-server
-rwxr-xr-x 1 root      root            167072 Jul    4 16:20    gpg-connect-agent
-rwxr-xr-x 1 root      root            418856 Jul    4 16:20    gpg-agent
-rwxr-xr-x 1 root      root          1066992 Jul    4 16:20    gpg
-rwxr-xr-x 1 root      root            121920 Jul    4 16:20    dirmngr-client
-rwxr-xr-x 1 root      root            583536 Jul    4 16:20    dirmngr
lrwxrwxrwx 1 root      root                      3 Jul    5 15:13    git-upload-pack
-> git
lrwxrwxrwx 1 root      root                      3 Jul    5 15:13    git-upload-
archive -> git
-rwxr-xr-x 1 root      root          1773344 Jul    5 15:13    git-shell
lrwxrwxrwx 1 root      root                      3 Jul    5 15:13    git-receive-pack
-> git
-rwxr-xr-x 1 root      root          3097168 Jul    5 15:13    git
-rwxr-xr-x 1 root      root                  445 Jul 12 18:09    ubuntu-advantage
lrwxrwxrwx 1 root      root                    16 Jul 12 18:09    ua -> ubuntu-
advantage
-rwxr-xr-x 1 root      root                  372 Jul 19 05:41    pyjwt3
lrwxrwxrwx 1 root      root                    22 Jul 24 21:38    nawk ->
/etc/alternatives/nawk
lrwxrwxrwx 1 root      root                    21 Jul 24 21:38    awk ->
/etc/alternatives/awk
lrwxrwxrwx 1 root      root                    19 Jul 24 21:38    w ->
/etc/alternatives/w
lrwxrwxrwx 1 root      root                      4 Jul 24 21:38    sh -> dash
lrwxrwxrwx 1 root      root                    23 Jul 24 21:38    pager ->
/etc/alternatives/pager
lrwxrwxrwx 1 root      root                    24 Jul 24 21:38    unlzma ->
/etc/alternatives/unlzma
lrwxrwxrwx 1 root      root                    24 Jul 24 21:38    lzmore ->
/etc/alternatives/lzmore
lrwxrwxrwx 1 root      root                    22 Jul 24 21:38    lzma ->
/etc/alternatives/lzma
lrwxrwxrwx 1 root      root                    24 Jul 24 21:38    lzless ->
/etc/alternatives/lzless
lrwxrwxrwx 1 root      root                    24 Jul 24 21:38    lzgrep ->
/etc/alternatives/lzgrep
lrwxrwxrwx 1 root      root                    25 Jul 24 21:38    lzegrep ->
/etc/alternatives/lzegrep
lrwxrwxrwx 1 root      root                    24 Jul 24 21:38    lzdiff ->
/etc/alternatives/lzdiff
lrwxrwxrwx 1 root      root                    23 Jul 24 21:38    lzcmp ->
/etc/alternatives/lzcmp
lrwxrwxrwx 1 root      root                    23 Jul 24 21:38    lzcat ->
/etc/alternatives/lzcat
lrwxrwxrwx 1 root      root                    25 Jul 24 21:38    lzfgrep ->
/etc/alternatives/lzfgrep
lrwxrwxrwx 1 root      root                    24 Jul 24 21:38    netcat ->
/etc/alternatives/netcat
lrwxrwxrwx 1 root      root                    20 Jul 24 21:38    nc ->
/etc/alternatives/nc
lrwxrwxrwx 1 root      root                    23 Jul 24 21:38    rview ->
/etc/alternatives/rview
lrwxrwxrwx 1 root      root                    20 Jul 24 21:38    vi ->
/etc/alternatives/vi
lrwxrwxrwx 1 root      root                    22 Jul 24 21:38    view ->
/etc/alternatives/view
lrwxrwxrwx 1 root      root                    20 Jul 24 21:38    ex ->
/etc/alternatives/ex
lrwxrwxrwx 1 root      root                    24 Jul 24 21:38    editor ->
/etc/alternatives/editor
lrwxrwxrwx 1 root      root                    20 Jul 24 21:39    mt ->
/etc/alternatives/mt
lrwxrwxrwx 1 root      root                    24 Jul 24 21:39    telnet ->
/etc/alternatives/telnet
lrwxrwxrwx 1 root      root                    23 Jul 24 21:39    write ->
/etc/alternatives/write
lrwxrwxrwx 1 root      root                    22 Jul 24 21:39    from ->
/etc/alternatives/from
lrwxrwxrwx 1 root      root                    22 Jul 24 21:39    pftp ->
/etc/alternatives/pftp
lrwxrwxrwx 1 root      root                    21 Jul 24 21:39    ftp ->
/etc/alternatives/ftp
lrwxrwxrwx 1 root      root                    22 Jul 24 21:39    pico ->
/etc/alternatives/pico
lrwxrwxrwx 1 root      root                    29 Jul 24 21:39    infobrowser ->
/etc/alternatives/infobrowser
lrwxrwxrwx 1 root      root                    29 Jul 24 21:39    traceroute6 ->
/etc/alternatives/traceroute6
lrwxrwxrwx 1 root      root                    26 Jul 24 21:39    pinentry ->
/etc/alternatives/pinentry
lrwxrwxrwx 1 root      root                    26 Jul 24 21:39    jsondiff ->
/etc/alternatives/jsondiff
lrwxrwxrwx 1 root      root                    21 Jul 24 21:40    vim ->
/etc/alternatives/vim
lrwxrwxrwx 1 root      root                    25 Jul 24 21:40    vimdiff ->
/etc/alternatives/vimdiff
lrwxrwxrwx 1 root      root                    22 Jul 24 21:40    rvim ->
/etc/alternatives/rvim
lrwxrwxrwx 1 root      root                    21 Jul 24 21:40    rsh ->
/etc/alternatives/rsh
lrwxrwxrwx 1 root      root                    24 Jul 24 21:40    rlogin ->
/etc/alternatives/rlogin
lrwxrwxrwx 1 root      root                    21 Jul 24 21:40    rcp ->
/etc/alternatives/rcp
-rwxr-xr-x 1 root      root              57752 Aug 16 13:23    vmware-xferlogs
-rwxr-xr-x 1 root      root              23264 Aug 16 13:23    vmware-vmblock-fuse
-rwxr-xr-x 1 root      root              18744 Aug 16 13:23    vmware-vgauth-cmd
-rwxr-xr-x 1 root      root              60000 Aug 16 13:23    vmware-toolbox-cmd
-rwxr-xr-x 1 root      root              31032 Aug 16 13:23    vmware-rpctool
-rwxr-xr-x 1 root      root              22840 Aug 16 13:23    vmware-namespace-cmd
-rwxr-xr-x 1 root      root              14720 Aug 16 13:23    vmware-hgfsclient
-rwxr-xr-x 1 root      root              14720 Aug 16 13:23    vmware-checkvm
-rwxr-xr-x 1 root      root              72224 Aug 16 13:23    vmware-alias-import
-rwxr-xr-x 1 root      root              76352 Aug 16 13:23    vmtoolsd
-rwxr-xr-x 1 root      root              56112 Aug 16 13:23    vmhgfs-fuse
-rwxr-xr-x 1 root      root              10623 Aug 16 13:23    vm-support
-rwxr-xr-x 1 root      root            141856 Aug 16 13:23    VGAuthService
-rwxr-xr-x 1 root      root            508568 Aug 16 18:48    rsync
lrwxrwxrwx 1 root      root                    29 Aug 16 18:48    rrsync ->
../share/rsync/scripts/rrsync
-rwxr-xr-x 1 root      root              10227 Aug 19 18:14    do-release-upgrade
-rwxr-xr-x 1 root      root              14496 Aug 22 10:54    locale-check
-rwxr-xr-x 1 root      root            239848 Aug 31 19:18    curl
lrwxrwxrwx 1 root      root                    26 Sep    4 13:31    updatedb ->
/etc/alternatives/updatedb
lrwxrwxrwx 1 root      root                    24 Sep    4 13:31    locate ->
/etc/alternatives/locate
lrwxrwxrwx 1 root      root                    22 Sep    7 08:02    java ->
/etc/alternatives/java
lrwxrwxrwx 1 root      root                    21 Sep    7 08:02    jjs ->
/etc/alternatives/jjs
lrwxrwxrwx 1 root      root                    25 Sep    7 08:02    keytool ->
/etc/alternatives/keytool
lrwxrwxrwx 1 root      root                    22 Sep    7 08:02    rmid ->
/etc/alternatives/rmid
lrwxrwxrwx 1 root      root                    29 Sep    7 08:02    rmiregistry ->
/etc/alternatives/rmiregistry
lrwxrwxrwx 1 root      root                    25 Sep    7 08:02    pack200 ->
/etc/alternatives/pack200
lrwxrwxrwx 1 root      root                    27 Sep    7 08:02    unpack200 ->
/etc/alternatives/unpack200
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    jexec ->
/etc/alternatives/jexec
lrwxrwxrwx 1 root      root                    21 Sep    7 08:02    jar ->
/etc/alternatives/jar
lrwxrwxrwx 1 root      root                    27 Sep    7 08:02    jarsigner ->
/etc/alternatives/jarsigner
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    javac ->
/etc/alternatives/javac
lrwxrwxrwx 1 root      root                    25 Sep    7 08:02    javadoc ->
/etc/alternatives/javadoc
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    javap ->
/etc/alternatives/javap
lrwxrwxrwx 1 root      root                    22 Sep    7 08:02    jcmd ->
/etc/alternatives/jcmd
lrwxrwxrwx 1 root      root                    21 Sep    7 08:02    jdb ->
/etc/alternatives/jdb
lrwxrwxrwx 1 root      root                    27 Sep    7 08:02    jdeprscan ->
/etc/alternatives/jdeprscan
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    jdeps ->
/etc/alternatives/jdeps
lrwxrwxrwx 1 root      root                    21 Sep    7 08:02    jfr ->
/etc/alternatives/jfr
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    jinfo ->
/etc/alternatives/jinfo
lrwxrwxrwx 1 root      root                    24 Sep    7 08:02    jimage ->
/etc/alternatives/jimage
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    jlink ->
/etc/alternatives/jlink
lrwxrwxrwx 1 root      root                    22 Sep    7 08:02    jmap ->
/etc/alternatives/jmap
lrwxrwxrwx 1 root      root                    22 Sep    7 08:02    jmod ->
/etc/alternatives/jmod
lrwxrwxrwx 1 root      root                    21 Sep    7 08:02    jps ->
/etc/alternatives/jps
lrwxrwxrwx 1 root      root                    28 Sep    7 08:02    jrunscript ->
/etc/alternatives/jrunscript
lrwxrwxrwx 1 root      root                    24 Sep    7 08:02    jshell ->
/etc/alternatives/jshell
lrwxrwxrwx 1 root      root                    24 Sep    7 08:02    jstack ->
/etc/alternatives/jstack
lrwxrwxrwx 1 root      root                    24 Sep    7 08:02    jstatd ->
/etc/alternatives/jstatd
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    jstat ->
/etc/alternatives/jstat
lrwxrwxrwx 1 root      root                    22 Sep    7 08:02    rmic ->
/etc/alternatives/rmic
lrwxrwxrwx 1 root      root                    27 Sep    7 08:02    serialver ->
/etc/alternatives/serialver
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    jaotc ->
/etc/alternatives/jaotc
lrwxrwxrwx 1 root      root                    23 Sep    7 08:02    jhsdb ->
/etc/alternatives/jhsdb
lrwxrwxrwx 1 root      root                    26 Sep    7 08:02    jconsole ->
/etc/alternatives/jconsole
-rw-r--r-- 1 root      root                      0 Sep    8 08:47    setenv.sh
-rw-r--r-- 1 root      root                      0 Sep    8 08:48    seten.sh
lrwxrwxrwx 1 root      root                    21 Sep    8 10:05    sar ->
/etc/alternatives/sar
-rwxr-xr-x 1 root      root              18712 Sep 19 04:59    xxd
-rwxr-xr-x 1 root      root                2121 Sep 19 04:59    vimtutor
-rwxr-xr-x 1 root      root          1349848 Sep 19 04:59    vim.tiny
-rwxr-xr-x 1 root      root          2906824 Sep 19 04:59    vim.basic
-rwxr-xr-x 1 root      root                1057 Sep 19 12:32    sosreport
-rwxr-xr-x 1 root      root                1065 Sep 19 12:32    sos-collector
-rwxr-xr-x 1 root      root                  596 Sep 19 12:32    sos
-rwxr-xr-x 1 root      root              72216 Sep 20 12:05    nsupdate
-rwxr-xr-x 1 root      root            109360 Sep 20 12:05    nslookup
-rwxr-xr-x 1 root      root              51608 Sep 20 12:05    mdig
-rwxr-xr-x 1 root      root            105232 Sep 20 12:05    host
-rwxr-xr-x 1 root      root            138032 Sep 20 12:05    dig
-rwxr-xr-x 1 root      root              49552 Sep 20 12:05    delv
lrwxrwxrwx 1 root      root                    20 Sep 21 08:32    js ->
/etc/alternatives/js
ansadmin@svl200:/bin$ ls -lrt | tomcat

Command 'tomcat' not found, did you mean:

    command 'topcat' from deb topcat (4.7-2)

Try: apt install <deb name>

ansadmin@svl200:/bin$ ls -lrt | grep tomcat


ansadmin@svl200:/bin$
Network error: Software caused connection abort

─────────────────────────────────────────────────────────────────────────────────────
─────────────────────────────────────────────────────────────────────────────────────
───────────────────────────────────

Session stopped
        - Press <return> to exit tab
        - Press R to restart session
        - Press S to save terminal output to file

You might also like