__netbox: force virtualenv to be python3
Set a flag to be sure it is python3. Else, you may get an ugly error if python2 is not installed (and netbox requires python3.6 at minimum).
This commit is contained in:
parent
ee3db10ecf
commit
ae7ffac6bb
1 changed files with 2 additions and 1 deletions
|
@ -37,7 +37,8 @@ cp \$tmpdir/configuration.py '$install_dir/netbox/configuration.py'
|
||||||
cp \$tmpdir/ldap_config.py '$install_dir/netbox/ldap_config.py'
|
cp \$tmpdir/ldap_config.py '$install_dir/netbox/ldap_config.py'
|
||||||
|
|
||||||
# Setup & enter python virtualenv.
|
# Setup & enter python virtualenv.
|
||||||
virtualenv /opt/netbox/venv
|
# forcing python3 to be sure (till python4 gets released ..)
|
||||||
|
virtualenv -p python3 /opt/netbox/venv
|
||||||
|
|
||||||
# Install python dependencies.
|
# Install python dependencies.
|
||||||
/opt/netbox/venv/bin/pip3 install -r "\$tmpdir/$src/requirements.txt"
|
/opt/netbox/venv/bin/pip3 install -r "\$tmpdir/$src/requirements.txt"
|
||||||
|
|
Loading…
Reference in a new issue