Git Product home page Git Product logo

zerotier-systemd-manager's Introduction

Get ZeroTier playing nice with systemd-networkd and resolvectl

This is a small tool to enable the systemd-networkd service as well as resolvectl to enable per-interface DNS settings. We take this directly from zerotier-one (on your machine) metadata. This service does not reach out to the internet on its own.

The result is per-interface DNS settings, which is especially nice when you are using zeronsd with multiple networks.

Usage

Check out our releases for debian and redhat packages that automate this on a variety of platforms.

Installing From Source

Compile it with golang 1.16 or later:

# be outside of gopath when you do this
go get github.com/zerotier/zerotier-systemd-manager

Ensure systemd-networkd is properly configured and resolvectl works as intended.

Finally, run the tool as root: zerotier-systemd-manager. If you have interfaces with DNS assignments in ZeroTier, it will populate files in /etc/systemd/network. No DNS assignment, no file. Unless you have passed -auto-restart=false, it will restart systemd-networkd for you if things have changed.

If you have a DNS-over-TLS configuration provided by zeronsd (v0.4.0 or later), you can enable using it by providing -dns-over-tls=true in the supervisor (a systemd timer in the default case). You will have to hand-edit this in for now.

If you want to enable multicast DNS / bonjour / mDNS you can enable it by providing -multicast-dns.

Finally, if you have left a DNS-controlled network it will try to remove the old files if -reconcile=true is set (the default). This way you can stuff it in cron and not think about it too much.

Enjoy!

Author

Erik Hollensbe [email protected]

License

BSD 3-Clause

Releasing

This repo uses goreleaser.

zerotier-systemd-manager's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.