#!/bin/sh set -eu # All writers of this local persistent store must use this launcher. The lock # file itself must never be removed: flock releases ownership on process death. : "${OAUTH_STORE_PATH:?Set OAUTH_STORE_PATH to a persistent writable file}" mkdir -p "$(dirname "$OAUTH_STORE_PATH")" exec flock --nonblock --no-fork "${OAUTH_STORE_PATH}.launcher.lock" sh -c ' rm -f -- "${OAUTH_STORE_PATH}.lock" exec node scripts/serve-atproto.mjs '