From 9a04c5abf4f2b7f961975ee61aede4ec9e99b565 Mon Sep 17 00:00:00 2001 From: kmpm Date: Sun, 20 Jan 2019 12:11:31 +0100 Subject: services in own folder * spitting services into multiple files in it's own folder * making image links absolute * some linting --- docs/services/dynamic-dns.rst | 153 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 153 insertions(+) create mode 100644 docs/services/dynamic-dns.rst (limited to 'docs/services/dynamic-dns.rst') diff --git a/docs/services/dynamic-dns.rst b/docs/services/dynamic-dns.rst new file mode 100644 index 00000000..dcb9c155 --- /dev/null +++ b/docs/services/dynamic-dns.rst @@ -0,0 +1,153 @@ +Dynamic DNS +----------- + +VyOS is able to update a remote DNS record when an interface gets a new IP +address. In order to do so, VyOS includes ddclient_, a perl script written for +this exact purpose. + +ddclient_ uses two methods to update a DNS record. The first one will send +updates directly to the DNS daemon, in compliance with RFC2136_. The second +one involves a third party service, like DynDNS.com or any other similar +website. This method uses HTTP requests to transmit the new IP address. You +can configure both in VyOS. + +VyOS CLI and RFC2136 +^^^^^^^^^^^^^^^^^^^^ + +First, create an RFC2136_ config node : + +.. code-block:: sh + + edit service dns dynamic interface eth0 rfc2136 + +Present your RNDC key to ddclient : + +.. code-block:: sh + + set key /config/dyndns/mydnsserver.rndc.key + +Set the DNS server IP/FQDN : + +.. code-block:: sh + + set server dns.mydomain.com + +Set the NS zone to be updated : + +.. code-block:: sh + + set zone mydomain.com + +Set the records to be updated : + +.. code-block:: sh + + set record dyn + set record dyn2 + +You can optionally set a TTL (note : default value is 600 seconds) : + +.. code-block:: sh + + set ttl 600 + +This will generate the following ddclient config blocks: + +.. code-block:: sh + + server=dns.mydomain.com + protocol=nsupdate + password=/config/dyndns/mydnsserver.rndc.key + ttl=600 + zone=mydomain.com + dyn + server=dns.mydomain.com + protocol=nsupdate + password=/config/dyndns/mydnsserver.rndc.key + ttl=600 + zone=mydomain.com + dyn2 + +You can also keep a different dns zone updated. Just create a new config node: + +.. code-block:: sh + + edit service dns dynamic interface eth0 rfc2136 + +VyOS CLI and HTTP dynamic DNS services +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +VyOS is also able to use any service relying on protocols supported +by ddclient. + +To use such a service, you must define a login, a password, one or multiple +hostnames, a protocol and a server. + +.. code-block:: sh + + edit service dns dynamic interface eth0 service HeNet + set login my-login # set password my-password + set host-name my-tunnel-id + set protocol dyndns2 + set server ipv4.tunnelbroker.net + +VyOS is also shipped with a list of known services. You don't need to set the +protocol and server value as VyOS has defaults provided for those. These are +the services VyOS knows about: + +* afraid +* changeip +* dnspark +* dslreports +* dyndns +* easydns +* namecheap +* noip +* zoneedit + +To use DynDNS for example: + +.. code-block:: sh + + edit service dns dynamic interface eth0 service dyndns + set login my-login + set password my-password + set host-name my-dyndns-hostname + +It's possible to use multiple services : + +.. code-block:: sh + + edit service dns dynamic interface eth0 service dyndns + set login my-login + set password my-password + set host-name my-dyndns-hostname + edit service dns dynamic interface eth0 service HeNet + set login my-login + set password my-password + set host-name my-tunnel-id + set protocol dyndns2 + set server ipv4.tunnelbroker.net + +ddclient behind NAT +^^^^^^^^^^^^^^^^^^^ + +By default, ddclient will update a dynamic dns record using the IP address +directly attached to the interface. If your VyOS instance is behind NAT, your +record will be updated to point to your internal IP. + +ddclient_ has another way to determine the WAN IP address. This is controlled +by these two options: + +.. code-block:: sh + + set service dns dynamic interface eth0 use-web url + set service dns dynamic interface eth0 use-web skip + +ddclient_ will load the webpage at `[url]` and will try to extract an IP +address for the response. ddclient_ will skip any address located before the +string set in `[skip]`. + + +.. _ddclient: http://sourceforge.net/p/ddclient/wiki/Home/ +.. _RFC2136: https://www.ietf.org/rfc/rfc2136.txt -- cgit v1.2.3 From 1ac4afa392eb4c077507cf3866ebc1b8b3cb1793 Mon Sep 17 00:00:00 2001 From: kmpm Date: Sun, 20 Jan 2019 16:13:07 +0100 Subject: fixed erroneous targets --- docs/services/dynamic-dns.rst | 3 +-- docs/services/index.rst | 2 ++ docs/services/lldp.rst | 6 +----- docs/services/references.rst | 13 +++++++++++++ docs/services/snmp.rst | 5 +---- docs/services/ssh.rst | 2 +- docs/services/tftp.rst | 2 -- docs/services/webproxy.rst | 4 +--- 8 files changed, 20 insertions(+), 17 deletions(-) create mode 100644 docs/services/references.rst (limited to 'docs/services/dynamic-dns.rst') diff --git a/docs/services/dynamic-dns.rst b/docs/services/dynamic-dns.rst index dcb9c155..67de6471 100644 --- a/docs/services/dynamic-dns.rst +++ b/docs/services/dynamic-dns.rst @@ -149,5 +149,4 @@ address for the response. ddclient_ will skip any address located before the string set in `[skip]`. -.. _ddclient: http://sourceforge.net/p/ddclient/wiki/Home/ -.. _RFC2136: https://www.ietf.org/rfc/rfc2136.txt +.. include:: references.rst diff --git a/docs/services/index.rst b/docs/services/index.rst index a138c961..80405ef7 100644 --- a/docs/services/index.rst +++ b/docs/services/index.rst @@ -1,5 +1,7 @@ .. _services: +.. include:: references.rst + Services ======== diff --git a/docs/services/lldp.rst b/docs/services/lldp.rst index 88df9b20..6a3bee7b 100644 --- a/docs/services/lldp.rst +++ b/docs/services/lldp.rst @@ -94,8 +94,4 @@ Troubleshooting Use operationnal command ``show log lldp`` to display logs. - -.. _`Cisco Discovery Protocol`: https://en.wikipedia.org/wiki/Cisco_Discovery_Protocol -.. _`Foundry Discovery Protocol`: https://en.wikipedia.org/wiki/Foundry_Discovery_Protocol -.. _MIB: https://en.wikipedia.org/wiki/Management_information_base -.. _SNMP: https://en.wikipedia.org/wiki/Simple_Network_Management_Protocol +.. include:: references.rst diff --git a/docs/services/references.rst b/docs/services/references.rst new file mode 100644 index 00000000..6e6e9595 --- /dev/null +++ b/docs/services/references.rst @@ -0,0 +1,13 @@ +.. _`Cisco Discovery Protocol`: https://en.wikipedia.org/wiki/Cisco_Discovery_Protocol +.. _ddclient: http://sourceforge.net/p/ddclient/wiki/Home/ +.. _`Foundry Discovery Protocol`: https://en.wikipedia.org/wiki/Foundry_Discovery_Protocol +.. _MIB: https://en.wikipedia.org/wiki/Management_information_base +.. _RFC2136: https://www.ietf.org/rfc/rfc2136.txt +.. _SNMP: https://en.wikipedia.org/wiki/Simple_Network_Management_Protocol +.. _SNMPv2: https://en.wikipedia.org/wiki/Simple_Network_Management_Protocol#Version_2 +.. _SNMPv3: https://en.wikipedia.org/wiki/Simple_Network_Management_Protocol#Version_3 +.. _SSH: https://en.wikipedia.org/wiki/Secure_Shell +.. _Squid3: http://www.squid-cache.org/ +.. _Squidguard: http://www.squidguard.org/ +.. _TFTP: https://en.wikipedia.org/wiki/Trivial_File_Transfer_Protocol + diff --git a/docs/services/snmp.rst b/docs/services/snmp.rst index ac79f700..e11e3969 100644 --- a/docs/services/snmp.rst +++ b/docs/services/snmp.rst @@ -177,7 +177,4 @@ After commit the resulting configuration will look like: } -.. _SNMP: https://en.wikipedia.org/wiki/Simple_Network_Management_Protocol -.. _SNMPv2: https://en.wikipedia.org/wiki/Simple_Network_Management_Protocol#Version_2 -.. _SNMPv3: https://en.wikipedia.org/wiki/Simple_Network_Management_Protocol#Version_3 -.. _MIB: https://en.wikipedia.org/wiki/Management_information_base +.. include:: references.rst diff --git a/docs/services/ssh.rst b/docs/services/ssh.rst index a8da9154..4d96f8de 100644 --- a/docs/services/ssh.rst +++ b/docs/services/ssh.rst @@ -147,4 +147,4 @@ as the ``vyos`` user using their own keys. set system login user vyos authentication public-keys 'xrobau' type ssh-rsa -.. _SSH: https://en.wikipedia.org/wiki/Secure_Shell + diff --git a/docs/services/tftp.rst b/docs/services/tftp.rst index 524c8e5e..96b33a65 100644 --- a/docs/services/tftp.rst +++ b/docs/services/tftp.rst @@ -40,5 +40,3 @@ The resulting configuration will look like: listen-address 10.10.1.1 } - -.. _TFTP: https://en.wikipedia.org/wiki/Trivial_File_Transfer_Protocol diff --git a/docs/services/webproxy.rst b/docs/services/webproxy.rst index b739e479..d1c2ca2e 100644 --- a/docs/services/webproxy.rst +++ b/docs/services/webproxy.rst @@ -118,6 +118,4 @@ So sometimes it is useful to bypass a transparent proxy: (This can be useful when a called service has many and/or often changing destination addresses - e.g. Netflix.) - -.. _Squid3: http://www.squid-cache.org/ -.. _Squidguard: http://www.squidguard.org/ +.. include:: references.rst -- cgit v1.2.3