How to Install AdGuard on Your Synology NAS

How to Install AdGuard on Your Synology NAS

AdGuard is DNS ad blocking similar to Pi-Hole. It’s a privacy protection software which comprises open-source and shareware products that protect Microsoft Windows, Linux, OS X, Android and iOS users from unwanted ads, pop-ups, banners, as well as from tracking, obscene content, malware and phishing. Over 5 million people are reported to be using the software in 2018 and 7 million in 2019 with very fast growth. AdGuard is not only an ad blocker, but a whole ad blocking and privacy protection suite, a must-have product if you have a Synology NAS device.

AdGuard Home intercepts and filters DNS requests. It works as a DNS server and prevents all the devices in a home network from connecting to the servers that track user browsing. In this step by step guide I will teach you how to install AdGuard on your Synology NAS device using Docker.

  • STEP 1

Please Support My work by Making a Donation.

  • STEP 2

Install Docker via Synology “Package Center”.

install synology docker dsm

  • STEP 3

Open Docker Package. From the Docker Console, go to Registry and search adguard. Look for adguard/adguardhome and select it, then click Download. You will be prompted to Choose Tag, select latest. Follow the instructions in the image below.

1 AdGuard Synology Docker

  • STEP 4

After you click “Select”, the download process of the AdGuard docker container will start. You can click on Image on the Docker Console to see the download progress. The current container is about 47 MB. Follow the instructions in the image below.

2 AdGuard Synology Docker

  • STEP 5

Go to File Station and open the docker folder. Inside the docker folder, create a new folder and name it “adguard“. Follow the instructions in the image below.

3 AdGuard Synology Docker

  • STEP 6

Now create two new folders inside the adguard folder that you created at STEP 5: name one “config” and the other “data“. Follow the instructions in the image below.

4 AdGuard Synology Docker

  • STEP 7

Now go back to the Docker Package. After the download is completed from the Docker Console, go to Image, then select the adguard/adguardhome:latest container. Click Launch. Check “Execute container using high privilege”, then click Advanced Settings. Follow the instructions in the image below.

5 AdGuard Synology Docker

  • STEP 8

Select Enable auto-restart and Create shortcut on desktop. Follow the instructions in the image below.

6 AdGuard Synology Docker

  • STEP 9

Next tab – “Volume“. Select Add Folder. Follow the instructions in the image below.

7 AdGuard Synology Docker

  • STEP 10

Choose the config folder, then click Select. Follow the instructions in the image below.

8 AdGuard Synology Docker

  • STEP 11

After you click Select, type /opt/adguardhome/conf inside Mount path. Follow the instructions in the image below.

adguard step 11

  • STEP 12

Click Add Folder again. Choose data folder, then click Select. Follow the instructions in the image below.

10 AdGuard Synology Docker

  • STEP 13

After you click Select, type /opt/adguardhome/work/data inside Mount path. Follow the instructions in the image below.

  • STEP 14

Next tab – “Network“. Check “Use the same network as Docker Host”. Follow the instructions in the image below.

12 AdGuard Synology Docker

  • STEP 15

Next tab – “Port Settings“ move forward without doing anything (no action needed).
Next tab – “Links“ move forward without doing anything (no action needed).
Next tab – “Environment“. Click the + to add the variable and Value.
On the variable area type: TZ and on the Value Area add: Europe/Bucharest (Select your current Time Zone from this list). After that, click Apply. Follow the instructions in the image below.

13 AdGuard Synology Docker

  • STEP 16

After clicking “Apply“, the screen below will open. Click “Next“. Follow the instructions in the image below.

14 AdGuard Synology Docker

  • STEP 17

After clicking “Next“, the screen below will open. Select “Run this container after the wizard is finished” then click “Apply“. Follow the instructions in the image below.

15 AdGuard Synology Docker

  • STEP 18

Go back to STEP 1 or you will deal with karma 🙂. Do you remember that at STEP 8 you selected the option Create shortcut on desktop? If you did everything correctly, you will find the adguard shortcut on your DSM desktop. Open it, then click Log. Follow the instructions in the image below.

16 AdGuard Synology Docker

  • STEP 19

Copy your IP link from the log. It’s your NAS IP ending with :3000 – Follow the instructions in the image below.

17 AdGuard Synology Docker

  • STEP 20

Now open your browser and type in http://Synology-ip-address:3000/ and log into AdGuard. Install and Set it up according to your preference. Enjoy!

18 AdGuard Synology Docker

AdGuard setup Synology Docker

Note: I installed the AdGuard container on my Synology NAS DS718+
Note
: On STEP 7 you can change the container name according to your preference.
Note: Admin Web Interface Error message: Listen tcp 0.0.0.0:80 bind: address already in use. This means that something on your system probably a web server like Apache already listening on port 80. You can solve it by changing port from 80 to 8080. Follow the instructions in the image below.

AdGuard Error Docker port 80 already in use Synology

Note: DNS Server Error message: listen udp 0.0.0.0:53: bind: address already in use.

port 53 DNS Adguard already in use

In this Scenario something else is listening to the local DNS port 53 or AdGuard Home doesn’t have privileges. You have Followed STEP 7 ? If yes and doesn’t work, disable DHCP on your Synology NAS Control Panel / DHCP Server then select “Disable DHCP Server“. Now try again to open AdGuard Home. If this work, don’t miss to go back on STEP 1.

Note: Find out how to update AdGuard container with the latest image.
Note: I recommend you use Reverse Proxy to allow AdGuard to work over an HTTPS connection.
Note: Can I run Docker on my Synology NAS? See the supported models.

This post was updated on Friday / August 21st, 2020 at 1:59 AM