Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating ClamAV engine with offical version 1.2.1 #1248

Merged
merged 1 commit into from
Dec 1, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ARG ruby_version=3.2.2
ARG base_image=ghcr.io/alphagov/govuk-ruby-base:$ruby_version
ARG builder_image=ghcr.io/alphagov/govuk-ruby-builder:$ruby_version

ARG clam_engine=clamav-1.2.1.linux.x86_64.deb

FROM $builder_image AS builder

Expand All @@ -14,13 +14,15 @@ RUN bootsnap precompile --gemfile .

FROM $base_image

ARG clam_engine
ENV GOVUK_APP_NAME=asset-manager

# TODO: move ClamAV into a completely separate service.
RUN install_packages clamav clamav-daemon clamdscan shared-mime-info && \
rm -fr /etc/clamav/* && \
mkdir -p /var/run/clamav && \
chown app:app /var/run/clamav /var/lib/clamav
RUN install_packages wget shared-mime-info && \
wget https://www.clamav.net/downloads/production/$clam_engine && \
apt install ./$clam_engine && rm ./$clam_engine && \
mkdir -p /var/run/clamav /var/lib/clamav /usr/local/share/clamav && \
chown app:app /var/run/clamav /var/lib/clamav /usr/local/share/clamav

WORKDIR $APP_HOME
COPY --from=builder $BUNDLE_PATH $BUNDLE_PATH
Expand Down