Sha256: be74ba6f1a73668c1fd3cfaafd5433f29c9913b6536916dc7582fa6970d8fa70

Contents?: true

Size: 1.54 KB

Versions: 24

Compression:

Stored size: 1.54 KB

Contents

# =============================================================================
# Target: base

FROM ruby:2.7-alpine AS base

RUN apk --no-cache --update upgrade && \
    apk --no-cache add \
        bash \
        ca-certificates \
        git \
        libc6-compat \
        openssl \
        tzdata \
        xz-libs \
    && rm -rf /var/cache/apk/*

WORKDIR /opt/app

# =============================================================================
# Target: development
#

FROM base AS development

# Install system packages needed to build gems with C extensions.
RUN apk --update --no-cache add \
        build-base \
        coreutils \
        git \
    && rm -rf /var/cache/apk/*

# The base image ships bundler 1.17.2, but we want something more recent
RUN gem install bundler -v 2.1.4

# Copy codebase to WORKDIR. Unlike application projects, for a gem project
# we need to do this before running `bundle install`, in order for the gem
# we're building to be able to "install" itself.
COPY . .

# Install gems.
RUN bundle install --path=/usr/local/bundle

# =============================================================================
# Target: production

FROM base AS production

# Copy the built codebase from the dev stage
COPY --from=development /opt/app /opt/app
COPY --from=development /usr/local/bundle /usr/local/bundle

# Sanity-check that everything was installed correctly and still runs in the
# slimmed-down production image.
RUN bundle config set deployment 'true'
RUN bundle install --local --path=/usr/local/bundle

CMD ['bundle', 'exec', 'rake']

Version data entries

24 entries across 24 versions & 3 rubygems

Version Path
berkeley_library-tind-0.7.2 Dockerfile
berkeley_library-tind-0.7.1 Dockerfile
berkeley_library-tind-0.7.0 Dockerfile
berkeley_library-logging-0.2.7 Dockerfile
berkeley_library-logging-0.2.6.2 Dockerfile
berkeley_library-logging-0.2.6.1 Dockerfile
berkeley_library-tind-0.6.0 Dockerfile
berkeley_library-tind-0.5.1 Dockerfile
berkeley_library-logging-0.2.6 Dockerfile
berkeley_library-tind-0.5.0 Dockerfile
berkeley_library-tind-0.4.3 Dockerfile
berkeley_library-marc-0.3.1 Dockerfile
berkeley_library-marc-0.3.0 Dockerfile
berkeley_library-logging-0.2.5 Dockerfile
berkeley_library-logging-0.2.4 Dockerfile
berkeley_library-marc-0.2.1 Dockerfile
berkeley_library-tind-0.4.2 Dockerfile
berkeley_library-logging-0.2.3 Dockerfile
berkeley_library-logging-0.2.2 Dockerfile
berkeley_library-tind-0.4.1 Dockerfile