Update esphome-install.sh

Debian 12 compatible
pull/1593/head
tteckster 1 year ago committed by GitHub
parent 46a2b14b09
commit bbd7ad39f6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -20,17 +20,25 @@ $STD apt-get install -y mc
$STD apt-get install -y git $STD apt-get install -y git
msg_ok "Installed Dependencies" msg_ok "Installed Dependencies"
msg_info "Installing Python3-pip" msg_info "Updating Python3"
$STD apt-get install -y python3-pip $STD apt-get install -y \
msg_ok "Installed Python3-pip" python3 \
python3-dev \
python3-pip \
python3-venv
msg_ok "Updated Python3"
msg_info "Installing ESPHome" msg_info "Installing ESPHome"
$STD pip3 install esphome if [[ "$PCT_OSVERSION" == "12" ]]; then
$STD pip install esphome --break-system-packages
$STD pip install tornado esptool --break-system-packages
else
$STD pip install esphome
$STD pip install tornado esptool
fi
msg_ok "Installed ESPHome" msg_ok "Installed ESPHome"
msg_info "Installing ESPHome Dashboard" msg_info "Creating Service"
$STD pip3 install tornado esptool
service_path="/etc/systemd/system/esphomeDashboard.service" service_path="/etc/systemd/system/esphomeDashboard.service"
echo "[Unit] echo "[Unit]
Description=ESPHome Dashboard Description=ESPHome Dashboard
@ -41,9 +49,8 @@ Restart=always
User=root User=root
[Install] [Install]
WantedBy=multi-user.target" >$service_path WantedBy=multi-user.target" >$service_path
$STD systemctl enable esphomeDashboard.service systemctl enable -q --now esphomeDashboard.service
systemctl start esphomeDashboard msg_ok "Created Service"
msg_ok "Installed ESPHome Dashboard"
motd_ssh motd_ssh
customize customize

Loading…
Cancel
Save

Powered by BW's shoe-string budget.