Installing Custom Python Modules
You can run Python custom scripts under Python 3. To install custom Python modules, first install pip into the sandbox:
#wget https://bootstrap.pypa.io/get-pip.py
#python3 get-pip.py
You can correct the URL to get-pip.py
to the apropriate one from bootstrap.pypa.io
.
After that, use the standard pip utility:
#pip install package_name
If there is no Internet connection on the sandbox, use SCP to send the file into the /Backup/Sandbox directory in the administrative shell:
scp get-pip.py admin@172.23.28.2:/Backup/Sandbox
In the administrative shell, the /Backup/Sandbox directory maps to the /mnt/host/data/userdata directory inside the sandbox. After the file is successfully uploaded to the sandbox, log in to the sandbox via the administrative shell:
sandbox login
Once inside the sandbox, use the standard installation procedure to install the script or modules located at /mnt/host/data/userdata:
#cd /mnt/host/data/userdata
#python3 get-pip.py
#pip install package_name