2021-12-18 18:31:38 +01:00
|
|
|
FROM alpine:3.14
|
2021-12-18 11:25:31 +01:00
|
|
|
|
|
|
|
ENV BUILD_PKGS="build-base ruby-dev libffi-dev libxml2-dev mariadb-dev" \
|
|
|
|
RUNTIME_PKGS="ruby ruby-json ruby-bigdecimal ruby-irb ruby-bundler ca-certificates mariadb-client" \
|
|
|
|
DEVELOPMENT_PKGS="bash"
|
|
|
|
|
|
|
|
RUN apk --no-cache add $BUILD_PKGS $RUNTIME_PKGS $DEVELOPMENT_PKGS
|
|
|
|
|
|
|
|
RUN adduser -D -u 1000 -h /srv/app -s /bin/bash app
|
|
|
|
WORKDIR /srv/app
|
|
|
|
USER app
|
|
|
|
|
|
|
|
ENV BUNDLE_JOBS=4 \
|
|
|
|
BUNDLE_PATH=/srv/app/vendor/bundle \
|
|
|
|
GEM_PATH=/srv/app/vendor/bundle:$GEM_PATH \
|
|
|
|
PATH=/srv/app/vendor/bundle/bin:$PATH
|
|
|
|
|
|
|
|
EXPOSE 3000
|
|
|
|
|
|
|
|
CMD ["bash"]
|