Files
proxmox/scripts/monitoring/enhanced-besu-validator.service

50 lines
930 B
SYSTEMD
Raw Normal View History

[Unit]
Description=Hyperledger Besu Validator Node (Enhanced with Health Checks)
After=network-online.target
Wants=network-online.target
[Service]
Type=simple
User=besu
Group=besu
WorkingDirectory=/opt/besu
# Enhanced restart policy
Restart=always
RestartSec=10
StartLimitInterval=300
StartLimitBurst=5
# Health check before start
ExecStartPre=/usr/local/bin/check-validator-prerequisites.sh
ExecStartPre=/bin/sleep 2
# Main service
ExecStart=/opt/besu/bin/besu \
--config-file=/etc/besu/config-validator.toml
# Health check after start
ExecStartPost=/usr/local/bin/verify-validator-started.sh
ExecStartPost=/bin/sleep 5
# Stop gracefully
TimeoutStopSec=30
KillMode=mixed
KillSignal=SIGTERM
# Resource limits
LimitNOFILE=65536
LimitNPROC=32768
# Logging
StandardOutput=journal
StandardError=journal
SyslogIdentifier=besu-validator
# Security
NoNewPrivileges=true
PrivateTmp=true
[Install]
WantedBy=multi-user.target