rc.local and service manager for Alpine Linux.
Find a file
2026-03-27 18:36:40 +00:00
etc Aggiorna README.md 2026-03-27 18:35:43 +00:00
LICENSE Aggiungi LICENSE 2026-03-27 18:36:40 +00:00
README.md Aggiorna README.md 2026-03-27 18:35:43 +00:00
VERSION Aggiungi VERSION 2026-03-27 18:35:59 +00:00

local

rc.local and service manager for Alpine Linux.

Structure

etc/
  rc.local                    # script executed at boot (customizable)
  local.d/
    rc.start                  # starts services listed in services
    rc.stop                   # stops services listed in services (reverse order)
    services                  # list of services to manage (one per line)
  init.d/
    rc-local                  # OpenRC service that runs rc.local

Flow

boot  →  local (OpenRC)    →  /etc/local.d/rc.start  →  services ↑
      →  rc-local (OpenRC) →  /etc/rc.local
halt  →  local (OpenRC)    →  /etc/local.d/rc.stop   →  services ↓ (reverse)

Services

Edit /etc/local.d/services to list services to manage at boot:

# one service per line, # to comment
nginx
sshd