Skip to content

Conversation

@Unix4ever
Copy link
Member

Fixes: #1816

This change also deprecates omnictl machine-logs command and introduces a new command group omnictl machine ....

Now the logs can be read by using omnictl machine logs --id <id>. For the tunnel mode management there is now command:

omnictl machine configure --id <id> grpc-tunnel-mode [enabled|disabled|auto]

@Unix4ever Unix4ever requested a review from Slessi as a code owner November 28, 2025 16:16
@github-project-automation github-project-automation bot moved this to To Do in Planning Nov 28, 2025
@talos-bot talos-bot moved this from To Do to In Review in Planning Nov 28, 2025
@utkuozdemir
Copy link
Member

I think there shouldn't be a required --id flag, instead, we should use args[0] - flags kinda imply optionality, and omnictl machine configure <id> and omnictl machine logs <id> read more natural to me. I mean, machine commands already always operate on a single machine.

@Unix4ever
Copy link
Member Author

I think there shouldn't be a required --id flag, instead, we should use args[0] - flags kinda imply optionality, and omnictl machine configure and omnictl machine logs read more natural to me. I mean, machine commands already always operate on a single machine.

I think cobra doesn't support positional args in the middle of command. So this kind of command is not going to work omnictl machine configure <id> grpc-tunnel-mode <mode>

@rothgar
Copy link
Member

rothgar commented Dec 1, 2025

Do we envision other settings for configure? I would think those would be "patches" to the configuration. Something like

omnictl patch machine $ID -p '{"spec": {"grpc-tunnel-mode": "http"}}'

This is the structure for kubectl patches and can work generically for objects and config

@Unix4ever
Copy link
Member Author

This is the structure for kubectl patches and can work generically for objects and config

can't say I like this. Tunnel mode is not a part of the machine config, it's a separate resource. So this kind of syntax will be confusing.

Fixes: siderolabs#1816

This change also deprecates `omnictl machine-logs` command and
introduces a new command group `omnictl machine ...`.

Now the logs can be read by using `omnictl machine logs --id <id>`.
For the tunnel mode management there is now command:

```
omnictl machine configure --id <id> grpc-tunnel-mode [enabled|disabled|auto]
```

Signed-off-by: Artem Chernyshev <artem.chernyshev@talos-systems.com>
@rothgar
Copy link
Member

rothgar commented Dec 4, 2025

I don't really like the syntax either but I was thinking the command order is more familiar for k8s users and the json is more flexible in case we want to patch more things in the future.

Maybe we can make the configurable patches flags instead. Something like

omnictl patch machine $ID --patch grpc-tunnel-mode=enabled

Now that I think about it, is grpc-tunnel-mode clear what people are doing? Should this be --siderolink-connection=[udp,http-tunnel] because grpc is used in multiple parts of talos it could be confusing when this is being used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: In Review

Development

Successfully merging this pull request may close these issues.

[feature] support switching tunnel mode on the machine level in omni

4 participants