Skip to content

Commit

Permalink
en/guides: fix docker run command
Browse files Browse the repository at this point in the history
  • Loading branch information
saramonteiro committed Mar 20, 2023
1 parent 9349536 commit c90e703
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
16 changes: 14 additions & 2 deletions site/en/guides/border-router/docker/run.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,26 @@ sure to run `sudo modprobe ip6table_filter` for OTBR firewall support.
This allows OTBR scripts to create rules inside the Docker container
before `otbr-agent` starts.
Run the following commands before starting the container. That enables
the IPv6 in the host machine and the IP forwarding.
```
sudo sysctl -w net.ipv6.conf.all.disable_ipv6=0
sudo sysctl -w net.ipv4.conf.all.forwarding=1
sudo sysctl -w net.ipv6.conf.all.forwarding=1
```
In a new terminal window, start OTBR Docker, referencing the RCP's serial port.
For example, if the RCP is mounted at `/dev/ttyACM0`:
```
$ docker run --sysctl "net.ipv6.conf.all.disable_ipv6=0 net.ipv4.conf.all.forwarding=1 net.ipv6.conf.all.forwarding=1" -p 8080:80 --dns=127.0.0.1 -it --volume /dev/ttyACM0:/dev/ttyACM0 --privileged openthread/otbr --radio-url spinel+hdlc+uart:///dev/ttyACM0
$ docker run --net=host --dns=127.0.0.1 -it --volume /dev/ttyACM0:/dev/ttyACM0 --privileged openthread/otbr --radio-url spinel+hdlc+uart:///dev/ttyACM0 -B enp3s0
```
> Notes: Consult the specific documentation from the used RCP and analyze if further
configuration is necessary, for example, setting up baudrate:
`--radio-url 'spinel+hdlc+uart:///dev/ttyUSB0?uart-baudrate=1000000'`, also replace `enp3s0` by the name of your interface on the computer running otbr docker, ex: `wlan0`.
Upon success, you should have output similar to this:
Upon success, you should have the initial output similar to this:
```
WARNING: Localhost DNS setting (--dns=127.0.0.1) may fail in containers.
Expand Down
2 changes: 1 addition & 1 deletion site/en/guides/border-router/docker/test-connectivity.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Select **FORM** to form the Thread network. Check the output in the terminal win
otbr-agent[224]: [INFO]-CLI-----: execute command: prefix add fd11:22::/64 pasor
```

This output is required for internet connectivty for the Thread network.
This output is required for internet connectivity for the Thread network.

## Step 2: Bring up a second Thread node

Expand Down

0 comments on commit c90e703

Please sign in to comment.