Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setup Netmaker on ipv6 only machine #290

Merged
merged 2 commits into from
Mar 28, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 55 additions & 0 deletions server-installation.rst
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. mention about the install script should be run with ipv4 enabled initially for the installation process to succeed, later user can disable ipv4 and make the following changes for ipv6 only compatibility

  2. Were there any changes required for Caddy for ipv6? the SSL certs worked without any issue?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good points @abhishek9686 . I added two sections for the install/DNS AAAA record, please help review again. Thanks.
image

Original file line number Diff line number Diff line change
Expand Up @@ -896,3 +896,58 @@ Replace YOUR_IP_CIDR with the whitelist IP range (can be multiple ranges).
After changes are made for your reverse proxy, ``docker-compose down && docker-compose up -d`` and you should be all set. You can now keep your dashboard secure and your API more available without having to change netmaker-ui ports.


Setup Netmaker on IPv6 only machine
=====================================

This is not a guide how to add an overlay network(with IPv6) in Netmaker, it can be found in `Setup <https://docs.netmaker.io/getting-started.html#setup>`_ page.
This is to setup Netmaker working on an IPv6 only machine.

By default, Netmaker works on IPv4. Because Docker works on IPv4 by default.

Enable IPv6 support for Docker
------------------------------

1. Add/Edit the configuration file `/etc/docker/daemon.json`:

.. code-block:: json

{
"experimental": true,
"ip6tables": true
}

2. Restart the Docker daemon for your changes to take effect.

.. code-block::

sudo systemctl restart docker

3. Create a new IPv6 network, for example,

.. code-block::

docker network create --ipv6 --subnet 2001:0DB8::/112 ip6net

where "ip6net" is the network name, "2001:0DB8::/112" is the network range.


Enable IPv6 support for Netmaker
---------------------------------

1. Edit `docker-compose.yml` file and add the following lines at the bottom.

.. code-block:: yaml

networks:
ip6net:
external: true

2. The same in `docker-compose.yml` file, add `networks` field for every service.

.. code-block:: yaml

networks:
- ip6net

3. Run commands `"docker-compose down"` and `"docker-compose up -d"` to restart Netmaker server