Rough attempt to make this more efficient

This commit is contained in:
Felipe 2025-05-18 17:52:28 +00:00 committed by GitHub
parent ab4324c0eb
commit caba6a665f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,15 +1,34 @@
FROM ruby:3.4.3-alpine
FROM ruby:3.4.4-alpine AS builder
USER root
RUN apk add --no-cache \
build-base \
ruby-dev \
libffi-dev \
yaml-dev
WORKDIR /build
COPY Gemfile /build/
COPY *.gemspec /build/
COPY Gemfile Gemfile.lock ./
COPY *.gemspec ./
RUN gem update \
&& bundle config set jobs $(nproc) \
&& bundle install
RUN gem update --system && \
bundle config set jobs $(nproc) && \
bundle install --jobs=$(nproc) --retry=3 --without development test
COPY . /build
COPY . .
FROM ruby:3.4.3-alpine
USER root
RUN apk add --no-cache \
libffi \
yaml
WORKDIR /app
COPY --from=builder /usr/local/bundle /usr/local/bundle
COPY --from=builder /build /app
WORKDIR /
ENTRYPOINT [ "/build/bin/wayback_machine_downloader" ]
ENTRYPOINT [ "/app/bin/wayback_machine_downloader" ]