mirror of
https://github.com/gravitational/teleport.git
synced 2026-10-29 17:58:15 +08:00
For Teleport Discover, the user will be able to test connecting to a resource right after adding it. The flow should look like this: - User selects the resource type - in this case Server/Nodes - WebUI generates a new Token - WebUI shows the `sudo bash .../<token>/install.sh` to the user - When the user runs this command, and assuming everything works out, the WebUI should be able to receive the Server/Node that was generated from that specific Token. To achieve this, here's a more detailed flow, which this PR implements - User selects the resource type - in this case Server/Nodes - WebUI generates a new Token This generates a Provision Token which contains a RefResourceID WebUI receives back that ID - WebUI shows the `sudo bash .../<token>/install.sh` to the user This generates a script which includes setting the labels as part of the `teleport configure` command: `$ teleport configure ... --labels teleport.internal/resource-id=<refResourceID> ...` - User runs the provided command on the target host - WebUI should be able to query the Servers/Nodes which contain that specific `<resource-id>` and allow the user to connect to it. Demo: 