mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-11-18 19:45:15 +00:00
bump grafana to debian 13 (#9141)
* Update default Debian version to 13
* Remove software-properties-common from dependencies
Removed installation of 'software-properties-common' from dependencies.
* Update Debian version from 12 to 13
* Changed apt-get to apt
* Changed to new func setup_deb822_repo
* Replaced ${APP} with Grafana
* Refine update_script to use deb822 repo and grafana-only upgrade
* Using cleanup_lxc
* Wrong header_info in update_script()
* Remove unnecessary line break in dependency installation
* Simplify Grafana installation script
Removed unnecessary repository setup commands and updated the script for Grafana installation.
* Update Grafana repository setup in install script
Added repository details for Grafana installation.
---------
Co-authored-by: Tobias <96661824+CrazyWolf13@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
e373648787
commit
022abe7ba4
@@ -11,7 +11,7 @@ var_cpu="${var_cpu:-1}"
|
|||||||
var_ram="${var_ram:-512}"
|
var_ram="${var_ram:-512}"
|
||||||
var_disk="${var_disk:-2}"
|
var_disk="${var_disk:-2}"
|
||||||
var_os="${var_os:-debian}"
|
var_os="${var_os:-debian}"
|
||||||
var_version="${var_version:-12}"
|
var_version="${var_version:-13}"
|
||||||
var_unprivileged="${var_unprivileged:-1}"
|
var_unprivileged="${var_unprivileged:-1}"
|
||||||
|
|
||||||
header_info "$APP"
|
header_info "$APP"
|
||||||
@@ -20,19 +20,29 @@ color
|
|||||||
catch_errors
|
catch_errors
|
||||||
|
|
||||||
function update_script() {
|
function update_script() {
|
||||||
header_info
|
header_info
|
||||||
check_container_storage
|
check_container_storage
|
||||||
check_container_resources
|
check_container_resources
|
||||||
if [[ ! -f /etc/apt/sources.list.d/grafana.list ]]; then
|
|
||||||
msg_error "No ${APP} Installation Found!"
|
|
||||||
exit
|
|
||||||
fi
|
|
||||||
|
|
||||||
msg_info "Updating ${APP}"
|
if ! dpkg -s grafana >/dev/null 2>&1; then
|
||||||
$STD apt-get update
|
msg_error "No ${APP} Installation Found!"
|
||||||
$STD apt-get -y upgrade
|
exit 1
|
||||||
msg_ok "Updated successfully!"
|
fi
|
||||||
exit
|
|
||||||
|
if [[ -f /etc/apt/sources.list.d/grafana.list ]] || [[ ! -f /etc/apt/sources.list.d/grafana.sources ]]; then
|
||||||
|
setup_deb822_repo \
|
||||||
|
"grafana" \
|
||||||
|
"https://apt.grafana.com/gpg.key" \
|
||||||
|
"https://apt.grafana.com" \
|
||||||
|
"stable" \
|
||||||
|
"main"
|
||||||
|
fi
|
||||||
|
|
||||||
|
msg_info "Updating Grafana LXC"
|
||||||
|
$STD apt update
|
||||||
|
$STD apt --only-upgrade install -y grafana
|
||||||
|
msg_ok "Updated successfully!"
|
||||||
|
exit
|
||||||
}
|
}
|
||||||
|
|
||||||
start
|
start
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
"ram": 512,
|
"ram": 512,
|
||||||
"hdd": 2,
|
"hdd": 2,
|
||||||
"os": "debian",
|
"os": "debian",
|
||||||
"version": "12"
|
"version": "13"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -14,26 +14,23 @@ network_check
|
|||||||
update_os
|
update_os
|
||||||
|
|
||||||
msg_info "Installing Dependencies"
|
msg_info "Installing Dependencies"
|
||||||
$STD apt-get install -y \
|
$STD apt install -y apt-transport-https
|
||||||
apt-transport-https \
|
|
||||||
software-properties-common
|
|
||||||
msg_ok "Installed Dependencies"
|
msg_ok "Installed Dependencies"
|
||||||
|
|
||||||
msg_info "Setting up Grafana Repository"
|
msg_info "Setting up Grafana Repository"
|
||||||
curl -fsSL "https://apt.grafana.com/gpg.key" -o "/usr/share/keyrings/grafana.key"
|
setup_deb822_repo \
|
||||||
echo "deb [signed-by=/usr/share/keyrings/grafana.key] https://apt.grafana.com stable main" >/etc/apt/sources.list.d/grafana.list
|
"grafana" \
|
||||||
msg_ok "Set up Grafana Repository"
|
"https://apt.grafana.com/gpg.key" \
|
||||||
|
"https://apt.grafana.com" \
|
||||||
|
"stable" \
|
||||||
|
"main"
|
||||||
|
msg_ok "Grafana Repository setup sucessfully"
|
||||||
|
|
||||||
msg_info "Installing Grafana"
|
msg_info "Installing Grafana"
|
||||||
$STD apt-get update
|
$STD apt install -y grafana
|
||||||
$STD apt-get install -y grafana
|
systemctl enable -q --now grafana-server
|
||||||
systemctl enable -q --now grafana-server
|
|
||||||
msg_ok "Installed Grafana"
|
msg_ok "Installed Grafana"
|
||||||
|
|
||||||
motd_ssh
|
motd_ssh
|
||||||
customize
|
customize
|
||||||
|
cleanup_lxc
|
||||||
msg_info "Cleaning up"
|
|
||||||
$STD apt-get -y autoremove
|
|
||||||
$STD apt-get -y autoclean
|
|
||||||
msg_ok "Cleaned"
|
|
||||||
|
|||||||
Reference in New Issue
Block a user