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

Update README and move start.sh script (and rename) #263

Merged
merged 2 commits into from
Jun 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
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
32 changes: 21 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,21 +121,31 @@ This is the equivalent of:
ip addr del MY_IP dev MY_INTERFACE
```

## Dev environment
## Development environment
Copy link
Member

Choose a reason for hiding this comment

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

praise: I like this kind of attention to details 🤩


To make it work in dev you might want to create some dummy interfaces:
To make it work in dev you need to create dummy interfaces which will be
manipulated by LinK to simulate failover.

```shell
modprobe dummy
ip link add eth10 type dummy
ip link set eth10 up
ip link add eth11 type dummy
ip link set eth11 up
ip link add eth12 type dummy
ip link set eth12 up
The best way is to use systemd to automate this setup:

```bash
for idx in 10 11 12 ; do
Copy link
Member

Choose a reason for hiding this comment

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

suggestion: maybe explicitly mention that this code block is bash to make sure it's correctly colored?

echo "[NetDev]
Name=eth${idx}
Kind=dummy" | sudo tee "/etc/systemd/network/10-sc-dummy-eth${idx}.netdev"
done

echo "[Match]
Name=eth1*
[Link]
ActivationPolicy=up" | sudo tee "/etc/systemd/network/11-sc-dummy-activation.network"
```

The script `start.sh` can be executed as root to automatically do that.
Then run `systemctl restart systemd-networkd` to activate them immediately.

If you're not using Systemd or want to do the setup manually, the script
`hacks/setup_dummy_netlink_interfaces.sh` can be executed as root to manually
create `eth10`, `eth11` and `eth12`.

## Release a New Version

Expand Down
File renamed without changes.