mirror of
https://github.com/livebook-dev/livebook.git
synced 2025-01-11 01:18:12 +08:00
10 lines
447 B
Elixir
10 lines
447 B
Elixir
export RELEASE_NODE=${LIVEBOOK_NODE:-${RELEASE_NODE:-livebook_server}}
|
|
export RELEASE_DISTRIBUTION=${LIVEBOOK_DISTRIBUTION:-${RELEASE_DISTRIBUTION:-sname}}
|
|
export RELEASE_MODE=interactive
|
|
|
|
cookie_path="${RELEASE_ROOT}/releases/COOKIE"
|
|
if [ ! -f $cookie_path ]; then
|
|
RELEASE_COOKIE=$(cat /dev/urandom | env LC_ALL=C tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)
|
|
echo "$RELEASE_COOKIE" > "$cookie_path"
|
|
[ $? -eq 0 ] || export RELEASE_COOKIE
|
|
fi
|