mirror of
https://github.com/nextcloud/all-in-one.git
synced 2025-12-19 14:06:50 +00:00
improve ipv6 docs (#2504)
This commit is contained in:
parent
944e09237c
commit
a63ff97f43
3 changed files with 14 additions and 10 deletions
|
|
@ -33,6 +33,8 @@ services:
|
|||
# - NEXTCLOUD_ENABLE_DRI_DEVICE=true # This allows to enable the /dev/dri device in the Nextcloud container which is needed for hardware-transcoding. See https://github.com/nextcloud/all-in-one#how-to-enable-hardware-transcoding-for-nextcloud
|
||||
# - TALK_PORT=3478 # This allows to adjust the port that the talk container is using.
|
||||
# - WATCHTOWER_DOCKER_SOCKET_PATH=/var/run/docker.sock # Needs to be specified if the docker socket on the host is not located in the default '/var/run/docker.sock'. Otherwise mastercontainer updates will fail. For macos it needs to be '/var/run/docker.sock'
|
||||
# networks: # Is needed when you want to create the nextcloud-aio network with ipv6-support using this file, see the network config at the bottom of the file
|
||||
# - nextcloud-aio # Is needed when you want to create the nextcloud-aio network with ipv6-support using this file, see the network config at the bottom of the file
|
||||
|
||||
# # Optional: Caddy reverse proxy. See https://github.com/nextcloud/all-in-one/blob/main/reverse-proxy.md
|
||||
# # You can find further examples here: https://github.com/nextcloud/all-in-one/discussions/588
|
||||
|
|
@ -48,14 +50,15 @@ services:
|
|||
# - ./sites:/srv
|
||||
# network_mode: "host"
|
||||
|
||||
# # Optional: If you need ipv6, follow step 1 and 2 of https://github.com/nextcloud/all-in-one/blob/main/docker-ipv6-support.md first and then uncomment the below config in order to activate ipv6 for the internal nextcloud-aio network
|
||||
# # Optional: If you need ipv6, follow step 1 and 2 of https://github.com/nextcloud/all-in-one/blob/main/docker-ipv6-support.md first and then uncomment the below config in order to activate ipv6 for the internal nextcloud-aio network.
|
||||
# # Please make sure to uncomment also the networking lines of the mastercontainer above in order to actually create the network with docker-compose
|
||||
# # Inspired by https://github.com/mailcow/mailcow-dockerized/blob/master/docker-compose.yml
|
||||
# networks:
|
||||
# nextcloud-aio:
|
||||
# name: nextcloud-aio
|
||||
# name: nextcloud-aio # This line is not allowed to be changed as otherwise the created network will not be used by the other containers of AIO
|
||||
# driver: bridge
|
||||
# enable_ipv6: true
|
||||
# ipam:
|
||||
# driver: default
|
||||
# config:
|
||||
# - subnet: ${IPV6_NETWORK:-fd4d:6169:6c63:6f77::/64}
|
||||
# - subnet: fd12:3456:789a:2::/64 # IPv6 subnet to use
|
||||
|
|
|
|||
|
|
@ -3,12 +3,12 @@
|
|||
Before you can use IPv6 in Docker containers or swarm services, you need to enable IPv6 support in the Docker daemon. Afterward, you can choose to use either IPv4 or IPv6 (or both) with any container, service, or network.
|
||||
|
||||
## Docker on Linux and Docker-rootless
|
||||
1. Edit `/etc/docker/daemon.json` (or `~/.config/docker/daemon.json` in case of docker-rootless), set the `ipv6` key to `true` and the `fixed-cidr-v6` key to your IPv6 subnet. In this example we are setting it to `2001:db8:1::/64`. Additionally set `experimental` to `true` and `ip6tables` to `true` as well.
|
||||
1. Edit `/etc/docker/daemon.json` (or `~/.config/docker/daemon.json` in case of docker-rootless), set the `ipv6` key to `true` and the `fixed-cidr-v6` key to your IPv6 subnet. In this example we are setting it to `fd12:3456:789a:1::/64`. Additionally set `experimental` to `true` and `ip6tables` to `true` as well. If you are using mailcow and enabled IPv6 with the update.sh, you can keep their daemon.json, it will work too.
|
||||
|
||||
```json
|
||||
{
|
||||
"ipv6": true,
|
||||
"fixed-cidr-v6": "2001:db8:1::/64",
|
||||
"fixed-cidr-v6": "fd12:3456:789a:1::/64",
|
||||
"experimental": true,
|
||||
"ip6tables": true
|
||||
}
|
||||
|
|
@ -21,22 +21,22 @@ Before you can use IPv6 in Docker containers or swarm services, you need to enab
|
|||
```console
|
||||
sudo systemctl restart docker
|
||||
```
|
||||
3. Make sure that ipv6 is enabled for the internal `nextcloud-aio` network by running `sudo docker network inspect nextcloud-aio`. On a new instance, this command should return that it did not find a network with this name. Then you can run `sudo docker network create --subnet="2001:db8:2::/64" --driver bridge --ipv6 nextcloud-aio` in order to create the network with ipv6-support. If it finds the network though and its value `EnableIPv6` is set to false, make sure to follow https://github.com/nextcloud/all-in-one/discussions/2045 in order to recreate the network and enable ipv6 for it.
|
||||
3. Make sure that ipv6 is enabled for the internal `nextcloud-aio` network by running `sudo docker network inspect nextcloud-aio`. On a new instance, this command should return that it did not find a network with this name. Then you can run `sudo docker network create --subnet="fd12:3456:789a:2::/64" --driver bridge --ipv6 nextcloud-aio` in order to create the network with ipv6-support. If it finds the network though and its value `EnableIPv6` is set to false, make sure to follow https://github.com/nextcloud/all-in-one/discussions/2045 in order to recreate the network and enable ipv6 for it.
|
||||
|
||||
## Docker Desktop (Windows and macOS)
|
||||
On Windows and macOS which use Docker Desktop, you need to go into the settings, and select `Docker Engine`. There you should see the currently used daemon.json file.
|
||||
|
||||
1. You need to now adjust this json file by setting the `ipv6` key to `true` and the `fixed-cidr-v6` key to your IPv6 subnet. In this example we are setting it to `2001:db8:1::/64`. Additionally set `experimental` to `true` and `ip6tables` to `true` as well.
|
||||
1. You need to now adjust this json file by setting the `ipv6` key to `true` and the `fixed-cidr-v6` key to your IPv6 subnet. In this example we are setting it to `fd12:3456:789a:1::/64`. Additionally set `experimental` to `true` and `ip6tables` to `true` as well.
|
||||
|
||||
```
|
||||
"ipv6": true,
|
||||
"fixed-cidr-v6": "2001:db8:1::/64",
|
||||
"fixed-cidr-v6": "fd12:3456:789a:1::/64",
|
||||
"experimental": true,
|
||||
"ip6tables": true
|
||||
```
|
||||
|
||||
2. Add these values to the json and make sure to keep the other currently values and that you don't see `Unexpected token in JSON at position ...` before attempting to restart by clicking on `Apply & restart`.
|
||||
3. Make sure that ipv6 is enabled for the internal `nextcloud-aio` network by running `docker network inspect nextcloud-aio`. On a new instance, this command should return that it did not find a network with this name. Then you can run `docker network create --subnet="2001:db8:2::/64" --driver bridge --ipv6 nextcloud-aio` in order to create the network with ipv6-support. If it finds the network though and its value `EnableIPv6` is set to false, make sure to follow https://github.com/nextcloud/all-in-one/discussions/2045 in order to recreate the network and enable ipv6 for it.
|
||||
3. Make sure that ipv6 is enabled for the internal `nextcloud-aio` network by running `docker network inspect nextcloud-aio`. On a new instance, this command should return that it did not find a network with this name. Then you can run `docker network create --subnet="fd12:3456:789a:2::/64" --driver bridge --ipv6 nextcloud-aio` in order to create the network with ipv6-support. If it finds the network though and its value `EnableIPv6` is set to false, make sure to follow https://github.com/nextcloud/all-in-one/discussions/2045 in order to recreate the network and enable ipv6 for it.
|
||||
|
||||
---
|
||||
|
||||
|
|
|
|||
|
|
@ -85,6 +85,7 @@ sed -i 's|NEXTCLOUD_ADDITIONAL_APKS=|NEXTCLOUD_ADDITIONAL_APKS=imagemagick
|
|||
sed -i 's|NEXTCLOUD_ADDITIONAL_PHP_EXTENSIONS=|NEXTCLOUD_ADDITIONAL_PHP_EXTENSIONS=imagick # This allows to add additional php extensions to the Nextcloud container permanently. Default is imagick but can be overwritten by modifying this value.|' sample.conf
|
||||
sed -i 's|INSTALL_LATEST_MAJOR=|INSTALL_LATEST_MAJOR=no # Setting this to yes will install the latest Major Nextcloud version upon the first installation|' sample.conf
|
||||
sed -i 's|=$|= # TODO! This needs to be a unique and good password!|' sample.conf
|
||||
echo 'IPV6_NETWORK=fd12:3456:789a:2::/64 # IPv6 subnet to use' >> sample.conf
|
||||
|
||||
cat sample.conf
|
||||
|
||||
|
|
@ -137,7 +138,7 @@ networks:
|
|||
ipam:
|
||||
driver: default
|
||||
config:
|
||||
- subnet: \${IPV6_NETWORK:-fd4d:6169:6c63:6f77::/64}
|
||||
- subnet: \${IPV6_NETWORK}
|
||||
NETWORK
|
||||
|
||||
cat containers.yml > latest.yml
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue