mirror of
https://github.com/unraid/api.git
synced 2026-01-06 00:30:22 -06:00
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Enhanced automated build and release processes with containerized builds, improved caching, and refined artifact handling. - Introduced new configuration options to strengthen versioning, integrity checks, and pull request tracking. - Added a new Dockerfile for building the Node.js application. - Added new environment variables for API versioning and validation control. - Implemented comprehensive management of PM2 processes and state. - Introduced a new GitHub Actions workflow for automating staging plugin deployment upon pull request closure. - Updated logic for handling plugin installation and error feedback. - Added new asynchronous methods for managing PM2 processes. - Updated logging configurations for better control over log outputs. - Added Prettier configuration for consistent code formatting. - Introduced a configuration to prevent the application from watching for file changes. - **Bug Fixes** - Improved error handling and user feedback during the installation of staging versions. - **Documentation** - Removed outdated introductory documentation to streamline project information. - **Chores** - Updated deployment routines and validation steps to improve release consistency and error handling. - Simplified packaging and build scripts for smoother staging and production workflows. - Excluded sensitive files from the Docker build context. - Updated the `.gitignore` file to prevent unnecessary files from being tracked. - Adjusted the test timeout configuration for improved test reliability. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
34 lines
565 B
Bash
Executable File
34 lines
565 B
Bash
Executable File
#!/bin/bash
|
|
# unraid-api-handler
|
|
|
|
# shellcheck source=/dev/null
|
|
source /etc/profile
|
|
|
|
flash="/boot/config/plugins/dynamix.my.servers"
|
|
[[ ! -d "${flash}" ]] && echo "Please reinstall the Unraid Connect plugin" && exit 1
|
|
[[ ! -f "${flash}/env" ]] && echo 'env=production' >"${flash}/env"
|
|
unraid_binary_path="/usr/local/bin/unraid-api"
|
|
|
|
install() {
|
|
true;
|
|
}
|
|
uninstall() {
|
|
true;
|
|
}
|
|
|
|
case "$1" in
|
|
'install')
|
|
install "$2"
|
|
;;
|
|
'reload')
|
|
restart
|
|
;;
|
|
'uninstall')
|
|
uninstall
|
|
;;
|
|
*)
|
|
# Pass all other commands to unraid-api
|
|
"${unraid_binary_path}" "$@"
|
|
;;
|
|
esac
|