Enhance README and build scripts for hardware-specific optimizations
- Updated README.md to clarify development setup for macOS/Docker and added production build instructions for specific hardware. - Introduced new build scripts for optimized OS images targeting Start9 Server Pure, HP ProDesk 400 G4 DM, and Dell OptiPlex. - Enhanced Dockerfile to specify platform compatibility and improved Alpine profile for Archipelago builds. - Updated configuration files and init scripts to support new hardware profiles and ensure proper service management.
This commit is contained in:
52
image-recipe/alpine-profile/overlay-merged/etc/init.d/archipelago
Executable file
52
image-recipe/alpine-profile/overlay-merged/etc/init.d/archipelago
Executable file
@@ -0,0 +1,52 @@
|
||||
#!/sbin/openrc-run
|
||||
# Archipelago Bitcoin Node OS Backend
|
||||
|
||||
name="Archipelago"
|
||||
description="Archipelago Bitcoin Node OS Backend Server"
|
||||
command="/usr/bin/archipelago-backend"
|
||||
command_user="archipelago:archipelago"
|
||||
command_background=true
|
||||
pidfile="/var/run/archipelago.pid"
|
||||
start_stop_daemon_args="--make-pidfile"
|
||||
|
||||
# Working directory and environment
|
||||
directory="/var/lib/archipelago"
|
||||
export RUST_LOG="${RUST_LOG:-info}"
|
||||
export ARCHIPELAGO_DATA_DIR="/var/lib/archipelago"
|
||||
export ARCHIPELAGO_PORT="${ARCHIPELAGO_PORT:-8100}"
|
||||
|
||||
depend() {
|
||||
need net
|
||||
need localmount
|
||||
after firewall
|
||||
use podman docker
|
||||
}
|
||||
|
||||
start_pre() {
|
||||
# Ensure directories exist
|
||||
checkpath --directory --mode 0755 --owner archipelago:archipelago \
|
||||
/var/lib/archipelago \
|
||||
/var/lib/archipelago/apps \
|
||||
/var/lib/archipelago/secrets \
|
||||
/var/lib/archipelago/logs \
|
||||
/var/lib/archipelago/backups
|
||||
|
||||
# Wait for network to be fully ready
|
||||
local retries=30
|
||||
while [ $retries -gt 0 ]; do
|
||||
if ping -c 1 -W 1 8.8.8.8 >/dev/null 2>&1; then
|
||||
einfo "Network is ready"
|
||||
return 0
|
||||
fi
|
||||
retries=$((retries - 1))
|
||||
sleep 1
|
||||
done
|
||||
|
||||
ewarn "Network may not be fully ready"
|
||||
return 0
|
||||
}
|
||||
|
||||
start_post() {
|
||||
einfo "Archipelago backend started"
|
||||
einfo "Access the UI at: http://$(hostname -I | awk '{print $1}'):8100"
|
||||
}
|
||||
Reference in New Issue
Block a user