docker-clamav
docker-clamav copied to clipboard
Custom Dockerfile From ClamAV Base Image with Server
I'm attempting to create a Dockerfile from the base ClamAV image so that I can run a simple Nodejs server on the same image (and talk directly to clamdscan). For example
FROM clamav/clamav:latest
RUN apk add --update nodejs npm
RUN node --version
RUN npm --version
WORKDIR /code
COPY ./ ./
CMD ["yarn","start"]
After I build the image (naming it clamav-test), I run it locally with:
docker run -it --rm --env 'CLAMAV_NO_FRESHCLAMD=true' -p 3000:3000 clamav-test:latest
I expose 3000 as my Nodejs server is running on port 3000.
When the container runs, it starts up the clamd service, but will not run my yarn start cmd.
Is there a way to add an cli executable to the clamav image for initialization?
Hey @quidmonkey !
Thank you for your question.
Some questions of me:
- How does the build log look like?
- Did you try an interactive start?
You should not use port 3000, try another port instead.