You want to have your own ad-blocking DNS server but you're often going outside or you don't have wifi in your house but you have an unused domain and just signed up for aws free tier? Follow this tutorial to get pihole running on any cloud provider with DNS over TLS and DNS over HTTPS, while restricting port 53 so you have less risk for your server becoming an open resolver. Let's get going!
- Make sure you have port 80, 443, and 853 opened in your firewall settings, and login to your server via ssh.
- Install nginx:
apt install nginx
- Create a file on
/etc/nginx/conf.d/example.conf
with following contents:
server {
server_name example.com;
listen 80;
# only add the line below if you have public ipv6 in your server