Using talosctl
You may use any gRPC compatible client to interact with Talos. For this example we’ll use talosctl.
Every Talos Linux node does expose an endpoint for the Talos gRPC API. When you use talosctl it will try to connect to the gRPC endpoint specified in the Talosconfig. This may fail if the endpoint is not reachable. In that case you can specify a different node from the cluster you want to interact with using the --endpoints CLI parameter of talosctl, providing a IP / DNS record of that endpoint, to connect to a different endpoint.
The --nodes parameter of talosctl however always has to be specified and specifies the nodes that should be targeted by the talosctl command. If the --endpoints used are different from the --nodes used the chosen endpoint will proxy the command to all the specified nodes. A network connection from the talosctl CLI is only created to the --endpoints.
Check the talosctl documentation to learn more about how to use talosctl.
While it’s possible to use talosctl to interact with a STACKIT Edge Cloud managed cluster please be aware that you should not use talosctl to directly change the configuration of your managed systems. If you want to change the configuration of your system make sure to interact with it using the exposed STEC CRDs such as EdgeCluster, as explained in the documentation. Commands such as talosctl rollback, talosctl rotate-ca and talosctl reset can break the connection with STACKIT Edge Cloud management plane and lead to unexpected behavior. As a best practice only use commands that read information but don’t alter it.
Make sure you use the latest version of talosctl that’s supported with the Talos version of the Talos node you’re working with. In the examples below we’ve been using talosctl version 1.10.5.
Prerequisites:
- You acquired a valid Talosconfig for the STEC managed Edge Cluster.
- Tools: a generic Linux bash terminal, talosctl, yq.
Steps:
> export TALOSCONFIG=your-edge-cluster.talosconfig.yaml
> TALOS_IP=$(yq '.contexts.[ keys |.[0]].endpoints[0] | split(":") |.[0]'./my-edge-cluster.talosconfig)
> talosctl --nodes $TALOS_IP get membersNODE NAMESPACE TYPE ID VERSION HOSTNAME MACHINE TYPE OS ADDRESSES192.168.4.142 cluster Member talos-4ic-txr 1 talos-4ic-txr controlplane Talos (v1.10.5) ["192.168.4.142"]
> talosctl --nodes $TALOS_IP get svcNODE NAMESPACE TYPE ID VERSION RUNNING HEALTHY HEALTH UNKNOWN192.168.4.142 runtime Service apid 2 true true false192.168.4.142 runtime Service auditd 2 true true false192.168.4.142 runtime Service containerd 2 true true false192.168.4.142 runtime Service cri 2 true true false192.168.4.142 runtime Service dashboard 1 true false true192.168.4.142 runtime Service etcd 2 true true false192.168.4.142 runtime Service ext-edgehostlet 1 true false true192.168.4.142 runtime Service kubelet 2 true true false192.168.4.142 runtime Service machined 2 true true false192.168.4.142 runtime Service syslogd 2 true true false192.168.4.142 runtime Service trustd 2 true true false192.168.4.142 runtime Service udevd 2 true true false