dnscrypt-proxy/dnscrypt-proxy.service

40 lines
1.5 KiB
Desktop File

# This file is part of dnscrypt-proxy
# Author: Marguerite Su <i@marguerite.su> with some AUR references.
# Version: 1.7.0
# Description: dnscrypt is a tool that encrypts your DNS queries in order to
# protect against man-in-the-middle attacks and DNS hijacking
# (commonly seen in China). It uses OpenDNS resolvers by default.
# It is BSD-licensed.
# In openSUSE it's licensed under SuSE-Permissive (non-free ware).
# For details, refer to its documentation.
[Unit]
Description=Secure connection between your computer and a DNS resolver
Documentation=man:dnscrypt-proxy(8)
Requires=dnscrypt-proxy.socket
After=network.target ntp.service
# NTP always has local servers, and there's nothing to encrypt for time.
# and ntp.service isn't native systemd service, if we start before it,
# it will take a long time to sync. just save 20000+ms on boot.
Before=nss-lookup.target
[Service]
Type=forking
NonBlocking=true
PIDFile=/var/run/dnscrypt-proxy.pid
# Execute a wrapper that calls the dnscrypt-proxy with config from
# /etc/sysconfig/dnscrypt and substitutes defaults that cannot be passed
# to ExecStart in combination with EnvironmentFile
ExecStart=/usr/sbin/dnscrypt \
--daemonize \
--pidfile=/var/run/dnscrypt-proxy.pid \
--user=dnscrypt \
--resolvers-list=/usr/share/dnscrypt-proxy/dnscrypt-resolvers.csv \
--logfile=/var/log/dnscrypt-proxy.log
# Automatically Restart
Restart=on-abort
[Install]
Also=dnscrypt-proxy.socket
WantedBy=multi-user.target
Alias=dnscrypt.service