teleport/gen/proto
Rafał Cieślak fc49acb722
Add role setup for Connect My Computer in tshd (#28891)
* Ignore specific teleterm proto file rather than whole package

* clusters.Storage: Avoid unnecessary casting of URI back to string

* Storage.fromProfile: Move loading profile status to separate function

* Return client.TeleportClient together with clusters.Cluster

This is a stopgap to make clusters.Cluster a regular struct with no extra
behavior and a much smaller interface.

At the moment, almost all RPCs go through layers like these:

gRPC handler → daemon.Service → clusters.Storage → clusters.Cluster →
→ TeleportClient

As a result, clusters.Cluster has a gigantic interface that's hard to test.

Instead, we want to make it hold basic information about the cluster.
The real work will be done by collaborator structs which take clusters.Cluster
and TeleportClient as args. This way we can mock them out more easily in tests.

See the issue linked in the comment of clusters.Storage.GetByResourceURI
for more details.

* Make AddMetadataToRetryableError public

Since we're moving away from doing everything in clusters.Cluster, we'll
need to use this function from within the daemon package.

* Add IsRoot and IsLeaf methods to uri.ResourceURI

These methods will be used to return early if someone tries to set up
roles for a leaf cluster. Connect My Computer works with root clusters only.

* Add handler for creating Connect My Computer role

* Add test for calling GenerateUserCerts with bogus request ID

* Fix checking logins of existing role

* Remove commented out argument to ReissueUserCerts

* Add a stopgap comment to Storage.GetByURI

* Remove invalid doc links

* Ensure owner node label has expected value if role already exists

* Add unit test which checks RoleSetup.Run idempotency

* Add godoc for Resolver

* Simplify watcher equality check, add a comment

* Expand the comment for DropAccessRequests

* Fix position of Connect My Computer popover

* Integrate role setup with setup document

* Add temporary action to additional actions

This will be removed once the parent PR is approved. I just wanted to give
reviewers a shortcut to triggering the endpoint from the actual app.

* Add return type to createRole

* Add useRetryWithRelogin

* Wrap role setup in retryWithRelogin

* Remove useRetryWithRelogin in favor of retryWithRelogin & useCallback

* Remove CMC role setup from AdditionalActions

* Prettier fix

* Fix eslint
2023-07-20 11:42:22 +00:00
..
go Add role setup for Connect My Computer in tshd (#28891) 2023-07-20 11:42:22 +00:00
js Add role setup for Connect My Computer in tshd (#28891) 2023-07-20 11:42:22 +00:00