Skip to content

Latest commit

 

History

History
126 lines (90 loc) · 4.04 KB

Getting_Started.md

File metadata and controls

126 lines (90 loc) · 4.04 KB

Home

Pterodactyl

Getting Started

Follow these steps to set up and run the project:

1. Clone the Repository

git clone https://github.com/rikosintie/Discovery.git
cd Discovery

If you don't have git installed, you can download the zip file from the repository. Click on the green "Code" button and select "Download ZIP". Then unzip the file.

Github ZIP file

NOTE: Once you have the repository cloned it is linked to the repository on github.com. You should issue a git pull once in a while to pull down any changes that have been made to the repository.

2. Create a Virtual Environment

python -m venv venv --upgrade-deps --prompt="Discovery"

This will create the standard "venv" directory but when activated will display "Discovery". I prefer this over using python -m venv Discovery because it's the standard way to create the virtual environment. But I like seeing Discovery instead of venv when I activate the environment.

The --upgrade-deps argument tells python to upgrade pip to the latest version when creating the virtual environment. You need internet access for pip to be upgraded. If you don't have internet access, remove the --upgrade-deps argument.

3. Activate the Virtual Environment

On Windows

.\venv\Scripts\activate

On macOS/Linux

source venv/bin/activate

Here is what my terminal looks like after activating:

venv

4. Install Dependencies

You can use pip list to list the packages currently installed. If you run it now you will see:

$ pip list
Package    Version
---------- -------
pip        23.3.2
setuptools 69.0.3

Now run the following:

pip install -r requirements.txt

You will see all the dependencies being downloaded and installed. Here is a snippet of the dependencies.

$ pip install -r requirements.txt
Collecting asttokens~=2.4.1 (from -r requirements.txt (line 1))
  Downloading asttokens-2.4.1-py2.py3-none-any.whl.metadata (5.2 kB)
Collecting bcrypt~=4.1.2 (from -r requirements.txt (line 2))
  Downloading bcrypt-4.1.2-cp39-abi3-manylinux_2_28_x86_64.whl.metadata (9.5 kB)

Now if we run pip list we will see that the dependencies have been installed:

$ pip list
Package       Version
------------- -------
asttokens     2.4.1
bcrypt        4.1.2
cffi          1.16.0
colorama      0.4.6
cryptography  41.0.7
executing     2.0.1
future        0.18.3
icecream      2.1.3
netmiko       4.3.0
ntc_templates 4.1.0
paramiko      3.4.0
pip           23.3.2
prettytable   3.9.0
pycparser     2.21
Pygments      2.17.2
PyNaCl        1.5.0
pyserial      3.5
PyYAML        6.0.1
scp           0.14.5
setuptools    69.0.3
six           1.16.0
textfsm       1.1.3
wcwidth       0.2.12

5. Deactivate the Virtual Environment

When you are finished, deactivate the environment

deactivate

You will need to activate the virtual environment each time you want to run the scripts.


Home - Usage - The Helper Scripts