2023-03-22 20:48:20 -04:00
|
|
|
#!/usr/bin/env bash
|
2026-08-25 11:04:15 +02:00
|
|
|
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
|
|
|
|
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
2026-01-06 13:28:12 +01:00
|
|
|
# Copyright (c) 2021-2026 tteck
|
2023-03-22 20:48:20 -04:00
|
|
|
# Author: tteck (tteckster)
|
2024-12-16 12:42:51 +01:00
|
|
|
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
|
|
|
|
# Source: https://jellyfin.org/
|
2023-03-22 20:48:20 -04:00
|
|
|
|
|
|
|
|
APP="Jellyfin"
|
2025-04-10 11:56:52 +02:00
|
|
|
var_tags="${var_tags:-media}"
|
|
|
|
|
var_cpu="${var_cpu:-2}"
|
|
|
|
|
var_ram="${var_ram:-2048}"
|
2025-10-20 08:28:22 +02:00
|
|
|
var_disk="${var_disk:-16}"
|
2025-04-10 11:56:52 +02:00
|
|
|
var_os="${var_os:-ubuntu}"
|
2025-06-24 18:34:20 +02:00
|
|
|
var_version="${var_version:-24.04}"
|
2026-06-21 02:56:49 +10:00
|
|
|
var_arm64="${var_arm64:-yes}"
|
2025-04-10 11:56:52 +02:00
|
|
|
var_unprivileged="${var_unprivileged:-1}"
|
2025-12-08 13:52:30 +01:00
|
|
|
var_gpu="${var_gpu:-yes}"
|
2024-12-16 12:42:51 +01:00
|
|
|
|
|
|
|
|
header_info "$APP"
|
2023-03-22 20:48:20 -04:00
|
|
|
variables
|
|
|
|
|
color
|
|
|
|
|
catch_errors
|
|
|
|
|
|
|
|
|
|
function update_script() {
|
2025-06-24 18:34:20 +02:00
|
|
|
header_info
|
|
|
|
|
check_container_storage
|
|
|
|
|
check_container_resources
|
|
|
|
|
if [[ ! -d /usr/lib/jellyfin ]]; then
|
|
|
|
|
msg_error "No ${APP} Installation Found!"
|
|
|
|
|
exit
|
|
|
|
|
fi
|
2025-10-20 16:21:31 +02:00
|
|
|
|
2026-06-22 23:35:14 +10:00
|
|
|
if ! grep -qEi 'ubuntu' /etc/os-release && [[ "$(arch_resolve)" == "amd64" ]]; then
|
2025-10-20 21:00:48 +02:00
|
|
|
msg_info "Updating Intel Dependencies"
|
2025-11-01 09:06:33 +01:00
|
|
|
rm -f ~/.intel-* || true
|
2026-04-17 21:58:31 +02:00
|
|
|
|
|
|
|
|
# Fetch compute-runtime first so /tmp/gh_rel.json is populated for IGC tag resolution
|
2025-10-20 21:00:48 +02:00
|
|
|
fetch_and_deploy_gh_release "intel-libgdgmm12" "intel/compute-runtime" "binary" "latest" "" "libigdgmm12_*_amd64.deb"
|
2026-04-17 21:58:31 +02:00
|
|
|
|
|
|
|
|
local igc_tag
|
|
|
|
|
_resolve_igc_tag igc_tag
|
|
|
|
|
|
|
|
|
|
fetch_and_deploy_gh_release "intel-igc-core-2" "intel/intel-graphics-compiler" "binary" "$igc_tag" "" "intel-igc-core-2_*_amd64.deb"
|
|
|
|
|
fetch_and_deploy_gh_release "intel-igc-opencl-2" "intel/intel-graphics-compiler" "binary" "$igc_tag" "" "intel-igc-opencl-2_*_amd64.deb"
|
2026-06-04 12:22:41 +02:00
|
|
|
fetch_and_deploy_gh_release "intel-opencl-icd" "intel/compute-runtime" "binary" "latest" "" "intel-opencl-icd_*_amd64.deb"
|
2025-10-20 21:00:48 +02:00
|
|
|
msg_ok "Updated Intel Dependencies"
|
|
|
|
|
fi
|
2025-10-30 09:24:16 -07:00
|
|
|
|
2026-03-18 11:55:38 +01:00
|
|
|
msg_info "Setting up Jellyfin Repository"
|
2026-09-01 07:45:58 +02:00
|
|
|
JELLYFIN_REPO_URL="https://repo.jellyfin.org/$(get_os_info id)"
|
|
|
|
|
JELLYFIN_SUITE="$(get_fallback_suite "$(get_os_info id)" "$(get_os_info codename)" "$JELLYFIN_REPO_URL")"
|
2026-03-18 11:55:38 +01:00
|
|
|
setup_deb822_repo \
|
|
|
|
|
"jellyfin" \
|
|
|
|
|
"https://repo.jellyfin.org/jellyfin_team.gpg.key" \
|
2026-09-01 07:45:58 +02:00
|
|
|
"$JELLYFIN_REPO_URL" \
|
|
|
|
|
"$JELLYFIN_SUITE"
|
2026-03-18 11:55:38 +01:00
|
|
|
msg_ok "Set up Jellyfin Repository"
|
|
|
|
|
|
2025-10-20 08:28:22 +02:00
|
|
|
msg_info "Updating Jellyfin"
|
2026-02-02 13:01:17 +01:00
|
|
|
ensure_dependencies libjemalloc2
|
2025-10-20 08:28:22 +02:00
|
|
|
if [[ ! -f /usr/lib/libjemalloc.so ]]; then
|
2026-06-22 23:35:14 +10:00
|
|
|
ln -sf "/usr/lib/$(arch_resolve "x86_64-linux-gnu" "aarch64-linux-gnu")/libjemalloc.so.2" /usr/lib/libjemalloc.so
|
2025-10-20 08:28:22 +02:00
|
|
|
fi
|
|
|
|
|
$STD apt -y upgrade
|
2026-09-08 10:28:42 +02:00
|
|
|
$STD apt -y --with-new-pkgs upgrade jellyfin jellyfin-server jellyfin-ffmpeg8
|
2026-03-18 11:55:38 +01:00
|
|
|
ln -sf /usr/lib/jellyfin-ffmpeg/ffmpeg /usr/bin/ffmpeg
|
|
|
|
|
ln -sf /usr/lib/jellyfin-ffmpeg/ffprobe /usr/bin/ffprobe
|
2025-10-20 08:28:22 +02:00
|
|
|
msg_ok "Updated Jellyfin"
|
2025-10-30 09:24:16 -07:00
|
|
|
msg_ok "Updated successfully!"
|
2025-06-24 18:34:20 +02:00
|
|
|
exit
|
2023-03-22 20:48:20 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
start
|
|
|
|
|
build_container
|
|
|
|
|
description
|
|
|
|
|
|
2026-01-06 22:57:40 +01:00
|
|
|
msg_ok "Completed successfully!\n"
|
2024-12-16 12:42:51 +01:00
|
|
|
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
2026-06-03 11:03:13 +02:00
|
|
|
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
|
|
|
|
echo -e "${GATEWAY}${BGN}http://${IP}:8096${CL}"
|