What do you want to save?
Add Code snippet
New code examples
-
Other 2022-03-19 11:35:22
save router config with ansible
---- hosts: router gather_facts: false vars: git_branch: /etc/ansible/playbooks/backuptasks:---- hosts: router gather_facts: false vars: git_branch: /etc/ansible/playbooks/backuptasks: - name: switch to target branch command: git checkout &q... Add solution -
Python 2021-11-20 06:41:11
netmiko add timeout with command
from netmiko import ConnectHandler import time start_time = time.time() cisco = { 'device_type': 'cisco_ios', 'host': '10.196.1.73', 'username': 'ansible', 'password': 'XXX', } print("init connection") ssh_conn = ConnectH... Add solution -
Other 2021-11-18 16:41:18
install ansible on linux
On Fedora: $ sudo dnf install ansible On RHEL and CentOS: $ sudo yum install ansible On Ubuntu: $ sudo apt-add-repository --yes --update ppa:ansible/ansible $ sudo apt install ansible Using PIP: $ pip install --user ansible On Alpine: $ apk add ansibl... Add solution