Skip to content

Commit

Permalink
Basic linting on Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
mec committed Nov 12, 2024
1 parent 70f732c commit 8375a51
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# ------------------------------------------------------------------------------
# Base
# ------------------------------------------------------------------------------
FROM ruby:3.3.6 as base
FROM ruby:3.3.6 AS base
LABEL org.opencontainers.image.authors="[email protected]"

COPY .node-version .node-version
Expand All @@ -17,12 +17,12 @@ RUN \
build-essential \
libpq-dev

ENV APP_HOME /srv/app
ENV DEPS_HOME /deps
ENV APP_HOME=/srv/app
ENV DEPS_HOME=/deps

ARG RAILS_ENV
ENV RAILS_ENV ${RAILS_ENV:-production}
ENV NODE_ENV ${RAILS_ENV:-production}
ENV RAILS_ENV=${RAILS_ENV:-production}
ENV NODE_ENV=${RAILS_ENV:-production}

# ------------------------------------------------------------------------------
# Dependencies
Expand All @@ -34,7 +34,7 @@ RUN apt-get update && apt-get install -y yarn
WORKDIR ${DEPS_HOME}

# Install Ruby dependencies
ENV BUNDLE_GEM_GROUPS ${RAILS_ENV}
ENV BUNDLE_GEM_GROUPS=${RAILS_ENV}

COPY Gemfile ${DEPS_HOME}/Gemfile
COPY Gemfile.lock ${DEPS_HOME}/Gemfile.lock
Expand Down Expand Up @@ -109,8 +109,8 @@ RUN \
ARG CURRENT_GIT_SHA
ARG TIME_OF_BUILD

ENV CURRENT_GIT_SHA ${CURRENT_GIT_SHA}
ENV TIME_OF_BUILD ${TIME_OF_BUILD}
ENV CURRENT_GIT_SHA=${CURRENT_GIT_SHA}
ENV TIME_OF_BUILD=${TIME_OF_BUILD}

COPY ./docker-entrypoint.sh /
RUN chmod +x /docker-entrypoint.sh
Expand All @@ -123,7 +123,7 @@ CMD ["bundle", "exec", "rails", "server"]
# ------------------------------------------------------------------------------
# Test
# ------------------------------------------------------------------------------
FROM web as test
FROM web AS test

RUN \
apt-get update && \
Expand Down

0 comments on commit 8375a51

Please sign in to comment.