Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[v17] Add support for target port in gateways in Connect (#51014)
* Add basic support for target port in gateways in Connect * Update type for targetSubresourceName on DocumentGateway The way DocumentsService.createGatewayDocument is implemented means that the targetSubresourceName property is always present, but it can be undefined. * Use "local port" instead of "port" in DocumentGatewapApp * Rewrite gateway FieldInputs to use styled components * Update comments in protos * useGateway: Stabilize useAsync functions of ports * Add padding to menu label if it's first child * Add support for required prop to Input and FieldInput * Add UI for changing target port * ActionButtons: Show ports of multi-port apps when VNet is not supported Now that we have support for the target port in Connect's gateways, we can show the ports and then open a gateway for that specific port on click. * Add RWMutex to gateways * Clear app gateway cert on target port change * Remove gateways/app.LocalProxyURL It was used only in tests and it made sense only for web apps anyway. * TestTCP: Close connections when test ends * Create context with timeout in testGatewayCertRenewal …instead of in each function that uses it. * Add tests for changing the target port of a TCP gateway * Parallelize app gateway tests within MFA/non-MFA groups * Make testGatewayConnection take ctx as first arg This will be needed in tests that check target port validation. * Validate target port of app gateways * Increase timeouts in app gateway tests * fix: Move testGatewayConnectionFunc to proxy_helpers.go * Add field for changing target port if app gateway fails to start * Make OfflineGateway use uncontrolled forms * Pass form fields to OfflineGateway from outside This will enable each callsite to establish it's own rules as to which fields are required. This will be useful once we add required target subresource name for TCP apps. * Add tests for submitting form through OfflineGateway * Make sure reconnect and formSchema operate on the same type * Add comment for Terminal input * Show available target ports in gateways for multi-port apps * Allow opening multiple gateways for the same app but different target port * Ensure uniqueness of gateways in tshd * Add comments to a bunch of related types and functions * Refactor ClustersService.findGatewayByConnectionParams This makes it work with app gateways too. * Remove gatewayUri from TrackedGatewayConnection * Update document title on target port change * MenuLogin: Support custom ButtonComponent and buttonText * setUpAppGateway: Accept app URI instead of whole app This will let us call this function from places which do not have access to the whole app object. * useGateway: Update doc title after creating gateway * Change list of buttons with ports to MenuLogin with ports * make grpc --------- Co-authored-by: Alan Parra <[email protected]>
- Loading branch information