Skip to content

support ErlangVM in AWS Layers #80

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 9 additions & 7 deletions priv/erlang-start
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,6 @@ $(mkdir -p "${RUN_DIR}/checkpointfs")
$(mkdir -p "${RUN_DIR}/tmpfs")
$(mkdir -p "${RUN_DIR}/ramfs")

echo "OpenSSL is $(openssl version)"
# ciphers=$(openssl ciphers 'ALL:eNULL' | sed -e 's/:/ /g')
# echo "OpenSSL cyphers are $ciphers"

echo "starting ErlangVM"

SCRIPT=$(readlink $0 || true)
if [ -z $SCRIPT ]; then
SCRIPT=$0
Expand All @@ -26,7 +20,15 @@ SCRIPT_DIR="$(cd `dirname "$SCRIPT"` && pwd -P)"
RELEASE_ROOT_DIR="$(cd "$SCRIPT_DIR/.." && pwd -P)"
REL_DIRS=(${RELEASE_ROOT_DIR}/releases/[0-9]*)
REL_DIR=${REL_DIRS[-1]}
ERTS_DIR=(${RELEASE_ROOT_DIR}/erts-*)
# account for potential Erlang Lambda Layer
export ERTS_PATH="/opt/erts-*"
if [ -d ${ERTS_PATH} ]; then
echo "starting ErlangVM from a layer at ${ERTS_PATH}"
ERTS_DIR=(${ERTS_PATH})
else
echo "starting ErlangVM"
ERTS_DIR=(${RELEASE_ROOT_DIR}/erts-*)
fi;
ERTS_LIB_DIR="${ERTS_DIR}/lib"
export NATIVELIB_DIR=${ERTS_LIB_DIR}
export REL_NAME="$(basename $SCRIPT)"
Expand Down