Bastian (BaM)
e6dea9fc3f
Update external tool command for Wake-on-LAN functionality
...
Change the command from 'wakeonlan' to 'wol' in the network module for better compatibility. Update log messages to reflect the new tool being used.
2025-09-15 08:49:30 +02:00
Bastian (BaM)
8cb6d55782
Refactor to use LuaJIT and improve performance
...
Integrate LuaJIT as an optional runtime for better performance, with a fallback to standard Lua 5.4. Update Dockerfile to install LuaJIT and create a wrapper script for execution. Enhance network module with socket fallback support and update README to reflect these changes and configuration options.
2025-09-15 08:44:19 +02:00
Bastian (BaM)
fff635c2d7
Add README.md for Auto-Boot Ollama Host project
...
Introduce a comprehensive README file detailing the project's purpose, features, environment variables, usage instructions, project structure, and how it operates. This addition enhances documentation and provides clarity for users and developers.
2025-09-14 21:34:43 +02:00
Bastian (BaM)
fed3cdc728
Fix capitalization in log messages
2025-09-14 21:17:26 +02:00
Bastian (BaM)
93bccebdff
Refactor error and finish pattern handling in auto-boot-ollama-host script
...
Update the handle_error_pattern and handle_finish_pattern functions to return the powered_on state. This change improves the clarity of the powered_on logic and ensures consistent state management during Ollama startup and shutdown processes.
2025-09-14 20:40:50 +02:00
Bastian (BaM)
76ddedbf14
Add debug logging for SSH command execution
...
Introduce a function to check the DEBUG environment variable and adjust logging behavior accordingly. When DEBUG is enabled, full SSH command details are logged; otherwise, only the command itself is logged to prevent exposure of sensitive information.
2025-09-14 20:31:24 +02:00
Bastian (BaM)
e8b11d43da
Increase sleep duration before starting the ollama service from 5 to 10 seconds to ensure better SSH readiness.
2025-09-14 20:19:42 +02:00
Bastian (BaM)
94da305b17
Quote remote commands in SSH execution to prevent shell interpretation of special characters
2025-09-14 20:16:27 +02:00
Bastian (BaM)
eb83c4ccbd
Add desktop session detection to auto-boot-ollama-host script
...
Implement a new module for checking if the user is logged into a Windows desktop session. The script now skips Ollama startup and shutdown if the user is currently logged in, preventing interruptions. Update README to reflect new features and module structure.
2025-09-14 18:27:39 +02:00
Bastian (BaM)
80976be664
Remove auto-boot-ollama-host script as it is no longer needed for the current setup.
2025-09-14 17:44:53 +02:00
Bastian (BaM)
886d1c86cf
Update Dockerfile to copy all scripts from the scripts directory for improved flexibility in script management
2025-09-14 17:38:43 +02:00
Bastian (BaM)
149d8b2191
Refactor auto-boot-ollama-host script into modular structure with separate configuration, network, SSH, and service management modules for improved maintainability and readability
2025-09-14 17:37:12 +02:00
Bastian (BaM)
1442eb3df7
Add SSH_USER environment variable to configuration and update SSH command references in the script
2025-09-14 17:31:28 +02:00
Bastian (BaM)
8537c0c312
Increase sleep duration before starting the ollama service to ensure SSH readiness
2025-09-14 15:59:47 +02:00
Bastian (BaM)
1a137f0894
Refactor SSH commands to use nssm for managing the ollama service
2025-09-14 15:49:59 +02:00
Bastian (BaM)
2e50d69d53
Update log message for clarity when restarting log watch loop
2025-09-14 15:03:48 +02:00
Bastian (BaM)
90b918512c
Update error pattern message for SSH connection failure to enhance clarity
2025-09-14 15:01:39 +02:00
Bastian (BaM)
2669ccfd02
Refactor SSH command execution to improve command structure and remove unnecessary quoting
2025-09-14 14:50:56 +02:00
Bastian (BaM)
ee9fb7ff52
Refactor SSH command execution to improve command quoting and enhance readability
2025-09-14 14:43:26 +02:00
Bastian (BaM)
2af2cde9c1
Refactor SSH command execution to remove unnecessary quoting and improve command handling
2025-09-14 14:39:05 +02:00
Bastian (BaM)
535fadbf5f
Fix SSH command execution by appending '&& true' to ensure proper handling of command success
2025-09-14 14:29:54 +02:00
Bastian (BaM)
11cc5779b5
Add WOL state tracking to manage shutdown logic for Ollama host
2025-09-14 14:23:46 +02:00
Bastian (BaM)
e743f61aef
Refactor log monitoring loop to continuously check for error and finish patterns, enhancing Ollama service management
2025-09-14 14:20:20 +02:00
Bastian (BaM)
adff6a42d1
Increase SSH connection timeout to 30 seconds and adjust sleep duration to 30 seconds for improved service availability
2025-09-14 14:18:23 +02:00
Bastian (BaM)
1424458bcb
Add FINISH_PATTERN detection and adjust shutdown logic for Ollama host
2025-09-14 14:15:49 +02:00
Bastian (BaM)
05b799ff94
Fix SSH command quoting for service management and increase shutdown delay to 180 seconds
2025-09-14 14:10:30 +02:00
Bastian (BaM)
cf0f039ee5
Fix SSH command quoting for service management and increase shutdown delay to 180 seconds
2025-09-14 14:09:24 +02:00
Bastian (BaM)
86e5cd3042
Increase delay before shutting down Ollama host to 180 seconds for improved power management
2025-09-14 14:06:25 +02:00
Bastian (BaM)
c971bf196a
Fix SSH command to enable ollama service without redundant arguments
2025-09-14 14:05:38 +02:00
Bastian (BaM)
3ebb6fecc5
Fix SSH command quoting to ensure proper argument handling
2025-09-14 13:59:59 +02:00
Bastian (BaM)
d092952df8
Fix SSH command quoting and improve ollama service management logic
2025-09-14 13:55:43 +02:00
Bastian (BaM)
006b7c716e
Enhance ollama service management: increase delay before starting service, add shutdown logic after service reachability check
2025-09-14 13:47:52 +02:00
Bastian (BaM)
5d26effe64
Fix SSH command execution syntax for ollama service startup
2025-09-14 13:44:46 +02:00
Bastian (BaM)
77a8dc85d3
Rename id file to id_rsa
2025-09-14 13:39:21 +02:00
Bastian (BaM)
903b4aa51b
Add log message for SSH reachability check before starting ollama service
2025-09-14 13:37:18 +02:00
Bastian (BaM)
cd99ea8779
Add delay before starting ollama service after confirming SSH reachability
2025-09-14 13:35:30 +02:00
Bastian (BaM)
0c42d35b09
Refactor SSH command execution and enhance port checking logic in Lua script
2025-09-14 13:34:44 +02:00
Bastian (BaM)
bda835e9f8
Add .dockerignore and update Dockerfile and compose.yaml for SSH key handling
2025-09-14 13:28:35 +02:00
Bastian (BaM)
ee29740c6b
Comment out SSH key environment variables in Docker Compose for improved security
2025-09-14 13:18:19 +02:00
Bastian (BaM)
87b282d9d0
Refactor SSH key handling in Dockerfile to ensure known_hosts is created before ssh-keyscan
2025-09-14 13:16:51 +02:00
Bastian (BaM)
57b20df159
Add OpenSSH client installation and SSH key handling in Dockerfile
2025-09-14 13:13:43 +02:00
Bastian (BaM)
59a19551fe
Unset SSH environment variables after key file creation for enhanced security
2025-09-14 12:47:44 +02:00
Bastian (BaM)
8e618e59db
Ensure .ssh directory exists before creating SSH identity file
2025-09-14 12:46:36 +02:00
Bastian (BaM)
09b4acd110
Ensure .ssh directory exists before creating SSH identity file
2025-09-14 12:45:44 +02:00
Bastian (BaM)
17125b6600
Add SSH key file creation from environment variables with error handling
2025-09-14 12:44:23 +02:00
Bastian (BaM)
134398879c
Fix indentation in main function for improved readability
2025-09-14 12:40:47 +02:00
Bastian (BaM)
eb1e8b6acf
Add SSH key environment variables for enhanced security
2025-09-14 12:33:52 +02:00
Bastian (BaM)
7637f748d1
Add SSH configuration options for enhanced connectivity
2025-09-14 12:29:44 +02:00
Bastian (BaM)
bb4cac4a2b
Refactor send_wol function to streamline magic packet creation and enforce IPv4 UDP socket binding
2025-09-14 11:10:50 +02:00
Bastian (BaM)
c57359daef
Enhance Wake-on-LAN functionality by forcing IPv4 UDP socket and adding source IP binding
2025-09-14 11:08:40 +02:00