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

Make rootless settings configurable #6498

Merged
merged 4 commits into from
Nov 21, 2022

Conversation

brandond
Copy link
Member

@brandond brandond commented Nov 15, 2022

Proposed Changes

Add environment variables for port-driver, cidr, mtu, enable-ipv6, and disable-host-loopback settings. Since rootless is still experimental, I don't think they deserve full CLI flag status.

Types of Changes

new feature

Verification

Follow the rootless K3s setup instructions (delegating cgroup controllers), then create a k3s-rootless.service as follows:

[Unit]
Description=k3s (Rootless)

[Service]
Environment=PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin K3S_ROOTLESS_MTU=1500 K3S_ROOTLESS_PORT_DRIVER=slirp4netns
ExecStart=k3s server --rootless --snapshotter=fuse-overlayfs
ExecReload=/bin/kill -s HUP $MAINPID
TimeoutSec=0
RestartSec=2
Restart=always
StartLimitBurst=3
StartLimitInterval=60s
LimitNOFILE=infinity
LimitNPROC=infinity
LimitCORE=infinity
TasksMax=infinity
Delegate=yes
Type=simple
KillMode=mixed

Testing

tbd

Linked Issues

User-Facing Change

The rootless `port-driver`, `cidr`, `mtu`, `enable-ipv6`, and `disable-host-loopback` settings can now be configured via environment variables.

Further Comments

@brandond brandond requested a review from a team as a code owner November 15, 2022 07:24
@brandond brandond force-pushed the rootless-slirp4netns-tweaks branch from b09dea2 to 00b3bfa Compare November 15, 2022 09:31
Add enivironment variables for port-driver, cidr, mtu, and disable-host-loopback settings. Since rootless is still experimental, I don't think they deserve full CLI flag status.

Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
@brandond brandond force-pushed the rootless-slirp4netns-tweaks branch from 00b3bfa to 0468c70 Compare November 16, 2022 17:56
Copy link
Contributor

@nikolaishields nikolaishields left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants