diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index 68ee546..0000000 --- a/Dockerfile +++ /dev/null @@ -1,6 +0,0 @@ -FROM debian:sid-slim -RUN apt update && apt install -y cron clamav && apt purge -RUN freshclam -COPY ./clamav /etc/cron.d/clamav -RUN chmod 644 /etc/cron.d/clamav -ENTRYPOINT ["/usr/sbin/cron", "-f"] diff --git a/README.md b/README.md index 779a65e..8614375 100644 --- a/README.md +++ b/README.md @@ -4,11 +4,11 @@ ## Config - edit compose.yml file volumes + edit compose.yml file volumes under /scandir container folder ## Build - docker compose build + ./install.sh ## Start diff --git a/clamav b/clamav deleted file mode 100644 index 324cbc9..0000000 --- a/clamav +++ /dev/null @@ -1,2 +0,0 @@ -PATH=/usr/sbin:/usr/bin:/sbin:/bin -5 4 * * * root freshclam && nice -n10 clamscan -rio --move /data/quarantine /data/queue >> /var/log/result.log 2>&1 diff --git a/compose.yml b/compose.yml index c42c0bd..e6d53e0 100644 --- a/compose.yml +++ b/compose.yml @@ -1,14 +1,13 @@ services: malware-scan: - build: . + build: ./clamav image: malware-scan hostname: malware-scan container_name: malware-scan restart: always volumes: - - /var/lib/docker:/data/queue/docker - - ./quarantine:/data/quarantine - - ./result.log:/var/log/result.log + - /home:/scandir + - ./data:/var/lib/clamav networks: mynet: diff --git a/install.sh b/install.sh new file mode 100755 index 0000000..f7334a6 --- /dev/null +++ b/install.sh @@ -0,0 +1,5 @@ +#!/bin/bash +git clone --depth 1 https://github.com/Cisco-Talos/clamav-docker +git clone --depth 1 https://github.com/Cisco-Talos/clamav +cp -r ./clamav-docker/clamav/1.4/debian/* clamav/ +docker compose build --no-cache diff --git a/result.log b/result.log deleted file mode 100644 index e69de29..0000000