mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-07-08 06:57:37 +00:00
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>
This commit is contained in:
52
install/jupyternotebook-install.sh
Normal file
52
install/jupyternotebook-install.sh
Normal file
@ -0,0 +1,52 @@
|
||||
#!/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"
|
Reference in New Issue
Block a user