Skip to content

Commit

Permalink
Reduce image size
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikSchierboom committed Aug 10, 2023
1 parent 34a704f commit d87e0f7
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,22 @@
FROM ruby:2.6.6-alpine3.13
FROM ruby:2.6.6-alpine3.13 AS build

RUN apk update && apk upgrade && \
apk add --no-cache bash git openssh build-base gcc wget git
apk add --no-cache git openssh build-base gcc wget git

RUN gem install bundler -v 2.3.6

WORKDIR /opt/representer

COPY Gemfile Gemfile.lock .

RUN bundle install

FROM ruby:2.6.6-alpine3.13 AS runtime

RUN apk add --no-cache bash

WORKDIR /opt/representer

COPY --from=build /usr/local/bundle /usr/local/bundle

COPY . .

ENTRYPOINT ["sh", "/opt/representer/bin/run.sh"]
ENTRYPOINT ["sh", "/opt/representer/bin/run.sh"]

0 comments on commit d87e0f7

Please sign in to comment.