Adding variable for signature database checks per day

This commit is contained in:
ajila-fmeyer 2020-02-07 11:38:40 +01:00
parent 81beb69a5f
commit d10c4fd885
4 changed files with 6 additions and 3 deletions

View file

@ -17,7 +17,7 @@ RUN sed -i 's/^#Foreground .*$/Foreground true/g' /etc/clamav/clamd.conf \
&& sed -i 's/^#TCPSocket .*$/TCPSocket 3310/g' /etc/clamav/clamd.conf \
&& sed -i 's/^#Foreground .*$/Foreground true/g' /etc/clamav/freshclam.conf
RUN freshclam --quiet --no-dns --checks=24
RUN freshclam --quiet --no-dns
# Build go package
ADD . /go/src/clamav-rest/
@ -43,5 +43,6 @@ ENV MAX_PARTITIONS=50
ENV MAX_ICONSPE=100
ENV PCRE_MATCHLIMIT=100000
ENV PCRE_RECMATCHLIMIT=2000
ENV SIGNATURE_CHECKS=24
ENTRYPOINT [ "entrypoint.sh" ]

View file

@ -126,6 +126,7 @@ Below is the complete list of available options that can be used to customize yo
| `MAX_ICONSPE` | How many Icons in PE to scan - Default `100` |
| `PCRE_MATCHLIMIT` | Maximum PCRE Match Calls - Default `100000` |
| `PCRE_RECMATCHLIMIT` | Maximum Recursive Match Calls to PCRE - Default `2000` |
| `SIGNATURE_CHECKS` | Check times per day for a new database signature. Must be between 1 and 50. - Default `24` |
## Networking

View file

@ -28,7 +28,7 @@ RUN sed -i 's/^Example$/# Example/g' /etc/clamd.d/scan.conf \
&& sed -i 's/^#TCPSocket .*$/TCPSocket 3310/g' /etc/clamd.d/scan.conf \
&& sed -i 's/^#Foreground .*$/Foreground true/g' /etc/freshclam.conf
RUN freshclam --quiet --no-dns --checks=24
RUN freshclam --quiet --no-dns
# Build go package
ADD . /go/src/clamav-rest/
@ -54,5 +54,6 @@ ENV MAX_PARTITIONS=50
ENV MAX_ICONSPE=100
ENV PCRE_MATCHLIMIT=100000
ENV PCRE_RECMATCHLIMIT=2000
ENV SIGNATURE_CHECKS=24
ENTRYPOINT [ "entrypoint.sh" ]

View file

@ -16,7 +16,7 @@ sed -i 's/^#MaxIconsPE .*$/MaxIconsPE '"$MAX_ICONSPE"'/g' /etc/clamav/clamd.conf
sed -i 's/^#PCREMatchLimit.*$/PCREMatchLimit '"$PCRE_MATCHLIMIT"'/g' /etc/clamav/clamd.conf
sed -i 's/^#PCRERecMatchLimit .*$/PCRERecMatchLimit '"$PCRE_RECMATCHLIMIT"'/g' /etc/clamav/clamd.conf
freshclam -d &
freshclam --daemon --checks=$SIGNATURE_CHECKS &
clamd &
/usr/bin/clamav-rest &