Controle Ansible
This commit is contained in:
parent
9f54ccac36
commit
2d596d22f5
370
sio2/sisr/ct-ansible/.bash_history
Normal file
370
sio2/sisr/ct-ansible/.bash_history
Normal file
@ -0,0 +1,370 @@
|
||||
apt install vim curl mc sudo
|
||||
apt autoclean
|
||||
apt autoremove
|
||||
poweroff
|
||||
ip a
|
||||
ip l
|
||||
ip n
|
||||
ip r
|
||||
poweroff
|
||||
apt update
|
||||
apt upgrade
|
||||
poweroff
|
||||
apt install -y git-core
|
||||
poweroff
|
||||
apt update
|
||||
apt upgrade -y
|
||||
poweroff
|
||||
nano .bashrc
|
||||
vi /etc/hosts
|
||||
nano .bashrc
|
||||
poweroff
|
||||
ip r
|
||||
poweroff
|
||||
clr
|
||||
sed -i 's/bullseye/ansible/g' /etc/host{s,name}; reboot
|
||||
clr
|
||||
maj
|
||||
nano .bashrc
|
||||
maj
|
||||
apt install -y ansible
|
||||
ansible --version
|
||||
ssh-keygen
|
||||
ls -lh -ssh
|
||||
echo 'PermitRootLogin yes' >> /etc/ssh/sshd_config
|
||||
systemctl restart ssh
|
||||
nano /ssh/config
|
||||
ip -br a
|
||||
poweroff
|
||||
clr
|
||||
ip -br a
|
||||
poweroff
|
||||
clr'
|
||||
clr
|
||||
nano ~/.ssh/config
|
||||
nano ~/.ssh/config
|
||||
ip -br a
|
||||
nano ~/.ssh/config
|
||||
ssh-copy-id infra
|
||||
ssh infra uptime
|
||||
ssh-copy-id infra
|
||||
ssh-copy-id web1
|
||||
ssh-copy-id web2
|
||||
ls
|
||||
ssh infra uptime
|
||||
rmdir testansible
|
||||
mkdir testansible
|
||||
ls
|
||||
cd testansible/
|
||||
ls
|
||||
nano hosts
|
||||
cd
|
||||
ansible all -i hosts -m ping
|
||||
cd testansible/
|
||||
ansible all -i hosts -m ping
|
||||
ansible web -i hosts -m shell -a uptime
|
||||
ansible web -i hosts -m setup | more
|
||||
cd
|
||||
mkdir tpansible
|
||||
cd tpansible/
|
||||
ls
|
||||
nano web.yml
|
||||
nano web.yml
|
||||
nano web.yml
|
||||
pwd
|
||||
nano web.yml
|
||||
ansible-playbook -i hosts web.yml
|
||||
nano web.yml
|
||||
ansible-playbook -i hosts web.yml
|
||||
clr
|
||||
ansible-playbook -i hosts web.yml
|
||||
cd
|
||||
exit
|
||||
clr
|
||||
ip -br a
|
||||
clr
|
||||
ansible-playbook -i hosts web.yml
|
||||
ls
|
||||
cd tpansible/
|
||||
ls
|
||||
ansible-playbook -i hosts web.yml
|
||||
journalctl -xe
|
||||
clr
|
||||
journalctl -xe
|
||||
clr
|
||||
ansible-playbook -i hosts web.yml
|
||||
ls
|
||||
ansible-playbook -i hosts web.yml
|
||||
ansible all --list-hosts
|
||||
ls
|
||||
cd
|
||||
ls
|
||||
cd testansible/
|
||||
ls
|
||||
nano hosts
|
||||
cp hosts /root/tpansible/
|
||||
cd
|
||||
cd tpansible/
|
||||
ls
|
||||
clr
|
||||
ansible-playbook -i hosts web.yml
|
||||
ip a
|
||||
ip r
|
||||
host google.com
|
||||
ping google.com
|
||||
ansible-playbook -i hosts web.yml
|
||||
ansible-playbook -i hosts web.yml
|
||||
ls
|
||||
cd
|
||||
ls
|
||||
nano index.html
|
||||
cd tpansible/
|
||||
ansible-playbook -i hosts web.yml
|
||||
cd
|
||||
ls
|
||||
mv index.html tpansible/
|
||||
cd tpansible/
|
||||
ls
|
||||
ansible-playbook -i hosts web.yml
|
||||
cd
|
||||
clr
|
||||
mkdir syslog
|
||||
cd syslog/
|
||||
nano syslog.yml
|
||||
ls
|
||||
cd
|
||||
cd tpansible/
|
||||
ls
|
||||
cat hosts
|
||||
cp hosts /root/syslog/
|
||||
cd
|
||||
cd sys
|
||||
cd syslog/
|
||||
ls
|
||||
nano syslog.yml
|
||||
cd
|
||||
poweroff
|
||||
clear
|
||||
apt isntall squid
|
||||
apt install squid
|
||||
apt install squid
|
||||
apt update
|
||||
clear
|
||||
exit
|
||||
ip r
|
||||
exit
|
||||
clr
|
||||
poweroff
|
||||
clr
|
||||
history
|
||||
history| more
|
||||
history|more
|
||||
apt install -y ansible-doc
|
||||
ansible-doc user
|
||||
ansible-doc user
|
||||
ansible all -i hosts -m ping
|
||||
uptime
|
||||
ansible-lint
|
||||
ls
|
||||
ansible-lint testansible/
|
||||
apt install -y ansible-lint
|
||||
ansible-lint testansible/
|
||||
ansible-lint help
|
||||
ansible-lint -h
|
||||
ansible-lint -p testansible/
|
||||
poweroff
|
||||
clr
|
||||
history |more
|
||||
ls
|
||||
history |more
|
||||
ls
|
||||
cd testansible/
|
||||
ls
|
||||
cat hosts
|
||||
cdf
|
||||
cd
|
||||
ls
|
||||
cd tpansible/
|
||||
ls
|
||||
cat hosts
|
||||
cat index.html
|
||||
cat web.yml
|
||||
cd
|
||||
clr
|
||||
poweroff
|
||||
clr
|
||||
sed -i 's/ansible/ansible2/g' /etc/host{s,name};
|
||||
reboot
|
||||
poweroff
|
||||
history
|
||||
clr
|
||||
history |less
|
||||
ls
|
||||
clr
|
||||
ls
|
||||
cat squid/
|
||||
cd squid/
|
||||
ls
|
||||
cazt hosts
|
||||
cat hosts
|
||||
cat squid.yml
|
||||
cd
|
||||
clr
|
||||
ls
|
||||
nano ~/.ssh/config
|
||||
clr
|
||||
ip -br a
|
||||
nano ~./ssh/config
|
||||
nano ~/.ssh/config
|
||||
mkdir controleansible
|
||||
ls
|
||||
cd testansible/
|
||||
ls
|
||||
cat hosts
|
||||
clr
|
||||
ls
|
||||
cd
|
||||
ls
|
||||
cd tpansible/
|
||||
ls
|
||||
cd
|
||||
clr(
|
||||
clr
|
||||
cd controleansible/
|
||||
clr
|
||||
nano hosts
|
||||
ls
|
||||
nano user.yml
|
||||
nano user.yml
|
||||
nano resolv.conf
|
||||
ls
|
||||
clr
|
||||
nano user.yml
|
||||
nano user.yml
|
||||
cd
|
||||
ip -br a
|
||||
nano ~./ssh/config
|
||||
nano ~/.ssh/config
|
||||
cd controleansible/
|
||||
clr
|
||||
ls
|
||||
ansible-lint user.yml
|
||||
nano user.yml
|
||||
ansible-lint user.yml
|
||||
nano user.yml
|
||||
nano user.yml -l
|
||||
ansible-lint user.yml
|
||||
clr
|
||||
nano user.yml -l
|
||||
ansible-lint user.yml
|
||||
ls
|
||||
cat hosts
|
||||
clr
|
||||
ansible-playbook -i hosts user.yml
|
||||
nano hosts
|
||||
cd
|
||||
nano ~/.ssh/config
|
||||
cd controleansible/
|
||||
ls
|
||||
cat hosts
|
||||
ansible-playbook -i hosts user.yml
|
||||
nano user.yml
|
||||
ansible-playbook -i hosts user.yml
|
||||
clr
|
||||
ansible-playbook -i hosts user.yml
|
||||
nano user.yml
|
||||
clr
|
||||
cd
|
||||
clr
|
||||
git clone "https://gitea-lyc.lecastel.fr/ugo.idez/siotp.git
|
||||
git clone "https://gitea-lyc.lecastel.fr/ugo.idez/siotp.git"
|
||||
git clone "https://gitea.lyc-lecastel.fr/ugo.idez/siotp.git"
|
||||
clr
|
||||
cd
|
||||
clr
|
||||
ls
|
||||
cd siotp/
|
||||
ls
|
||||
cd sio1
|
||||
ls
|
||||
cd ..
|
||||
cd sio2
|
||||
ls
|
||||
mkdir ctrlansible
|
||||
cd
|
||||
clr
|
||||
cd controleansible/
|
||||
ls
|
||||
cd
|
||||
ls
|
||||
cd siotp
|
||||
cd sio2
|
||||
ls
|
||||
mv ctrlansible sisr/
|
||||
cd sisr/
|
||||
ls
|
||||
cd
|
||||
clr
|
||||
cd controleansible/
|
||||
ls
|
||||
cp hosts /siotp/sio2/sisr/cotrlansible
|
||||
cp hosts /root/siotp/sio2/sisr/ctrlansible
|
||||
cp resolv.conf /root/siotp/sio2/sisr/ctrlansible
|
||||
cp user.yml /root/siotp/sio2/sisr/ctrlansible
|
||||
cd
|
||||
clr
|
||||
cd siotp/sio2/sisr/
|
||||
ls
|
||||
cd ctrlansible/
|
||||
ls
|
||||
clr
|
||||
git add *
|
||||
git config --global user.email "ugo.idez@gmail.com"
|
||||
git config --global user.name "IDEZ Ugo"
|
||||
git tag
|
||||
git commit -am "Controle Ansible"
|
||||
git push
|
||||
git push --tag
|
||||
git status
|
||||
git log
|
||||
git show
|
||||
clr
|
||||
cd ..
|
||||
mv ctrlansible/ ct-ansible
|
||||
git add *
|
||||
git push
|
||||
git gommit -am "Controle ansible"
|
||||
git commit -am "Controle ansible"
|
||||
git push
|
||||
cd
|
||||
clr
|
||||
ls -al
|
||||
ls -a
|
||||
cat .bash_history
|
||||
cat .bash_history |less
|
||||
clr
|
||||
cd controleansible/
|
||||
clr
|
||||
ls
|
||||
ansible-playbook -i hosts user.yml
|
||||
cd
|
||||
nano /etc/ansible/hosts
|
||||
ansible -all m ping
|
||||
clr
|
||||
cd controleansible/
|
||||
ansible all -i hosts -m ping
|
||||
ssh srv
|
||||
clr
|
||||
ansible all -i hosts -m ping
|
||||
ssh srv
|
||||
clr
|
||||
ansible all -i hosts -m ping
|
||||
ansible all -i hosts -m ping
|
||||
nano user.yml
|
||||
ssh srv
|
||||
clr
|
||||
ssh srv
|
||||
clr
|
||||
ssh-copy-id srv
|
||||
clr
|
||||
exit
|
Loading…
x
Reference in New Issue
Block a user