Skip to content

Commit

Permalink
Merge branch 'master' into camh/start-v18
Browse files Browse the repository at this point in the history
  • Loading branch information
camscale authored Oct 28, 2024
2 parents 00f61b2 + 872b97a commit 2319e96
Show file tree
Hide file tree
Showing 161 changed files with 8,387 additions and 5,026 deletions.
54 changes: 34 additions & 20 deletions .github/ISSUE_TEMPLATE/testplan.md
Original file line number Diff line number Diff line change
Expand Up @@ -979,10 +979,14 @@ manualy testing.
- [ ] Self-hosted MariaDB.
- [ ] Self-hosted MongoDB.
- [ ] Self-hosted CockroachDB.
- [ ] Self-hosted Redis.
- [ ] Self-hosted Redis/Valkey.
- [ ] Self-hosted Redis Cluster.
- [ ] Self-hosted MSSQL.
- [ ] Self-hosted MSSQL with PKINIT authentication.
- [ ] Self-hosted Elasticsearch.
- [ ] Self-hosted Cassandra/ScyllaDB.
- [ ] Self-hosted Oracle.
- [ ] Self-hosted ClickHouse.
- [ ] AWS Aurora Postgres.
- [ ] AWS Aurora MySQL.
- [ ] MySQL server version reported by Teleport is correct.
Expand All @@ -992,53 +996,57 @@ manualy testing.
- [ ] Verify connection to external AWS account works with `assume_role_arn: ""` and `external_id: "<id>"`
- [ ] AWS ElastiCache.
- [ ] AWS MemoryDB.
- [ ] AWS OpenSearch.
- [ ] AWS Dynamodb.
- [ ] Verify connection to external AWS account works with `assume_role_arn: ""` and `external_id: "<id>"`
- [ ] AWS DocumentDB
- [ ] AWS Keyspaces
- [ ] Verify connection to external AWS account works with `assume_role_arn: ""` and `external_id: "<id>"`
- [ ] GCP Cloud SQL Postgres.
- [ ] GCP Cloud SQL MySQL.
- [ ] GCP Cloud Spanner.
- [ ] Snowflake.
- [ ] Azure Cache for Redis.
- [x] Azure single-server MySQL and Postgres (EOL Sep 2024 and Mar 2025, skip)
- [ ] Azure flexible-server MySQL and Postgres
- [ ] Elasticsearch.
- [ ] OpenSearch.
- [ ] Cassandra/ScyllaDB.
- [ ] Verify connection to external AWS account works with `assume_role_arn: ""` and `external_id: "<id>"`
- [ ] Dynamodb.
- [ ] Verify connection to external AWS account works with `assume_role_arn: ""` and `external_id: "<id>"`
- [ ] Azure flexible-server MySQL
- [ ] Azure flexible-server Postgres
- [ ] Azure SQL Server.
- [ ] Oracle.
- [ ] ClickHouse.
- [ ] Snowflake.
- [ ] MongoDB Atlas.
- [ ] Connect to a database within a remote cluster via a trusted cluster.
- [ ] Self-hosted Postgres.
- [ ] Self-hosted MySQL.
- [ ] Self-hosted MariaDB.
- [ ] Self-hosted MongoDB.
- [ ] Self-hosted CockroachDB.
- [ ] Self-hosted Redis.
- [ ] Self-hosted Redis/Valkey.
- [ ] Self-hosted Redis Cluster.
- [ ] Self-hosted MSSQL.
- [ ] Self-hosted MSSQL with PKINIT authentication.
- [ ] Self-hosted Elasticsearch.
- [ ] Self-hosted Cassandra/ScyllaDB.
- [ ] Self-hosted Oracle.
- [ ] Self-hosted ClickHouse.
- [ ] AWS Aurora Postgres.
- [ ] AWS Aurora MySQL.
- [ ] AWS RDS Proxy (MySQL, Postgres, MariaDB, or SQL Server)
- [ ] AWS Redshift.
- [ ] AWS Redshift Serverless.
- [ ] AWS ElastiCache.
- [ ] AWS MemoryDB.
- [ ] AWS OpenSearch.
- [ ] AWS Dynamodb.
- [ ] AWS DocumentDB
- [ ] AWS Keyspaces
- [ ] GCP Cloud SQL Postgres.
- [ ] GCP Cloud SQL MySQL.
- [ ] GCP Cloud Spanner.
- [ ] Snowflake.
- [ ] Azure Cache for Redis.
- [x] Azure single-server MySQL and Postgres (EOL Sep 2024 and Mar 2025, skip)
- [ ] Azure flexible-server MySQL and Postgres
- [ ] Elasticsearch.
- [ ] OpenSearch.
- [ ] Cassandra/ScyllaDB.
- [ ] Dynamodb.
- [ ] Azure flexible-server MySQL
- [ ] Azure flexible-server Postgres
- [ ] Azure SQL Server.
- [ ] Oracle.
- [ ] ClickHouse.
- [ ] Snowflake.
- [ ] MongoDB Atlas.
- [ ] Verify auto user provisioning.
Verify all supported modes: `keep`, `best_effort_drop`
- [ ] Self-hosted Postgres.
Expand Down Expand Up @@ -1084,6 +1092,7 @@ manualy testing.
- [ ] Can detect and register ElastiCache Redis clusters.
- [ ] Can detect and register MemoryDB clusters.
- [ ] Can detect and register OpenSearch domains.
- [ ] Can detect and register DocumentDB clusters.
- [ ] Azure
- [ ] Can detect and register MySQL and Postgres single-server instances.
- [ ] Can detect and register MySQL and Postgres flexible-server instances.
Expand All @@ -1098,6 +1107,11 @@ manualy testing.
- [ ] Verify searching for all columns in the search bar works
- [ ] Verify you can sort by all columns except `labels`
- [ ] `tsh bench` load tests (instructions on Notion -> Database Access -> Load test)
- [ ] Verify database session player
- [ ] Web UI
- [ ] Postgres
- [ ] `tsh play`
- [ ] Postgres
## TLS Routing
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/doc-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ jobs:
path: "docs"

