mirror of
https://github.com/YunoHost-Apps/jupyterlab_ynh.git
synced 2024-09-03 19:26:35 +02:00
venv
This commit is contained in:
parent
594c1d8370
commit
5aeb76eacf
3 changed files with 11 additions and 8 deletions
|
@ -5,7 +5,7 @@
|
|||
#=================================================
|
||||
|
||||
# dependencies used by the app
|
||||
pkg_dependencies="python3-dev python3-pip"
|
||||
pkg_dependencies="python3-dev python3-pip python3-venv"
|
||||
|
||||
nodejs_version="18"
|
||||
|
||||
|
|
|
@ -99,8 +99,9 @@ ynh_app_setting_set --app=$app --key=final_path --value=$final_path
|
|||
mkdir -p "$final_path"
|
||||
|
||||
pushd $final_path
|
||||
mkdir -p .venv
|
||||
PIPENV_VENV_IN_PROJECT="enabled" PIPENV_SKIP_LOCK=true ynh_exec_warn_less python3 -m pipenv install jupyterlab==$jupyterlab_version jupyterhub jupyter_collaboration notebook jupyterhub-ldapauthenticator pyzmq jupyterlab-language-pack-fr-FR
|
||||
python3 -m venv $final_path/venv
|
||||
source $final_path/venv/bin/activate
|
||||
ynh_exec_warn_less pip install jupyterlab==$jupyterlab_version jupyterhub jupyter_collaboration notebook jupyterhub-ldapauthenticator pyzmq jupyterlab-language-pack-fr-FR
|
||||
popd
|
||||
|
||||
#=================================================
|
||||
|
@ -116,7 +117,7 @@ ynh_add_config --template="../conf/jupyterhub_config.py" --destination="$final_p
|
|||
ynh_add_config --template="../conf/jupyter_notebook_config.py" --destination="$final_path/config/jupyter_notebook_config.py"
|
||||
|
||||
chown -R root: $final_path/
|
||||
chown -R $admin: $final_path/.venv/
|
||||
chown -R $admin: $final_path/venv/
|
||||
|
||||
#=================================================
|
||||
# SETUP SYSTEMD
|
||||
|
|
|
@ -94,7 +94,6 @@ ynh_install_app_dependencies $pkg_dependencies
|
|||
ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version
|
||||
ynh_use_nodejs
|
||||
$ynh_npm install -g configurable-http-proxy
|
||||
python3 -m pip install pipenv
|
||||
|
||||
#=================================================
|
||||
# SPECIFIC UPGRADE
|
||||
|
@ -106,9 +105,12 @@ if [ "$upgrade_type" == "UPGRADE_APP" ]
|
|||
then
|
||||
ynh_script_progression --message="Building app..." --weight=160
|
||||
|
||||
ynh_secure_remove $final_path/.venv
|
||||
|
||||
pushd $final_path
|
||||
mkdir -p .venv
|
||||
PIPENV_VENV_IN_PROJECT="enabled" PIPENV_SKIP_LOCK=true ynh_exec_warn_less python3 -m pipenv install jupyterlab==$jupyterlab_version jupyterhub notebook jupyter_collaboration jupyterhub-ldapauthenticator pyzmq
|
||||
python3 -m venv $final_path/venv
|
||||
source $final_path/venv/bin/activate
|
||||
ynh_exec_warn_less pip install jupyterlab==$jupyterlab_version jupyterhub notebook jupyter_collaboration jupyterhub-ldapauthenticator pyzmq
|
||||
popd
|
||||
fi
|
||||
|
||||
|
@ -126,7 +128,7 @@ ynh_add_config --template="../conf/jupyterhub_config.py" --destination="$final_p
|
|||
ynh_add_config --template="../conf/jupyter_notebook_config.py" --destination="$final_path/config/jupyter_notebook_config.py"
|
||||
|
||||
chown -R root: $final_path/
|
||||
chown -R $admin: $final_path/.venv/
|
||||
chown -R $admin: $final_path/venv/
|
||||
|
||||
#=================================================
|
||||
# SETUP SYSTEMD
|
||||
|
|
Loading…
Reference in a new issue