Ausgaben separate Blöcke

Michael Schaar 2023-09-21 13:48:14 +02:00
parent 35605d4a54
commit db2970c0f9
1 changed files with 13 additions and 3 deletions

@ -18,7 +18,7 @@ foo RUNNING 0 - 10.0.3.110 - false
Mit der IP kann man sich via ssh einlogen: Mit der IP kann man sich via ssh einlogen:
``` ```
ssh ubuntu@10.0.3.110 ssh ubuntu@10.0.3.110 # Mit exit wieder zurück auf rdf-dev
sudo lxc-create --name baa --template ubuntu sudo lxc-create --name baa --template ubuntu
sudo lxc-start --name baa sudo lxc-start --name baa
sudo lxc-ls --fancy sudo lxc-ls --fancy
@ -37,7 +37,7 @@ whatis nmap
nmap (1) - Netzwerk-Analysewerkzeug und Sicherheits-/Portscanner nmap (1) - Netzwerk-Analysewerkzeug und Sicherheits-/Portscanner
``` ```
```bash ```bash
ssh ubuntu@10.0.3.110 ssh ubuntu@10.0.3.110 # Mit exit zurück
dig @10.0.3.1 foo dig @10.0.3.1 foo
ping -c 4 10.0.3.110 ping -c 4 10.0.3.110
ping -c 4 10.0.3.55 ping -c 4 10.0.3.55
@ -52,6 +52,8 @@ ansible --version
cd ~/ansible_lxc_bsa2/ cd ~/ansible_lxc_bsa2/
vi inventory vi inventory
cat inventory cat inventory
```
```
[lokal] [lokal]
localhost ansible_connection=local localhost ansible_connection=local
``` ```
@ -65,6 +67,8 @@ ansible -i inventory -m ping lokal
sudo lxc-ls --fancy sudo lxc-ls --fancy
vi inventory vi inventory
cat inventory cat inventory
```
```
[lokal] [lokal]
localhost ansible_connection=local localhost ansible_connection=local
@ -77,6 +81,8 @@ localhost ansible_connection=local
ansible -i inventory -m ping notme ansible -i inventory -m ping notme
vi inventory vi inventory
cat inventory cat inventory
```
```
[lokal] [lokal]
localhost ansible_connection=local localhost ansible_connection=local
@ -84,17 +90,21 @@ localhost ansible_connection=local
10.0.3.110 ansible_user=ubuntu 10.0.3.110 ansible_user=ubuntu
10.0.3.55 ansible_user=ubuntu 10.0.3.55 ansible_user=ubuntu
``` ```
```bash ```bash
ansible -i inventory -m ping notme ansible -i inventory -m ping notme
vi inventory vi inventory
cat inventory cat inventory
```
```
[lokal] [lokal]
localhost ansible_connection=local localhost ansible_connection=local
[notme] [notme]
10.0.3.110 ansible_user=ubuntu ansible_password=ubuntu 10.0.3.110 ansible_user=ubuntu ansible_password=ubuntu
10.0.3.55 ansible_user=ubuntu ansible_password=ubuntu 10.0.3.55 ansible_user=ubuntu ansible_password=ubuntu
```
```bash
ansible -i inventory -m ping notme ansible -i inventory -m ping notme
ansible -i inventory -m ping all ansible -i inventory -m ping all
``` ```