In this lesson, we will cover:

  • How to install Scrapli.
  • How to validate your Scrapli installation.

You can find the scripts and code for this lesson within the Scrapli repo under the directory: 001_scrapli_fundamentals/.

Create Virtual Environment

Before installing Scrapli, we will create a virtual environment in which we will install Scrapli. By installing Scrapli within a virtual environment, we can ensure it (and all of its dependencies) are isolated from any other Python packages installed on the system.

# Create a new venv directory
mkdir venv

# Create a virtual environment
python3 -m venv venv/venv-scrapli

# Activate the virtual environment
source venv/venv-scrapli/bin/activate

Install Scrapli Core

Now we are inside our newly created virtual environment, we can install Scrapli. But first, let’s look at some of the ways Scrapli can be installed.

Scrapli Core – No Dependencies

To install only Scrapli Core, with no additional dependencies. If we only require Scrapli Core using the default system transport, we can perform:

$ pip3 install scrapli
Ready to Master Network Automation? Start Your Journey Today!
Our membership provides:
  • Full deep-dive course library (inc. Batfish, pyATS, Netmiko)
  • Code repositories inc. full course code, scripts and examples
  • 24x7 multi-vendor labs (Arista, Cisco, Juniper)
  • Private online community
  • Live monthly tech sessions
  • Access to tech session library

Join Now ➜
Close You've successfully subscribed to Packet Coders.
Close Success! Your account is fully activated, you now have access to all content.
Close Welcome back! You've successfully signed in.
Close Nearly there! To activate your account, please click the link in the email we just sent you.