1
0
mirror of https://github.com/community-scripts/ProxmoxVE.git synced 2025-03-08 13:19:05 +00:00
ProxmoxVE/install/jupyternotebook-install.sh
Dave 2dbd03b74c
New Script: Jupyter Notebook (#2561)
* Add jupyter notebook script, install script and json

* Add jupyter notebook script, install script and json

* Update jupyternotebook.sh

* Update jupyternotebook-install.sh

* Update jupyternotebook.sh

* Update jupyternotebook-install.sh

* Update jupyternotebook.json

---------

Co-authored-by: Dat Ta <datta@macmini.homeserver.local>
Co-authored-by: CanbiZ <47820557+MickLesk@users.noreply.github.com>
2025-02-24 09:10:43 +01:00

53 lines
1.0 KiB
Bash

#!/usr/bin/env bash
# Copyright (c) 2021-2025 community-scripts ORG
# Author: [Dave-code-creater (Tan Dat, Ta)]
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
# Source: [https://jupyter.org/]
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
color
verb_ip6
catch_errors
setting_up_container
network_check
update_os
msg_info "Installing Dependencies"
$STD apt-get install -y \
curl \
sudo \
mc \
python3 \
python3-pip
msg_ok "Installed Dependencies"
msg_info "Setting up Jupyter Notebook"
$STD pip3 install jupyter
msg_ok "Setup Jupyter Notebook"
msg_info "Creating Service"
cat <<EOF >/etc/systemd/system/jupyternotebook.service
[Unit]
Description=Jupyter Notebook Server
After=network.target
[Service]
Type=simple
ExecStart=jupyter notebook --ip=0.0.0.0 --port=8888 --allow-root
Restart=always
RestartSec=10
[Install]
WantedBy=multi-user.target
EOF
systemctl enable -q --now jupyternotebook
motd_ssh
customize
msg_info "Cleaning up"
$STD apt-get -y autoremove
$STD apt-get -y autoclean
msg_ok "Cleaned"