Skip to content

Commit

Permalink
Merge pull request #72 from jeremypng/jeremypng-issue63
Browse files Browse the repository at this point in the history
Issue 63 - pass secret to NetdevKeeper
  • Loading branch information
dgarros authored Jul 28, 2020
2 parents d38343d + d053df4 commit 94988c8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion netbox_onboarding/worker.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ def onboard_device(task_id, credentials):
"""Process a single OnboardingTask instance."""
username = credentials.username
password = credentials.password
secret = credentials.secret

try:
ot = OnboardingTask.objects.get(id=task_id)
Expand All @@ -43,7 +44,7 @@ def onboard_device(task_id, credentials):
ot.status = OnboardingStatusChoices.STATUS_RUNNING
ot.save()

netdev = NetdevKeeper(ot, username, password)
netdev = NetdevKeeper(ot, username, password, secret)
nbk = NetboxKeeper(netdev=netdev)

netdev.get_required_info()
Expand Down

0 comments on commit 94988c8

Please sign in to comment.