Skip to content
This repository has been archived by the owner on Jun 25, 2020. It is now read-only.

Updated import & num_workers #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tools/network/backup/backup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import logging
import os

from nornir.core import InitNornir
from nornir import InitNornir
from nornir.plugins.functions.text import print_result
from nornir.plugins.tasks.files import write_file
from nornir.plugins.tasks.networking import napalm_get
Expand All @@ -26,12 +26,12 @@ def main(config, path, debug):
nr = InitNornir(
config_file=config,
dry_run=False,
num_workers=1 if debug else 20,
)
result = nr.run(
name="Backup configuration of devices",
task=backup,
path=path,
num_workers=1 if debug else 20,
)
print_result(
result,
Expand Down