mirror of https://github.com/tteck/Proxmox.git
Compare commits
3 Commits
0d5754de12
...
e80dbb4aad
Author | SHA1 | Date |
---|---|---|
|
e80dbb4aad | |
|
61118ab83b | |
|
8c2a3cc4d7 |
|
@ -4,6 +4,13 @@
|
||||||
|
|
||||||
- All LXC instances created using this repository come pre-installed with Midnight Commander, which is a command-line tool (`mc`) that offers a user-friendly file and directory management interface for the terminal environment.
|
- All LXC instances created using this repository come pre-installed with Midnight Commander, which is a command-line tool (`mc`) that offers a user-friendly file and directory management interface for the terminal environment.
|
||||||
|
|
||||||
|
## 2023-06-16
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- **Proxmox VE Monitor-All**
|
||||||
|
- Skip instances based on onboot and templates. [8c2a3cc](https://github.com/tteck/Proxmox/commit/8c2a3cc4d774fa13d17f695d6bdf9a4deedb1372).
|
||||||
|
|
||||||
## 2023-06-12
|
## 2023-06-12
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
# License: MIT
|
# License: MIT
|
||||||
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
||||||
|
|
||||||
source /dev/stdin <<< "$FUNCTIONS_FILE_PATH"
|
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||||
color
|
color
|
||||||
verb_ip6
|
verb_ip6
|
||||||
catch_errors
|
catch_errors
|
||||||
|
@ -13,8 +13,36 @@ setting_up_container
|
||||||
network_check
|
network_check
|
||||||
update_os
|
update_os
|
||||||
|
|
||||||
msg_info "Installing Dependencies (Patience)"
|
if [[ "$PCT_OSVERSION" == "12" ]]; then
|
||||||
$STD apt-get install -y \
|
msg_info "Installing Dependencies, Bookworm (Patience)"
|
||||||
|
$STD apt-get install -y \
|
||||||
|
git \
|
||||||
|
curl \
|
||||||
|
sudo \
|
||||||
|
mc \
|
||||||
|
python3 \
|
||||||
|
python3-dev \
|
||||||
|
python3-venv \
|
||||||
|
python3-pip \
|
||||||
|
bluez \
|
||||||
|
libffi-dev \
|
||||||
|
libssl-dev \
|
||||||
|
libjpeg-dev \
|
||||||
|
zlib1g-dev \
|
||||||
|
autoconf \
|
||||||
|
build-essential \
|
||||||
|
libopenjp2-7 \
|
||||||
|
libturbojpeg0-dev \
|
||||||
|
tzdata \
|
||||||
|
ffmpeg \
|
||||||
|
liblapack3 \
|
||||||
|
liblapack-dev \
|
||||||
|
libatlas-base-dev
|
||||||
|
$STD systemctl disable systemd-networkd-wait-online.service
|
||||||
|
msg_ok "Installed Dependencies"
|
||||||
|
else
|
||||||
|
msg_info "Installing Dependencies, Bullseye (Patience)"
|
||||||
|
$STD apt-get install -y \
|
||||||
git \
|
git \
|
||||||
curl \
|
curl \
|
||||||
sudo \
|
sudo \
|
||||||
|
@ -45,21 +73,22 @@ $STD apt-get install -y \
|
||||||
liblapack3 \
|
liblapack3 \
|
||||||
liblapack-dev \
|
liblapack-dev \
|
||||||
libatlas-base-dev
|
libatlas-base-dev
|
||||||
msg_ok "Installed Dependencies"
|
msg_ok "Installed Dependencies"
|
||||||
|
|
||||||
msg_info "Installing pyenv"
|
msg_info "Installing pyenv"
|
||||||
$STD git clone https://github.com/pyenv/pyenv.git ~/.pyenv
|
$STD git clone https://github.com/pyenv/pyenv.git ~/.pyenv
|
||||||
set +e
|
set +e
|
||||||
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.bashrc
|
echo 'export PYENV_ROOT="$HOME/.pyenv"' >>~/.bashrc
|
||||||
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bashrc
|
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >>~/.bashrc
|
||||||
echo -e 'if command -v pyenv 1>/dev/null 2>&1; then\n eval "$(pyenv init --path)"\nfi' >> ~/.bashrc
|
echo -e 'if command -v pyenv 1>/dev/null 2>&1; then\n eval "$(pyenv init --path)"\nfi' >>~/.bashrc
|
||||||
msg_ok "Installed pyenv"
|
msg_ok "Installed pyenv"
|
||||||
. ~/.bashrc
|
. ~/.bashrc
|
||||||
set -e
|
set -e
|
||||||
msg_info "Installing Python 3.11.3 (Patience)"
|
msg_info "Installing Python 3.11.3 (Patience)"
|
||||||
$STD pyenv install 3.11.3
|
$STD pyenv install 3.11.3
|
||||||
pyenv global 3.11.3
|
pyenv global 3.11.3
|
||||||
msg_ok "Installed Python 3.11.3"
|
msg_ok "Installed Python 3.11.3"
|
||||||
|
fi
|
||||||
|
|
||||||
msg_info "Installing Home Assistant-Core"
|
msg_info "Installing Home Assistant-Core"
|
||||||
mkdir /srv/homeassistant
|
mkdir /srv/homeassistant
|
||||||
|
@ -68,8 +97,6 @@ python3 -m venv .
|
||||||
source bin/activate
|
source bin/activate
|
||||||
$STD pip install --upgrade pip
|
$STD pip install --upgrade pip
|
||||||
$STD python3 -m pip install wheel
|
$STD python3 -m pip install wheel
|
||||||
$STD pip install mysqlclient
|
|
||||||
$STD pip install psycopg2-binary
|
|
||||||
$STD pip install homeassistant
|
$STD pip install homeassistant
|
||||||
mkdir -p /root/.homeassistant
|
mkdir -p /root/.homeassistant
|
||||||
msg_ok "Installed Home Assistant-Core"
|
msg_ok "Installed Home Assistant-Core"
|
||||||
|
|
|
@ -49,9 +49,14 @@ while true; do
|
||||||
IP=$(qm guest cmd $instance network-get-interfaces | egrep -o "([0-9]{1,3}\.){3}[0-9]{1,3}" | grep -E "192\.|10\." | head -n 1)
|
IP=$(qm guest cmd $instance network-get-interfaces | egrep -o "([0-9]{1,3}\.){3}[0-9]{1,3}" | grep -E "192\.|10\." | head -n 1)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Skip instances based on templates
|
# Skip instances based on onboot and templates
|
||||||
|
onboot=$($config_cmd $instance | grep onboot | grep -q "onboot: 0" && echo "true" || echo "false")
|
||||||
template=$($config_cmd $instance | grep template | grep -q "template:" && echo "true" || echo "false")
|
template=$($config_cmd $instance | grep template | grep -q "template:" && echo "true" || echo "false")
|
||||||
if [ "$template" == "true" ]; then
|
|
||||||
|
if [ "$onboot" == "true" ]; then
|
||||||
|
echo "Skipping $instance because it is set not to boot"
|
||||||
|
continue
|
||||||
|
elif [ "$template" == "true" ]; then
|
||||||
echo "Skipping $instance because it is a template"
|
echo "Skipping $instance because it is a template"
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue