Better instructions

This commit is contained in:
chapeau 2024-07-29 09:51:43 +02:00
parent 6f978ef7a0
commit f75113c163
2 changed files with 25 additions and 2 deletions

View file

@ -17,4 +17,25 @@ Install python dependencies :
poetry install
```
### Docker
### Docker
On the host, you'll need `docker` and `docker-compose-plugin`.
Clone this repo, edit the `docker-compose.yml` file to suit your needs, and set `config/config.toml` to reflect you infrastructure.
You will need to create an empty `config/dnnsmasq.conf` for the first launch (it will be generated by the main container, but the file needs to exist).
Launch `docker compose`, get the ip address of the polyculenetwork container, and set manual routes via this ip:
```bash
ip route add <translated remote network> via <container ip>
```
Finally, run on the host
```bash
sysctl -w net.ipv4.ip_forward
iptables -A FORWARD -j ACCEPT
```
You will need to run these commands after each restart of the host machine.

View file

@ -23,6 +23,8 @@ services:
- LISTEN_PORT=51820
cap_add:
- NET_ADMIN
sysctls:
net.ipv4.ip_forward: 1
networks:
net1:
ipv4_address: 172.20.1.11
@ -59,4 +61,4 @@ networks:
internet:
ipam:
config:
- subnet: 172.20.0.0/24
- subnet: 172.20.0.0/24