Skip to content
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

Enable Container run with readonly root filesystem #246

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ RUN apt-get update && \
apt-get -y install bash procps openssl iproute2 curl jq libsnappy-dev net-tools nano && \
rm -rf /var/lib/apt/lists/* && \
addgroup --gid 10000 vernemq && \
adduser --uid 10000 --system --ingroup vernemq --home /vernemq --disabled-password vernemq
adduser --uid 10000 --system --ingroup vernemq --home /vernemq/data/home --disabled-password vernemq

WORKDIR /vernemq

Expand Down
3 changes: 3 additions & 0 deletions bin/vernemq.sh
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,9 @@ if [ ! -z "$DOCKER_VERNEMQ_ERLANG__DISTRIBUTION_BUFFER_SIZE" ]; then
sed -i.bak -r "s/\+zdbbl.+/\+zdbbl ${DOCKER_VERNEMQ_ERLANG__DISTRIBUTION_BUFFER_SIZE}/" ${VERNEMQ_VM_ARGS_FILE}
fi

mkdir -p /vernemq/data/home
chmod g-rwx /vernemq/data/home/.erlang.cookie

# Check configuration file
/vernemq/bin/vernemq config generate 2>&1 > /dev/null | tee /tmp/config.out | grep error

Expand Down