Skip to content
Merged
Show file tree
Hide file tree
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
14 changes: 7 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ USER root
RUN apk --no-cache upgrade && \
apk --no-cache add \
bash \
clamav \
clamav-daemon \
# clamav \
# clamav-daemon \
cmake \
exiftool \
ffmpeg \
Expand Down Expand Up @@ -37,10 +37,10 @@ RUN apk --no-cache upgrade && \
# cargo install rbspy && \
echo "******** Packages Installed *********"

RUN sed -i 's/User clamav/User app/g' /etc/clamav/clamd.conf
RUN mkdir -p /var/run/clamav && chown -R app:app /var/run/clamav
RUN mkdir -p /var/log/clamav && chown -R app:app /var/log/clamav
RUN chown -R app:app /var/lib/clamav
#RUN sed -i 's/User clamav/User app/g' /etc/clamav/clamd.conf
#RUN mkdir -p /var/run/clamav && chown -R app:app /var/run/clamav
#RUN mkdir -p /var/log/clamav && chown -R app:app /var/log/clamav
#RUN chown -R app:app /var/lib/clamav

RUN wget https://github.com/ImageMagick/ImageMagick/archive/refs/tags/7.1.0-57.tar.gz \
&& tar xf 7.1.0-57.tar.gz \
Expand Down Expand Up @@ -105,6 +105,6 @@ RUN RAILS_ENV=production SECRET_KEY_BASE=`bin/rake secret` DB_ADAPTER=nulldb DAT
CMD ./bin/web

FROM hyku-web AS hyku-worker
RUN freshclam
#RUN freshclam
ENV MALLOC_ARENA_MAX=2
CMD ./bin/worker
1 change: 1 addition & 0 deletions app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ def is_staging
def authenticate_if_needed
# Disable this extra authentication in test mode
return true if Rails.env.test?
return true # any hint of basic auth will stop BL staff from accessing site so instead we open all the "private" demo sites
if (is_hidden || is_staging) && !is_api_or_pdf
authenticate_or_request_with_http_basic do |username, password|
username == ENV.fetch("HYKU_DEMO_USER", "bl_demo_user") && password == ENV.fetch("HYKU_DEMO_PASSWORD", "resu_omed_lb")
Expand Down
3 changes: 2 additions & 1 deletion bin/worker
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,5 @@ else
puts 'DATABASE_URL not set, no pool change needed'
end

exec "echo $DATABASE_URL && clamd && bundle exec sidekiq"
#exec "echo $DATABASE_URL && clamd && bundle exec sidekiq"
exec "echo $DATABASE_URL && bundle exec sidekiq"
Loading