Commit graph

1622 commits

Author SHA1 Message Date
Sam Heinz
7027d67eb3
attempt to port docker-vm to support arm64 (#15611) 2026-07-06 15:41:55 +02:00
MickLesk
728726d5cc fix(docker): safe, interactive per-container update check
Replace the destructive multi-select container update block with a
proper per-container Y/N workflow:

- Unattended / non-interactive (DOCKER_NONINTERACTIVE=1 or no tty):
  skip silently -- no docker pulls, no prompts.
- Interactive: stop_spinner() before any prompt to keep the terminal
  clean, then for each container with a newer image:
    Compose-managed  → prompt Y/N (auto-no after 60 s)
                       → on Y: docker compose pull <service> &&
                                docker compose up -d <service>
    Standalone run   → prompt Y/N (auto-no after 60 s)
                       → on Y: docker pull only; no stop/rm;
                                user is told to recreate manually
- portainer / portainer_agent are excluded (handled earlier in
  setup_docker)

The old code always stopped and removed the container without
recreating it, leaving users with a destroyed service.  Standalone
containers without a Compose project can never be auto-recreated
safely, so only the image is pulled.

Fixes #15601
2026-07-06 14:43:25 +02:00
MickLesk
20740c3ca2 fix(docker): remove interactive container update check from setup_docker
The 'Interactive Container Update Check' block scanned ALL running
Docker containers, pulled their images, then stopped and removed them
with only a message asking the user to manually recreate them.  This
is destructive and outside the scope of the Docker LXC update script,
which is responsible for updating the Docker engine itself and the
Portainer / Portainer-Agent containers that this script originally
installed.

Removes the entire block.  Updates now cover:
  - OS packages (apt)
  - Docker engine (via setup_docker / repo)
  - Portainer CE (if installed by this script)
  - Portainer Agent (if installed by this script)

Self-hosted / user-managed containers are intentionally left alone.

Fixes #15601
2026-07-06 14:38:07 +02:00
CanbiZ (MickLesk)
704916d27d
tools.func: fix corepack/pnpm install flow in setup_nodejs (#15579)
Ensure Node module setup runs non-interactively by exporting COREPACK_ENABLE_DOWNLOAD_PROMPT=0, then handle corepack first when requested (including versioned specs). pnpm/yarn are now provisioned through corepack when enabled to avoid shim EEXIST collisions, with corepack modules skipped in the generic npm loop and conflicting shims cleaned only for npm-global installs. Also replace the global pnpm dangerouslyAllowAllBuilds setting with strictDepBuilds=false to avoid project-level config conflicts while keeping installs usable.
2026-07-03 22:22:06 +02:00
MickLesk
b8a1879b24 hotfix: retry npm install with --force for corepack shims
Add a fallback retry using `npm install -g --force` when the initial install fails. This handles EEXIST errors caused by corepack-provided shims for pnpm/yarn that ship with recent Node.js versions and block installation to /usr/bin/<tool>.
2026-07-03 09:34:21 +02:00
Michel Roegl-Brunner
9b7f4533c6
feat(build.func): add var_ignore_disable to bypass disabled-script guard (#15544)
Allow users to set var_ignore_disable=true to continue past the 'script disabled' guard in runtime_script_status_guard(). A warning is still shown, but execution continues instead of aborting. Deleted scripts remain a hard stop.
2026-07-02 13:53:39 +02:00
CanbiZ (MickLesk)
be29bb1538
tools.func: configure pnpm to allow all build scripts for LXC container environments (#15532) 2026-07-02 09:07:04 +02:00
CanbiZ (MickLesk)
a8eedc1848
core: fix SDN vnet network parameter to use bridge instead of vnet (#15527) 2026-07-01 22:36:07 +02:00
CanbiZ (MickLesk)
80af66e864
tools.func: use safe variable expansion in check_for_gh_release RETURN trap (#15529) 2026-07-01 22:35:15 +02:00
CanbiZ (MickLesk)
069c8f578f
ImageMagick: Switch to github releases (#15492) 2026-06-30 10:19:05 +02:00
Slaviša Arežina
89998b4fa0
add edit_yaml_config function (#15484) 2026-06-30 07:12:04 +10:00
CanbiZ (MickLesk)
fb14e6ae8b
fix(setup_docker): don't abort update on docker pull failure (#15410)
During the container update check, a failing 'docker pull' (local-only images, registry or permission errors) aborted the whole script under errexit. Ignore pull failures and skip containers whose digest could not be resolved.
2026-06-26 21:58:08 +02:00
Jamie
681924cb1a
fix(build.func): set /dev/kfd GID in fix_gpu_gids for AMD ROCm (#15401)
Update LXC config and privileged-container permissions for /dev/kfd
to use the render group, matching renderD* handling and tools.func.
2026-06-26 22:06:27 +10:00
Sam Heinz
b2d20799d8
fix alpine mktmp error (#15398) 2026-06-26 07:47:48 +02:00
CanbiZ (MickLesk)
edf167025f
VM-Core: Update some Functions (#15113) 2026-06-25 13:13:29 +02:00
MickLesk
f7acb76e80 fix typo 2026-06-24 23:44:26 +02:00
CanbiZ (MickLesk)
e193adad5a
core: add SDN vnet selection in advanced install (#15366)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-24 23:21:12 +02:00
CanbiZ (MickLesk)
0b94d4f54a
core: add var_http_proxy and var_http_no_proxy support (#15225)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-24 06:58:32 +02:00
Luna
e076322c0f
fix: close lxc build function (#15343) 2026-06-23 07:39:36 +02:00
Copilot
52e4e5ff39
fix(build.func): remove duplicate if statement causing syntax error on container creation (#15338)
* Initial plan

* fix(build.func): remove duplicate if statement causing syntax error

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
2026-06-23 07:29:05 +02:00
l0caldadmin
89b6678d1f
Fix syntax error in build function (#15337) 2026-06-23 07:25:51 +02:00
CanbiZ (MickLesk)
b18e9298b1
Implement local _disable_update for conditional upgrade handling
Add a local variable to manage update disabling based on environment settings.
2026-06-23 06:31:44 +02:00
CanbiZ (MickLesk)
bd228edb21
tools.func: refresh ruby-build when requested version is missing (#15315) 2026-06-22 22:01:40 +02:00
CanbiZ (MickLesk)
fd1dbf2ba1
core:: skip LXC stack upgrade prompt in unattended mode (#15319) 2026-06-22 21:59:27 +02:00
CanbiZ (MickLesk)
edbd570adf
Endurain: pin uv to the version required by the project (#15313) 2026-06-22 21:46:52 +02:00
CanbiZ (MickLesk)
0940119aea
feat(build): add pre-install storage health checks (#15226)
Warn or block container creation when target storage is above 85% or 95% full.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-22 21:08:09 +02:00
CanbiZ (MickLesk)
8b877f1c9f
tools.func: APT install and deb822 repo reliability (#15272)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-21 23:10:27 +02:00
CanbiZ (MickLesk)
6665a5bf5d
tools.func: prevent MySQL data loss and fix repo version matching (#15271)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-21 23:10:08 +02:00
CanbiZ (MickLesk)
53efcadfa9
tools.func: runtime hardening for API helpers and Docker/MeiliSearch (#15273)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-21 23:09:51 +02:00
CanbiZ (MickLesk)
b5c31d58f4
tools.func: centralize Node.js corepack and npm handling in setup_nodejs() (#15268) 2026-06-21 22:24:10 +02:00
Sam Heinz
3799d565da
[arm64] Port scripts between nodered & paperlessngx to support arm64 (#15255)
* [arm64] Port scripts between nodered-paperlessngx to support arm64

* Update paperclip.sh
2026-06-21 20:45:41 +02:00
Sam Heinz
18b9cd2e64
[arm64] Port scripts between komga & mediamanager to support arm64 (#15245)
* [arm64] Port scripts between komga-mediamanager to support arm64

adds override to make debian cts on arm64 use ubuntu mongodb binaries

* bump limesurvey
2026-06-21 00:21:58 +02:00
Sam Heinz
1134f4cdc6
[arm64] port hyperhdr-kometa to arm64 (#15234)
also port apprise-api, archivebox. Update meilisearch function to support arm64.

invoiceshelf changes are an existing bug.

changes to kasm are required to get docker working, as old docker provided by setup_docker will not work. The --ignore-dep-failures is required as there is a bug in the install script.
2026-06-21 02:56:49 +10:00
Sam Heinz
6ce9d8a39d
[arm64] Port scripts titled between A-F to support arm64 (#15181) 2026-06-19 09:53:08 +02:00
Michel Roegl-Brunner
e60c1f31c2 Stop spinner for deleted/disabled info messages
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-16 11:11:23 +02:00
Michel Roegl-Brunner
7ee47be436
Add runtime status guard and deleted script stubs (#15125)
* Add runtime script status guard and deleted-script stubs.

Prevent disabled/deleted scripts from running updates with clear user messages, and ensure deleted ct scripts are stubbed automatically so legacy update commands no longer fail with 404.

* Delete ct/ente.sh

* Update booklore.sh
2026-06-16 10:56:29 +02:00
CanbiZ (MickLesk)
6762208d66
core: improve mirror selection and error handling (#15108) 2026-06-15 10:09:38 +02:00
CanbiZ (MickLesk)
4b20b8dab5
tools.func: extend mesa-vulkan-drivers and vulkan-tools to installation for ARC GPU's (#15106) 2026-06-15 10:09:14 +02:00
CanbiZ (MickLesk)
293d4b73a1
core: implement gateway validation for DHCP and static networks (#15107) 2026-06-15 10:08:24 +02:00
MickLesk
07ab5dc16e Quote PostgreSQL extension names
Wrap the extension identifier in double quotes in the CREATE EXTENSION SQL call within setup_postgresql_db. This ensures extension names containing hyphens, mixed case, or other characters that require quoting are handled correctly and avoids syntax errors when creating extensions.
2026-06-13 18:17:21 +02:00
Michel Roegl-Brunner
a38da170da
Implement backup and restore functions (#15067)
Added create_backup and restore_backup functions for standardized data backup and restoration.
2026-06-12 10:23:28 +02:00
Sam Heinz
10acc2f591
[arm64] remove logic for custom debian arm64 template (#15050) 2026-06-11 18:06:21 +02:00
Sam Heinz
6851a02bdc
misc scripts: add support for arm64 (#12639)
* misc scripts: add support for arm64

* Replace tools.func call that checks arch

* Update misc/build.func

Co-authored-by: Tobias <96661824+CrazyWolf13@users.noreply.github.com>

* Update misc/build.func

Co-authored-by: Tobias <96661824+CrazyWolf13@users.noreply.github.com>

* Update misc/build.func

Co-authored-by: Tobias <96661824+CrazyWolf13@users.noreply.github.com>

* Update misc/build.func

Co-authored-by: Tobias <96661824+CrazyWolf13@users.noreply.github.com>

* build.func: change back to VE

* build.func: remove arm64 support for focal, bullseye

Legacy support removed since no cts use them anymore.

* Improve arm64 support and arch-specific downloads

Add clearer architecture error messages and gate arm64 usage, plus implement architecture-aware behavior across the toolkit. Changes include: update exit-code messages to reference amd64/arm64, refuse arm64 unless explicitly enabled, show architecture in summaries, and use arch-specific package lists when installing in containers. Make downloads for FFmpeg and yq choose the correct amd64/arm64 binaries, tighten template download error handling and formatting, and clean up minor whitespace/comment issues. These changes aim to make arm64 handling explicit and downloads/installations more robust for non-amd64 systems.

* remove arm64 overlay

* update ifupdown2 source

* Revert "remove arm64 overlay"

This reverts commit 231945dfa7.

* Revert changes from "Improve arm64 support and arch-specific downloads"

* Reapply "Improve arm64 support and arch-specific downloads"

This reapplies commit 7c051fb648.

* Reapply "remove arm64 overlay"

This reverts commit 866b6950c0.

* Redo template name handling

* fix template name handling change

* add ensure_whiptail function

This is required as some arm64 systems will not have whiptail installed, as it is not installed by default.

* add arm64_notice function

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* fix for copilot detected bugs

---------

Co-authored-by: Tobias <96661824+CrazyWolf13@users.noreply.github.com>
Co-authored-by: CanbiZ (MickLesk) <47820557+MickLesk@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-06-11 08:14:32 +02:00
Nick B
79ccc8ed6b
AMD IGPU support (#14944) 2026-06-05 12:40:26 +02:00
Slaviša Arežina
5380f72986
Fix alignment for msg_ functions (#14908) 2026-06-03 13:59:38 +02:00
CanbiZ (MickLesk)
1a63343a17
tools.func: add support for Rust installation profile in setup_rust (#14872) 2026-06-02 09:03:53 +02:00
Slaviša Arežina
80a73c0ec0
Format LATEST_VERSION_DOTTED from LATEST_VERSION (#14745)
Change LATEST_VERSION_DOTTED assignment to format version correctly.
2026-05-27 08:14:17 +02:00
CanbiZ (MickLesk)
edfa7c8c45
tools.func: better error diagnostics, consistent OS detection, setup function ordering (#14692)
* fix(tools): improve error diagnostics and actionable hints across install functions

- Add _diagnose_deb_failure() helper: extracts package metadata from failed .deb installs,
  detects PostgreSQL version conflicts (e.g., postgresql-16-vchord with PG17 active),
  lists unmet dependencies, and provides specific actionable hints
- Replace all 4 generic 'Both apt and dpkg installation failed' messages in
  fetch_and_deploy_{codeberg,gh,gl}_release and fetch_and_deploy_from_url with
  _diagnose_deb_failure() for targeted diagnostics
- install_packages_with_retry: on failure, check which packages are missing from
  configured repos and name them with a distribution-specific hint
- upgrade_packages_with_retry: add hint about held-back packages / apt-cache policy
- setup_postgresql: when PGDG repo is unavailable for trixie/forky/sid, show which
  distro PG version will be installed and warn that extension packages must match
- setup_deb822_repo: include GPG key URL and firewall hint in download failure message
- curl_download: add network/DNS hint to the failure message
- error_handler: add log-pattern analysis block after Node.js OOM detection that
  scans the last 60 log lines for 5 common failure patterns and emits msg_warn hints:
    * APT/dpkg dependency conflict (generic + PostgreSQL version mismatch)
    * APT GPG/signature verification failure (sqv, KEYEXPIRED, NO_PUBKEY)
    * Network/DNS failure (Could not resolve, Failed to fetch)
    * APT lock held by another process
    * Disk space exhaustion (ENOSPC)

* fix(tools): consolidate OS detection, add error hints, sort setup functions

- Replace all 13 manual /etc/os-release reads with get_os_info() across
  prepare_repository_setup, setup_hwaccel, setup_java, setup_mysql,
  setup_php, setup_postgresql, setup_clickhouse, install_packages_with_retry
- Add actionable Hint messages to 16 download/network failure paths:
  adminer, composer, ffmpeg (x2), go, ghostscript, imagemagick, rbenv,
  ruby-build, meilisearch-config, uv, yq, rust, apt-lock timeout,
  mongodb GPG, php keyring
- Replace 6 silent 'apt install || true' with msg_warn for optional packages:
  3x postgresql modules, ruby build deps, ssl-cert, docker-compose
- Sort all 'function setup_*' declarations into alphabetical order:
  clickhouse moved to after adminer, docker moved to after composer,
  meilisearch moved to after mariadb_db

* style(tools): unify all function declarations to name() { style

Remove 'function' keyword from 30 declarations to match the project convention
used in core.func, error_handler.func, and all other .func files (POSIX-compatible name() { syntax)
2026-05-26 08:06:08 +02:00
CanbiZ (MickLesk)
9ec0864d32
fix(tools): replace raw GitHub API curl calls with get_latest_github_release (#14690) 2026-05-25 08:50:00 +02:00
CanbiZ (MickLesk)
2fa9ae03a1
core: suppress MOTD for non-interactive shells (#14638) 2026-05-22 09:08:13 +02:00