Skip to content

Commit d22fbbf

Browse files
authored
DockerSolver: Configuration for DPS Network (#661)
1 parent 0bb60c3 commit d22fbbf

File tree

17 files changed

+1279
-192
lines changed

17 files changed

+1279
-192
lines changed

RELEASE-NOTES.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,21 @@
1+
## 5.2.0
2+
Docker Solver
3+
* Fixing DPS Docker Network IP Range
4+
* Created option to customize the docker network
5+
6+
Breaking Changes
7+
* Changed default DPS Network IP settings as the actual are not being accepted by docker
8+
9+
New Settings
10+
```yaml
11+
---
12+
- subNet: 172.20.0.0/16
13+
ipRange: 172.20.5.0/24
14+
gateway: 172.20.5.1
15+
- subNet: fc00:5c6f:db50::/64
16+
gateway: fc00:5c6f:db50::1
17+
```
18+
119
## 5.1.3
220
* Changed resolv.conf handling format to make it compatible with alpine linux see [#627][5_1_0_1][1].
321
* Refactoring Linux amd64 static build to work on Github Actions

docs/content/3-configuration/_index.en.md

Lines changed: 63 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -4,30 +4,30 @@ weight: 3
44
pre: "<b>3. </b>"
55
---
66

7-
Current Version: `3`. See [how to set the configurations][5].
7+
Current Version: `3`. See [how to set the configurations][5].
88

99
### Server
1010

11-
| Name | Description | Default Value |
12-
|------|-------------|---------------|
13-
| `server.protocol` | Protocol to start the DNS server. | `UDP_TCP` |
11+
| Name | Description | Default Value |
12+
|-------------------|-----------------------------------|---------------|
13+
| `server.protocol` | Protocol to start the DNS server. | `UDP_TCP` |
1414

1515
---
1616

1717
### DNS Server
1818

19-
| Name | Description | Default Value |
20-
|------|-------------|---------------|
21-
| `server.dns.port` | Port where the DNS server listens. | `53` |
22-
| `server.dns.noEntriesResponseCode` | Response code returned when no entries are resolved by any solver. | `3` |
19+
| Name | Description | Default Value |
20+
|------------------------------------|--------------------------------------------------------------------|---------------|
21+
| `server.dns.port` | Port where the DNS server listens. | `53` |
22+
| `server.dns.noEntriesResponseCode` | Response code returned when no entries are resolved by any solver. | `3` |
2323

2424
---
2525

2626
### WEB Server
2727

28-
| Name | Description | Default Value |
29-
|------|-------------|---------------|
30-
| `server.web.port` | Web GUI port. | `5380` |
28+
| Name | Description | Default Value |
29+
|-------------------|---------------|---------------|
30+
| `server.web.port` | Web GUI port. | `5380` |
3131

3232
---
3333

@@ -39,72 +39,87 @@ Common DNS resolution mechanisms used by DPS. Solvers are evaluated according to
3939

4040
### Remote Solver
4141

42-
| Name | Description | Default Value |
43-
|------|-------------|---------------|
44-
| `solver.remote.active` | Enables or disables querying remote DNS servers. | `true` |
45-
| `solver.remote.dnsServers` | Remote DNS servers to be queried when resolution cannot be done locally or via Docker. | `[8.8.8.8]` |
42+
| Name | Description | Default Value |
43+
|----------------------------|----------------------------------------------------------------------------------------|---------------|
44+
| `solver.remote.active` | Enables or disables querying remote DNS servers. | `true` |
45+
| `solver.remote.dnsServers` | Remote DNS servers to be queried when resolution cannot be done locally or via Docker. | `[8.8.8.8]` |
4646

4747
---
4848

4949
### Docker Solver
5050

51-
| Name | Description | Default Value |
52-
|------|-------------|---------------|
53-
| `solver.docker.registerContainerNames` | Whether container or service names should be registered as DNS hostnames. | `false` |
54-
| `solver.docker.domain` | Domain suffix used when registering Docker containers and services. | `docker` |
55-
| `solver.docker.hostMachineFallback` | Whether the host machine IP should be returned when a container is found but has no IP. | `true` |
56-
| `solver.docker.dockerDaemonUri` | Docker daemon URI used to connect to Docker. | OS dependent |
57-
| `solver.docker.dpsNetwork.autoCreate` | Whether DPS should automatically create a Docker bridge network. | `false` |
58-
| `solver.docker.dpsNetwork.autoConnect` | Whether all containers should be auto-connected to the DPS network. | `false` |
51+
| Name | Description | Default Value |
52+
|----------------------------------------------|-----------------------------------------------------------------------------------------|-----------------|
53+
| `solver.docker.registerContainerNames` | Whether container or service names should be registered as DNS hostnames. | `false` |
54+
| `solver.docker.domain` | Domain suffix used when registering Docker containers and services. | `docker` |
55+
| `solver.docker.hostMachineFallback` | Whether the host machine IP should be returned when a container is found but has no IP. | `true` |
56+
| `solver.docker.dockerDaemonUri` | Docker daemon URI used to connect to Docker. | OS dependent |
57+
| `solver.docker.dpsNetwork.autoCreate` | Whether DPS should automatically create a Docker bridge network. | `false` |
58+
| `solver.docker.dpsNetwork.autoConnect` | Whether all containers should be auto-connected to the DPS network. | `false` |
59+
| `solver.docker.dpsNetwork.configs` | Docker network IP configuration | |
60+
| `solver.docker.dpsNetwork.configs[].subNet` | Subnet | `172.20.0.0/16` |
61+
| `solver.docker.dpsNetwork.configs[].ipRange` | Ip Range | `172.20.5.0/24` |
62+
| `solver.docker.dpsNetwork.configs[].gateway` | Gateway | `172.20.5.1` |
63+
64+
Default DPS network settings
65+
66+
```yaml
67+
---
68+
- subNet: 172.20.0.0/16
69+
ipRange: 172.20.5.0/24
70+
gateway: 172.20.5.1
71+
- subNet: fc00:5c6f:db50::/64
72+
gateway: fc00:5c6f:db50::1
73+
```
5974
6075
---
6176
6277
### System Solver
6378
64-
| Name | Description | Default Value |
65-
|------|-------------|---------------|
79+
| Name | Description | Default Value |
80+
|-------------------------------------|------------------------------------------------|---------------|
6681
| `solver.system.hostMachineHostname` | Hostname that resolves to the host machine IP. | `host.docker` |
6782

6883
---
6984

7085
### Local Solver
7186

72-
| Name | Description | Default Value |
73-
|------|-------------|---------------|
87+
| Name | Description | Default Value |
88+
|--------------------------|-------------------------------------------------------|-------------------|
7489
| `solver.local.activeEnv` | Active environment used to resolve local DNS entries. | `` (empty string) |
7590

7691
---
7792

7893
### Stub Solver
7994

80-
| Name | Description | Default Value |
81-
|------|-------------|---------------|
82-
| `solver.stub.domainName` | Domain name used for stub solver resolved hostnames. | `stub` |
95+
| Name | Description | Default Value |
96+
|--------------------------|------------------------------------------------------|---------------|
97+
| `solver.stub.domainName` | Domain name used for stub solver resolved hostnames. | `stub` |
8398

8499
---
85100

86101
### Default DNS
87102

88-
| Name | Description | Default Value |
89-
|------|-------------|---------------|
90-
| `defaultDns.active` | Whether DPS should be automatically configured as the system default DNS. | `false` |
91-
| `defaultDns.resolvConf.overrideNameServers` | Whether existing nameservers should be commented out or DPS should be placed first. | `true` |
92-
| `defaultDns.resolvConf.paths` | Resolv.conf or systemd-resolved configuration paths used to apply default DNS. | /host/etc/systemd/resolved.conf,/host/etc/resolv.conf,/etc/systemd/resolved.conf,/etc/resolv.conf |
103+
| Name | Description | Default Value |
104+
|---------------------------------------------|-------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------|
105+
| `defaultDns.active` | Whether DPS should be automatically configured as the system default DNS. | `false` |
106+
| `defaultDns.resolvConf.overrideNameServers` | Whether existing nameservers should be commented out or DPS should be placed first. | `true` |
107+
| `defaultDns.resolvConf.paths` | Resolv.conf or systemd-resolved configuration paths used to apply default DNS. | /host/etc/systemd/resolved.conf,/host/etc/resolv.conf,/etc/systemd/resolved.conf,/etc/resolv.conf |
93108

94109
---
95110

96111
### Logs
97112

98-
| Name | Description | Default Value |
99-
|------|-------------|---------------|
100-
| `log.level` | Logging level used by DPS. | `INFO` |
101-
| `log.file` | Output target for logs (file path or console). | `console` |
102-
113+
| Name | Description | Default Value |
114+
|-------------|------------------------------------------------|---------------|
115+
| `log.level` | Logging level used by DPS. | `INFO` |
116+
| `log.file` | Output target for logs (file path or console). | `console` |
103117

104118
### File Configuration Example
119+
105120
* [Solver remote circuit breaker configuration][3]
106121

107-
```json
122+
```yaml
108123
version: 3
109124
server:
110125
dns:
@@ -132,6 +147,12 @@ solver:
132147
name: dps
133148
autoCreate: false
134149
autoConnect: false
150+
configs:
151+
- subNet: 172.20.0.0/16
152+
ipRange: 172.20.5.0/24
153+
gateway: 172.20.5.1
154+
- subNet: fc00:5c6f:db50::/64
155+
gateway: fc00:5c6f:db50::1
135156
dockerDaemonUri:
136157
system:
137158
hostMachineHostname: host.docker
@@ -156,8 +177,8 @@ log:
156177
file: console
157178
```
158179

159-
160180
### Legacy Configuration
181+
161182
[[ref][4]]
162183

163184
[1]: {{%relref "2-features/auto-configuration-as-default-dns/_index.md" %}}

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
version=5.1.3-snapshot
1+
version=5.2.0-snapshot

0 commit comments

Comments
 (0)