Create dummy COOKIE file in Nix package to avoid runtime error

This commit is contained in:
ryan 2025-08-02 20:09:57 -07:00
parent 495152826f
commit 8cbad5c849
2 changed files with 3 additions and 1 deletions

View File

@ -12,6 +12,9 @@ beamPackages.mixRelease rec {
# Disable distributed Erlang to avoid COOKIE requirement # Disable distributed Erlang to avoid COOKIE requirement
postInstall = '' postInstall = ''
# Create a dummy COOKIE file to satisfy the release boot script
echo "dummy_cookie" > $out/releases/COOKIE
# Create wrapper script that sets proper environment # Create wrapper script that sets proper environment
mv $out/bin/systant $out/bin/.systant-wrapped mv $out/bin/systant $out/bin/.systant-wrapped
cat > $out/bin/systant << EOF cat > $out/bin/systant << EOF

View File

@ -35,7 +35,6 @@ defmodule SystemStatsDaemon.MixProject do
applications: [runtime_tools: :permanent], applications: [runtime_tools: :permanent],
include_erts: true, include_erts: true,
strip_beams: false, strip_beams: false,
cookie: :disabled,
env: %{ env: %{
"RELEASE_DISTRIBUTION" => "none", "RELEASE_DISTRIBUTION" => "none",
"RELEASE_NODE" => "nonode@nohost" "RELEASE_NODE" => "nonode@nohost"