1442 Commits

Author SHA1 Message Date
CanbiZ
6a2928ca47 Update build.func 2025-11-24 09:19:34 +01:00
CanbiZ
e64957656b Quote variables in log display conditions
Added quotes around build_log_copied and install_log_copied variables in conditional checks to prevent potential issues with unbound or empty variables during log display.
2025-11-22 17:51:18 +01:00
CanbiZ
517f5b3d0c switch baks 2025-11-22 17:38:15 +01:00
CanbiZ
3133f47d6e Update build.func 2025-11-22 17:37:30 +01:00
Tobias
e49a5b6bc2
undo 2025-11-21 11:06:13 +01:00
Tobias
fbbc94757c
Output header URL and parameters for debugging
Add echo statement to output header URL and parameters
2025-11-21 10:57:52 +01:00
CanbiZ
d893df02aa Fix mealie-install.sh: use uv sync, add .env file, use uv run for systemd service 2025-11-20 13:44:32 +01:00
CanbiZ
52847c8dd8 Fix motd_ssh console issue: remove systemctl restart that breaks getty TTY 2025-11-20 13:34:42 +01:00
CanbiZ
79b44d3007 Update core.func 2025-11-20 11:29:26 +01:00
CanbiZ
b7430c20fe Update remaining pve_check functions to support Proxmox 9.0 and 9.1 2025-11-19 16:42:59 +01:00
CanbiZ
9e22bee07e Extend PVE support to version 9.0 and 9.1 in all pve_check functions 2025-11-19 16:39:05 +01:00
CanbiZ
686e1988b3 Fix motd_ssh timing in description() - remove late post-install call 2025-11-17 17:22:54 +01:00
CanbiZ
5ed03e1c62 Lowercase APPLICATION variable for credentials filenames (e.g. plex.creds instead of Plex.creds) 2025-11-17 16:18:15 +01:00
CanbiZ
9607c83465 Compact network check output: combine IPv4/IPv6 status into single line 2025-11-17 16:11:14 +01:00
CanbiZ
1c80a22685 Add container cleanup prompt to error_handler for build failures (e.g. GPU passthrough errors) 2025-11-17 16:02:29 +01:00
CanbiZ
d08d3ec424 Fix: remove debug echo from post_to_api, fix dev_index arithmetic in GPU passthrough (set -e compatible) 2025-11-17 15:44:56 +01:00
CanbiZ
68aa1df1b6 Fix GPU passthrough: use dev0/dev1 format instead of lxc.mount.entry, fix GID detection, cleanup output 2025-11-17 15:25:45 +01:00
CanbiZ
a7daaee5ae Refactor dev MOTD/SSH setup and journal cleanup
Moved MOTD/SSH setup for dev mode in LXC containers to run after installation and when containers are kept for debugging, improving reliability and clarity. Updated journalctl cleanup to avoid using $STD and suppress errors if systemd-journald is not initialized. Also refactored indentation in misc/api.func for consistency.
2025-11-17 15:09:36 +01:00
CanbiZ
1090081a66 remove ipv6 from api 2025-11-17 15:01:22 +01:00
CanbiZ
b5d3293202 typo 2025-11-17 14:58:29 +01:00
CanbiZ
db70e9ac34 Merge branch 'main' of https://github.com/community-scripts/ProxmoxVED 2025-11-17 14:56:29 +01:00
CanbiZ
6e98e359d8 post 2 api + error_handling
Switches from a comma-separated FEATURES string to a FEATURES_ARRAY for proper Proxmox parameter handling. Refactors PCT_OPTIONS to an array for safer argument passing, updates container creation calls, and adds API reporting after container creation.
2025-11-17 14:56:18 +01:00
4f1199a06e add testing echo 2025-11-17 14:51:46 +01:00
CanbiZ
2d35c9011a Normalize feature flags to numeric values in build.func
Moved normalization of feature flags (ENABLE_NESTING, ENABLE_KEYCTL, ENABLE_MKNOD, ENABLE_FUSE, PROTECT_CT) to base_settings() for consistent 0/1 values. Updated build_container() to rely on pre-normalized flags and fixed ENABLE_FUSE check. Improved pct create log file naming for uniqueness.
2025-11-17 14:41:51 +01:00
CanbiZ
414b36410d Normalize feature flags to numeric values in build.func
Updated ENABLE_NESTING, ENABLE_KEYCTL, and ENABLE_MKNOD normalization to ensure they are set to 0 or 1, as required by pct. This improves compatibility and prevents issues with non-numeric values.
2025-11-17 14:35:59 +01:00
CanbiZ
26aca1ce09 silent upgrade container 2025-11-17 14:26:32 +01:00
CanbiZ
e2179db113 Refactor MOTD/SSH setup in build script
Simplifies MOTD and SSH setup by sourcing common install functions and conditionally running motd_ssh. Improves error handling and messaging for debugging access during container initialization.
2025-11-17 14:22:48 +01:00
CanbiZ
82439d30cd Add msg_dev function for dev mode messaging
Introduces a new msg_dev function in core.func to standardize development/debugging messages. Updates build.func to use msg_dev for clearer dev mode output, replacing previous msg_custom and msg_info usages for MOTD/SSH setup and container debugging steps.
2025-11-17 14:22:22 +01:00
CanbiZ
ee5dc898f9 Update build.func 2025-11-17 14:00:52 +01:00
CanbiZ
73d6cabb52 Add advanced Proxmox container feature support
Introduces support for advanced Proxmox container features including nesting, keyctl, mknod, mount filesystems, protection flag, and timezone. Updates variable handling, settings UI, and container build logic to allow configuration and passing of these options.
2025-11-17 13:48:59 +01:00
CanbiZ
0bcd88685c Improve error handling during app installer run
Expanded comments and adjusted error handling logic when running the application installer in the container. All error traps are disabled before lxc-attach and restored after, ensuring host error_handler does not interfere with container-level error management.
2025-11-17 13:19:39 +01:00
CanbiZ
916293d98d introduce dev_mode
Introduces granular dev_mode flags (motd, keep, trace, pause, breakpoint, logs, dryrun) with a parser and exports for container builds. Enables persistent log directories when logs mode is active, supports dryrun and trace modes, and adds MOTD/SSH setup and breakpoint shell for debugging. Refactors related logic in build.func, core.func, and install.func for improved developer experience and debugging.
2025-11-17 12:53:26 +01:00
CanbiZ
c2b7f4e298 Improve container build/install logging and error handling
Introduces distinct BUILD_LOG and INSTALL_LOG variables for host and container operations, ensuring logs are properly captured and retrievable. Refactors silent execution and error handling to use the active log file, improves log copying after failures, and enhances context detection for log management. Also adds fallback logic for INSTALL_LOG initialization in install.func.
2025-11-17 12:45:24 +01:00
CanbiZ
06a4091019 Improve container install error handling and logging
Enhances reliability of application installation error detection in containers by using an error flag file, improves log copying and user prompts, and updates error handler to create a flag file with the exit code for host-side detection.
2025-11-17 12:23:51 +01:00
CanbiZ
5386da93e8 Handle failed LXC install and cleanup in build.func
Moved failed LXC installation cleanup logic from error_handler.func to build.func. Now, if installation fails, the user is prompted to remove the broken container with a 60s timeout, and the installation log is copied for debugging. Removed the cleanup_failed_lxc function and related trap from error_handler.func for better encapsulation.
2025-11-17 12:11:09 +01:00
CanbiZ
70a72f1356 Add cleanup handler for failed LXC installations
Introduces the cleanup_failed_lxc function to prompt for and remove broken containers after failed LXC installs. Updates catch_errors to invoke this cleanup on EXIT, ensuring failed containers are handled automatically or with user confirmation.
2025-11-17 11:46:51 +01:00
CanbiZ
c9d7c2f46b add exit_codes.md 2025-11-17 11:39:14 +01:00
CanbiZ
ee5fe3439d extend error messages 206,207,208,209 / 215, 216, 217, 218 / 222, 223, 231 2025-11-17 11:36:00 +01:00
CanbiZ
36f5e32d48 Inline explain_exit_code and clean diagnostics_check docs
Moved the explain_exit_code function directly into api.func, removing external dependency loading. Also cleaned up merge conflict markers and unified documentation for diagnostics_check in build.func.
2025-11-17 11:26:59 +01:00
CanbiZ
2f2adaea37 Merge branch 'main' of https://github.com/community-scripts/ProxmoxVED 2025-11-17 11:21:23 +01:00
CanbiZ
fc59aaede6 fix fi 2025-11-17 11:20:48 +01:00
CanbiZ
c0fc74bc9c Add detailed documentation and refactor core functions
Expanded inline documentation and section headers across misc/api.func, misc/build.func, misc/core.func, misc/error_handler.func, and misc/install.func for improved maintainability and clarity. Refactored error handling to use centralized explain_exit_code and updated API telemetry/reporting logic. Enhanced modularity and structure of utility, validation, and setup functions, and improved comments for user guidance and developer onboarding.
2025-11-17 11:17:04 +01:00
CanbiZ
432fc70e6e switch funcs 2025-11-17 10:45:28 +01:00
Tobias
b101b5b56b
Fix typo in PostgreSQL setup message 2025-11-14 13:58:18 +01:00
CanbiZ
f9a5ea27f3 Update tools.func 2025-11-12 15:18:18 +01:00
CanbiZ
5ade2b2237 Refactor Docker-VM 2025-11-11 13:45:03 +01:00
CanbiZ
59d684731d fixing outputs 2025-11-11 11:16:03 +01:00
CanbiZ
97f63f5189 Add Cloud-Init helper and refactor Docker VM script
Introduces misc/cloud-init.sh, a universal Cloud-Init helper library for Proxmox VM scripts. Refactors vm/docker-vm.sh to source the new Cloud-Init library, reorganizes variable initialization, improves OS and configuration selection logic, and enhances user interaction for VM creation. Also adds a backup of the previous docker-vm.sh as docker-vm.sh.bak.
2025-11-11 09:55:05 +01:00
CanbiZ
336d43ae58 Reindent all functions to 2-space style
Changed indentation from 4 spaces to 2 spaces for all functions in misc/core.func to improve consistency and readability. No functional changes were made.
2025-11-10 16:01:58 +01:00
CanbiZ
f96e1456e7 Update core.func 2025-11-10 15:53:56 +01:00