Back

Health and Antivirus

  • 0
  • Self Hosted
  • Tools
Samuel Kings
4 Aug, 2023, 04:11

So, I was messing with the Heath API a few minutes ago and everything workes fine except that the Antivirus service is returning "disabled". Is there something I need to do?

TL;DR
Summary: The user is having an issue with the Antivirus service being disabled in their Health API. They are seeking a solution. Solution: The user is instructed to enable the antivirus service in the `.env` file by adding `_APP_STORAGE_ANTIVIRUS=enabled` and restarting the docker compose. If this doesn't work, the user is advised to install clamav on their machine. It is also noted that there may be an issue with the version of clamav being used.
Binyamin
4 Aug, 2023, 04:12

Self-hosted?

Samuel Kings
4 Aug, 2023, 04:14

Errr. Using Digital Ocean

Binyamin
4 Aug, 2023, 04:14

Check this https://book.appread.io/security#antivirus You can see that the calmav service is disabled by default and you'll need to enable it.

Samuel Kings
4 Aug, 2023, 04:15

Alright. Thanks. trying it right away

Samuel Kings
4 Aug, 2023, 04:50

Hi @Binyamin, I couldn't find this block in my docker-compose.yml file clamav: image: appwrite/clamav:1.2.0 container_name: appwrite-clamav restart: unless-stopped networks: - appwrite volumes: - appwrite-uploads:/storage/uploads

Binyamin
4 Aug, 2023, 04:50
Binyamin
4 Aug, 2023, 04:51

Copy it from there, remove the hashes and try to restart you docker compose

Samuel Kings
4 Aug, 2023, 04:53

Nvm. I've seen it now. Scanned it twice before 🤦🏽

Samuel Kings
4 Aug, 2023, 05:06

I've done that but I get the same result though. I programmed it to output failed if the status is not "online"

Drake
4 Aug, 2023, 06:00

there might be a problem with this version of clamav

Binyamin
4 Aug, 2023, 13:45

Opps, I forgot this part Enable the antivirus inside the .env file

TypeScript
_APP_STORAGE_ANTIVIRUS=enabled

Then restart the docker compose.

But anyway its seems like this version won't work anymore as Steven mentioned, this due the fact clamavis blocking the current binary version of getting update as it is not up-to-date

You can give it a try by enabling the antivirus and check the clamav logs

TypeScript
docker logs appwrite-clamav

Also, notice that the initializing process of the calmav can take few minutes, after that you can check the health endpoint.

If this won't work for you, you can try to install clamav on your machine in general as Docker volume file are store in plain sight - just inside a nested folder.

Samuel Kings
4 Aug, 2023, 14:01

Alright. Thanks.

Samuel Kings
4 Aug, 2023, 16:06

I already did this _APP_STORAGE_ANTIVIRUS=enabled But I also get this error when I run docker logs appwrite-clamav

Binyamin
4 Aug, 2023, 16:07

Yes, this is due the fact the software is 0.102 instead of the latest one.

Samuel Kings
4 Aug, 2023, 16:07

Seems I'm gonna neglect this for now btw, can you explain this part:

If this won't work for you, you can try to install clamav on your machine in general as Docker volume file are store in plain sight - just inside a nested folder.

Samuel Kings
4 Aug, 2023, 16:08

Does this mean it's not really fixable? Is there any sure workaround?

Binyamin
4 Aug, 2023, 16:10

For example, If you run

TypeScript
docker volume inspect appwrite_appwrite-builds

You'll get something like this

TypeScript
[
 ....
 "Mountpoint": "/var/lib/docker/volumes/appwrite_appwrite-builds/_data",
 ....
]

You can cd into that mounting point

TypeScript
cd /var/lib/docker/volumes/appwrite_appwrite-builds/_data

To see all your files

This means even if you're using dokcer volumes the files are put in plain sight from the server aspect

Binyamin
4 Aug, 2023, 16:10

Is that makes sense?

Samuel Kings
4 Aug, 2023, 16:12

I think I understand. Alright, thanks. I'll be back.

Drake
4 Aug, 2023, 16:12

.

joeyouss
8 Aug, 2023, 10:19

Hi @Samuel Kings , is this fixed for you now?

Samuel Kings
8 Aug, 2023, 10:47

nope

Samuel Kings
8 Aug, 2023, 10:48

Twas taking too much of my time so put it on pending for now

joeyouss
8 Aug, 2023, 10:49

let us know if you need any help!

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more