Skip to content

Commit

Permalink
Merge pull request #42 from alphagov/sengi/fix-image
Browse files Browse the repository at this point in the history
Remove unnecessary packages from image + update deps.
  • Loading branch information
sengi authored May 15, 2024
2 parents 09e63f9 + 0145d5f commit 036a178
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 20 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
show-progress: false

- name: Setup Ruby
uses: ruby/setup-ruby@v1
Expand Down
15 changes: 13 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,20 @@
ARG ruby_version=3.3
FROM ghcr.io/alphagov/govuk-ruby-builder:$ruby_version
ARG base_image=ghcr.io/alphagov/govuk-ruby-base:$ruby_version
ARG builder_image=ghcr.io/alphagov/govuk-ruby-builder:$ruby_version


FROM --platform=$TARGETPLATFORM $builder_image AS builder

WORKDIR $APP_HOME
COPY Gemfile* .ruby-version ./
RUN bundle install
COPY . .
USER app


FROM --platform=$TARGETPLATFORM $base_image
WORKDIR $APP_HOME
COPY --from=builder $BUNDLE_PATH $BUNDLE_PATH
COPY --from=builder $APP_HOME .

USER app
CMD ["./collect"]
34 changes: 16 additions & 18 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -15,41 +15,40 @@ GEM
public_suffix (>= 2.0.2, < 6.0)
ast (2.4.2)
base64 (0.2.0)
bigdecimal (3.1.7)
bigdecimal (3.1.8)
climate_control (1.2.0)
concurrent-ruby (1.2.3)
connection_pool (2.4.1)
crack (1.0.0)
bigdecimal
rexml
diff-lcs (1.5.1)
domain_name (0.5.20190701)
unf (>= 0.0.5, < 1.0.0)
domain_name (0.6.20240107)
drb (2.2.1)
hashdiff (1.1.0)
http-accept (1.7.0)
http-cookie (1.0.5)
domain_name (~> 0.5)
i18n (1.14.4)
i18n (1.14.5)
concurrent-ruby (~> 1.0)
json (2.7.1)
json (2.7.2)
language_server-protocol (3.17.0.3)
mime-types (3.5.1)
mime-types (3.5.2)
mime-types-data (~> 3.2015)
mime-types-data (3.2023.1003)
mime-types-data (3.2024.0507)
minitest (5.22.3)
mutex_m (0.2.0)
netrc (0.11.0)
parallel (1.24.0)
parser (3.3.0.5)
parser (3.3.1.0)
ast (~> 2.4.1)
racc
prometheus-client (4.2.2)
public_suffix (5.0.4)
public_suffix (5.0.5)
racc (1.7.3)
rack (3.0.10)
rack (3.0.11)
rainbow (3.1.1)
regexp_parser (2.9.0)
regexp_parser (2.9.1)
rest-client (2.1.0)
http-accept (>= 1.7.0, < 2.0)
http-cookie (>= 1.0.2, < 2.0)
Expand All @@ -65,10 +64,10 @@ GEM
rspec-expectations (3.13.0)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.13.0)
rspec-mocks (3.13.0)
rspec-mocks (3.13.1)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.13.0)
rspec-support (3.13.0)
rspec-support (3.13.1)
rubocop (1.62.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
Expand Down Expand Up @@ -104,7 +103,7 @@ GEM
rubocop-capybara (~> 2.17)
rubocop-factory_bot (~> 2.22)
rubocop-rspec_rails (~> 2.28)
rubocop-rspec_rails (2.28.2)
rubocop-rspec_rails (2.28.3)
rubocop (~> 1.40)
ruby-progressbar (1.13.0)
sentry-ruby (5.17.3)
Expand All @@ -113,16 +112,15 @@ GEM
timecop (0.9.8)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unf (0.1.4)
unf_ext
unf_ext (0.0.8.2)
unicode-display_width (2.5.0)
webmock (3.23.0)
addressable (>= 2.8.0)
crack (>= 0.3.2)
hashdiff (>= 0.4.0, < 2.0.0)

PLATFORMS
aarch64-linux
ruby
x86_64-linux

DEPENDENCIES
Expand All @@ -136,4 +134,4 @@ DEPENDENCIES
webmock

BUNDLED WITH
2.4.10
2.5.10

0 comments on commit 036a178

Please sign in to comment.