Last active
January 4, 2023 11:41
-
-
Save mtrimarchi/67e4435651af6e97c9bbbe92957642ef to your computer and use it in GitHub Desktop.
Cloudflared with systemd
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /etc/default/cloudflared | |
CLOUDFLARED_OPTS=--port 5053 --upstream https://1.1.1.1/dns-query --upstream https://dns.google.com/resolve --upstream https://1.0.0.1/dns-query --upstream https://2606:4700:4700::1111/dns-query --upstream https://2606:4700:4700::1001/dns-query |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /lib/systemd/system/cloudflared.service | |
[Unit] | |
Description=cloudflared DNS over HTTPS proxy | |
After=syslog.target network-online.target | |
[Service] | |
Type=simple | |
User=cloudflared | |
EnvironmentFile=/etc/default/cloudflared | |
ExecStart=/usr/local/bin/cloudflared proxy-dns $CLOUDFLARED_OPTS | |
Restart=on-failure | |
RestartSec=10 | |
KillMode=process | |
[Install] | |
WantedBy=multi-user.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment