Skip to content

Conversation

@smira
Copy link
Member

@smira smira commented Apr 16, 2025

This allows to "hide" from get commands some resources unless they are called by the full name.

See siderolabs/talos#10666

Also rekres and bump deps, fix linting issues.

This allows to "hide" from `get` commands some resources unless they are
called by the full name.

See siderolabs/talos#10666

Also rekres and bump deps, fix linting issues.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
spec.Aliases = append(spec.Aliases, strings.ToLower(spec.DisplayType))

spec.AllAliases = append(spec.AllAliases, strings.ToLower(name))
if !spec.SkipAutomaticAliases {
Copy link
Member Author

Choose a reason for hiding this comment

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

this is the actual change 🤦‍♂️

@github-project-automation github-project-automation bot moved this from In Review to Approved in Planning Apr 16, 2025
@smira
Copy link
Member Author

smira commented Apr 16, 2025

/m

@talos-bot talos-bot merged commit a06b473 into cosi-project:main Apr 16, 2025
14 of 15 checks passed
@github-project-automation github-project-automation bot moved this from Approved to Done in Planning Apr 16, 2025
smira added a commit to smira/talos that referenced this pull request Apr 16, 2025
We have now two `MountStatus` resources: one legacy under `runtime`, and
another (new one) under `block`. As the old `MountStatus` is still used
e.g. in Omni, we still keep it around.

In order to fix `talosctl get mountstatus` to be non-ambigious, we
suppress aliases for the legacy resource:

```
talosctl get mountstatus
NODE         NAMESPACE   TYPE          ID                                  VERSION   SOURCE      TARGET                              FILESYSTEM   VOLUME
172.20.0.2   runtime     MountStatus   /etc/cni                            2                     /etc/cni                            none         /etc/cni
172.20.0.2   runtime     MountStatus   /etc/kubernetes                     2                     /etc/kubernetes                     none         /etc/kubernetes
```

Fixes siderolabs#10666

See cosi-project/runtime#588

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
smira added a commit to smira/talos that referenced this pull request Apr 22, 2025
We have now two `MountStatus` resources: one legacy under `runtime`, and
another (new one) under `block`. As the old `MountStatus` is still used
e.g. in Omni, we still keep it around.

In order to fix `talosctl get mountstatus` to be non-ambigious, we
suppress aliases for the legacy resource:

```
talosctl get mountstatus
NODE         NAMESPACE   TYPE          ID                                  VERSION   SOURCE      TARGET                              FILESYSTEM   VOLUME
172.20.0.2   runtime     MountStatus   /etc/cni                            2                     /etc/cni                            none         /etc/cni
172.20.0.2   runtime     MountStatus   /etc/kubernetes                     2                     /etc/kubernetes                     none         /etc/kubernetes
```

Fixes siderolabs#10666

See cosi-project/runtime#588

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
(cherry picked from commit e51a8ef)
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.

3 participants