- name: Prepare docs site configuration
# Prevent occasional `yarn install` executions that run indefinitely
timeout-minutes: 10
# The environment we use for linting the docs differs from the one we
# use for the live docs site in that we only test a single version of
# the content.
Expand Down
20 changes: 0 additions & 20 deletions api/client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -1782,11 +1782,6 @@ func (c *Client) GetRoles(ctx context.Context) ([]types.Role, error) {
for {
rsp, err := c.ListRoles(ctx, &req)
if err != nil {
if trace.IsNotImplemented(err) {
// fallback to calling the old non-paginated role API.
roles, err = c.getRoles(ctx)
return roles, trace.Wrap(err)
}
return nil, trace.Wrap(err)
}

Expand All @@ -1802,21 +1797,6 @@ func (c *Client) GetRoles(ctx context.Context) ([]types.Role, error) {
return roles, nil
}

// getRoles calls the old non-paginated GetRoles method.
//
// DELETE IN 17.0
func (c *Client) getRoles(ctx context.Context) ([]types.Role, error) {
resp, err := c.grpc.GetRoles(ctx, &emptypb.Empty{})
if err != nil {
return nil, trace.Wrap(err)
}
roles := make([]types.Role, 0, len(resp.GetRoles()))
for _, role := range resp.GetRoles() {
roles = append(roles, role)
}
return roles, nil
}

// ListRoles is a paginated role getter.
func (c *Client) ListRoles(ctx context.Context, req *proto.ListRolesRequest) (*proto.ListRolesResponse, error) {
var header gmetadata.MD
Expand Down
23 changes: 22 additions & 1 deletion api/client/events.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import (
clusterconfigpb "github.com/gravitational/teleport/api/gen/proto/go/teleport/clusterconfig/v1"
crownjewelv1 "github.com/gravitational/teleport/api/gen/proto/go/teleport/crownjewel/v1"
dbobjectv1 "github.com/gravitational/teleport/api/gen/proto/go/teleport/dbobject/v1"
identitycenterv1 "github.com/gravitational/teleport/api/gen/proto/go/teleport/identitycenter/v1"
kubewaitingcontainerpb "github.com/gravitational/teleport/api/gen/proto/go/teleport/kubewaitingcontainer/v1"
machineidv1 "github.com/gravitational/teleport/api/gen/proto/go/teleport/machineid/v1"
notificationsv1 "github.com/gravitational/teleport/api/gen/proto/go/teleport/notifications/v1"
Expand Down Expand Up @@ -122,7 +123,18 @@ func EventToGRPC(in types.Event) (*proto.Event, error) {
out.Resource = &proto.Event_AutoUpdateAgentRollout{
AutoUpdateAgentRollout: r,
}

case *identitycenterv1.Account:
out.Resource = &proto.Event_IdentityCenterAccount{
IdentityCenterAccount: r,
}
case *identitycenterv1.PrincipalAssignment:
out.Resource = &proto.Event_IdentityCenterPrincipalAssignment{
IdentityCenterPrincipalAssignment: r,
}
case *identitycenterv1.AccountAssignment:
out.Resource = &proto.Event_IdentityCenterAccountAssignment{
IdentityCenterAccountAssignment: r,
}
default:
return nil, trace.BadParameter("resource type %T is not supported", r)
}
Expand Down Expand Up @@ -588,6 +600,15 @@ func EventFromGRPC(in *proto.Event) (*types.Event, error) {
} else if r := in.GetProvisioningPrincipalState(); r != nil {
out.Resource = types.Resource153ToLegacy(r)
return &out, nil
} else if r := in.GetIdentityCenterAccount(); r != nil {
out.Resource = types.Resource153ToLegacy(r)
return &out, nil
} else if r := in.GetIdentityCenterPrincipalAssignment(); r != nil {
out.Resource = types.Resource153ToLegacy(r)
return &out, nil
} else if r := in.GetIdentityCenterAccountAssignment(); r != nil {
out.Resource = types.Resource153ToLegacy(r)
return &out, nil
} else {
return nil, trace.BadParameter("received unsupported resource %T", in.Resource)
}
Expand Down
Loading

0 comments on commit 2319e96

Please sign in to comment.