spell fixes (#19419)

This commit is contained in:
Steven Martin
2022-12-16 14:01:28 -05:00
committed by GitHub
parent e1c7304e21
commit e1ebc332f8
27 changed files with 32 additions and 32 deletions
+1 -1
View File
@@ -279,7 +279,7 @@ func TestEmpty(t *testing.T) {
require.Len(t, s, 0)
// normal error case
s, err = Collect(Fail[int](fmt.Errorf("unexpeced error")))
s, err = Collect(Fail[int](fmt.Errorf("unexpected error")))
require.Error(t, err)
require.Len(t, s, 0)
+1 -1
View File
@@ -514,7 +514,7 @@ func FromOneOf(in OneOf) (AuditEvent, error) {
// OneOfs only have one inner field, verify and then read it.
if elem.NumField() != 1 {
// This should never happen for proto one-ofs.
return nil, trace.BadParameter("unexpect number in value %v: %v != 1", elem.Kind(), elem.NumField())
return nil, trace.BadParameter("unexpected number in value %v: %v != 1", elem.Kind(), elem.NumField())
}
auditEvent, ok := elem.Field(0).Interface().(AuditEvent)
+2 -2
View File
@@ -232,7 +232,7 @@ func TestParseElastiCacheEndpoint(t *testing.T) {
},
},
{
name: "primary endpiont, TLS disabled",
name: "primary endpoint, TLS disabled",
inputURI: "my-redis-cluster.xxxxxx.ng.0001.cac1.cache.amazonaws.com:6379",
expectInfo: &RedisEndpointInfo{
ID: "my-redis-cluster",
@@ -241,7 +241,7 @@ func TestParseElastiCacheEndpoint(t *testing.T) {
},
},
{
name: "reader endpiont, TLS disabled",
name: "reader endpoint, TLS disabled",
inputURI: "my-redis-cluster-ro.xxxxxx.ng.0001.cac1.cache.amazonaws.com:6379",
expectInfo: &RedisEndpointInfo{
ID: "my-redis-cluster",
+1 -1
View File
@@ -56,7 +56,7 @@ func TestParseMSSQLEndpoint(t *testing.T) {
{"valid", "random.database.windows.net:1604", true, "random"},
// invalid
{"empty", "", false, ""},
{"malformed adddress", "abc", false, ""},
{"malformed address", "abc", false, ""},
{"only suffix", ".database.windows.net:1604", false, ""},
{"without suffix", "example.com:1604", false, ""},
{"without port", "random.database.windows.net", false, ""},
@@ -481,7 +481,7 @@ func hardCopyFile(src, dest string) error {
destinationHandle, err := os.Create(dest)
if err != nil {
return trace.Wrap(err, "failed to open destinatino file %q for writing", dest)
return trace.Wrap(err, "failed to open destination file %q for writing", dest)
}
defer destinationHandle.Close()
@@ -80,7 +80,7 @@ Click **Review + create**, then **Create**.
Once creation finishes, click **Go to resource**. On the page for the new
identity, click **JSON View**. At the top of the right sidebar, you will see a
field called **Resource ID** with a value resmmbling the following:
field called **Resource ID** with a value resembling the following:
```
/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/my-resource-group/providers/Microsoft.ManagedIdentity/userAssignedIdentities/teleport-azure
@@ -368,7 +368,7 @@ $ tctl create -f azure-cli-access.yaml
<TabItem options="Static Identities" label="All Authentication Methods">
Define a role with access to specific Azure identities, which means that
Teleport users who assume this role can use those (and only those) identites to
Teleport users who assume this role can use those (and only those) identities to
execute commands via an Azure CLI.
Create a file called `azure-cli-access.yaml` with the following content:
@@ -408,7 +408,7 @@ You can define a Teleport role that denies a user access to one or more Azure
identities. To do so, assign values to the `azure_identities` field within the
`spec.deny` section of a `role` resource.
For example, this role denies the user access to all Azure idenitities:
For example, this role denies the user access to all Azure identities:
```yaml
kind: role
@@ -430,7 +430,7 @@ applications, but makes use of the wildcard character (`*`) within the
identity.
Unlike values of `allow.azure_identities`, values of `deny.azure_identities` can
include wildcard expessions in addition to the URIs of specific Azure
include wildcard expressions in addition to the URIs of specific Azure
identities.
The Teleport Auth Service gives `deny` rules precedence over `allow` rules when
@@ -160,7 +160,7 @@ a specific reason to use ACM.
#### Using your own TLS credentials
With this approach, you are responsible for determining how to obtain a TLS
certficiate and private key for your Teleport cluster, and for renewing your
certificate and private key for your Teleport cluster, and for renewing your
credentials periodically. Use this approach if you would like to use a trusted
internal certificate authority instead of Let's Encrypt or AWS Certificate
Manager.
+1 -1
View File
@@ -148,7 +148,7 @@ func TestDiagnoseConnectionForPostgresDatabases(t *testing.T) {
},
{
name: "databse not found",
name: "database not found",
teleportUser: "dbnotfound",
reqResourceName: "dbnotfound",
+1 -1
View File
@@ -56,7 +56,7 @@ var (
writeRequests = prometheus.NewCounter(
prometheus.CounterOpts{
Name: "etcd_backend_write_requests",
Help: "Number of wrtie requests to the database",
Help: "Number of write requests to the database",
},
)
readRequests = prometheus.NewCounter(
+1 -1
View File
@@ -3665,7 +3665,7 @@ func (tc *TeleportClient) SSHLogin(ctx context.Context, sshLoginFunc SSHLoginFun
return nil, trace.Wrap(err)
}
fmt.Fprintf(tc.Stderr, "Re-intiaiting login with YubiKey generated private key.\n")
fmt.Fprintf(tc.Stderr, "Re-initiating login with YubiKey generated private key.\n")
response, err = sshLoginFunc(ctx, priv)
}
}
+1 -1
View File
@@ -437,7 +437,7 @@ func (ns *NodeSession) updateTerminalSize(ctx context.Context, s *tracessh.Sessi
// Send the "window-change" request over the channel.
if err = s.WindowChange(ctx, int(currHeight), int(currWidth)); err != nil {
log.Warnf("Unable to send %v reqest: %v.", sshutils.WindowChangeRequest, err)
log.Warnf("Unable to send %v request: %v.", sshutils.WindowChangeRequest, err)
continue
}
+1 -1
View File
@@ -96,7 +96,7 @@ func Test_gcpGKEClient_ListClusters(t *testing.T) {
errValidation: require.NoError,
},
{
name: "list specifc region",
name: "list specific region",
fields: fields{
client: &fakeGKEClient{
clusters: clusters,
+1 -1
View File
@@ -1560,7 +1560,7 @@ type DatabaseAWS struct {
// AccountID is the AWS account ID.
AccountID string `yaml:"account_id,omitempty"`
// RedshiftServerless contains RedshiftServerless specific settings.
RedshiftServerless DatabaseAWSRedshiftServerless `yaml:"redshift_severless"`
RedshiftServerless DatabaseAWSRedshiftServerless `yaml:"redshift_serverless"`
}
// DatabaseAWSRedshift contains AWS Redshift specific settings.
+1 -1
View File
@@ -168,7 +168,7 @@ func (l *FileLog) EmitAuditEvent(ctx context.Context, event apievents.AuditEvent
}
default:
fields := log.Fields{"event_type": event.GetType(), "event_size": len(line)}
l.WithFields(fields).Warnf("Got a event that exeeded max allowed size.")
l.WithFields(fields).Warnf("Got a event that exceeded max allowed size.")
return trace.BadParameter("event size %v exceeds max entry size %v", len(line), l.MaxScanTokenSize)
}
}
+1 -1
View File
@@ -374,7 +374,7 @@ WaitForStreams:
case <-expired:
return nil, trace.BadParameter("timed out waiting for client to create streams")
case <-connContext.Done():
return nil, trace.BadParameter("onnectoin has dropped, exiting")
return nil, trace.BadParameter("connection has dropped, exiting")
}
}
@@ -489,7 +489,7 @@ WaitForStreams:
case <-expired:
return nil, trace.BadParameter("timed out waiting for client to create streams")
case <-connContext.Done():
return nil, trace.BadParameter("onnectoin has dropped, exiting")
return nil, trace.BadParameter("connection has dropped, exiting")
}
}
+1 -1
View File
@@ -250,7 +250,7 @@ func TestPingConnection(t *testing.T) {
for i := 0; i < nWrites/2; i++ {
select {
case <-ctx.Done():
require.Fail(t, "timout write")
require.Fail(t, "timeout write")
case err := <-writeChan:
require.NoError(t, err)
}
+1 -1
View File
@@ -221,7 +221,7 @@ func TestCloudGetAWSSigninToken(t *testing.T) {
expectedToken: "generated-token",
},
{
name: "validate URL parameters termporary session",
name: "validate URL parameters temporary session",
sessionCredentials: credentials.NewStaticCredentials("id", "secret", "sessiontoken"),
federationServerHandler: http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
values := r.URL.Query()
+1 -1
View File
@@ -54,7 +54,7 @@ func TestBaseUser(t *testing.T) {
cloudResource: mockCloudResource,
}
t.Run("CheckAndSetDafaults", func(t *testing.T) {
t.Run("CheckAndSetDefaults", func(t *testing.T) {
require.NoError(t, user.CheckAndSetDefaults())
require.Equal(t, "local/testuser", user.GetID())
require.Equal(t, "local/testuser", fmt.Sprintf("%v", user))
+1 -1
View File
@@ -169,7 +169,7 @@ func TestAuthGetTLSConfig(t *testing.T) {
expectRootCAs: awsCertPool,
},
{
name: "AWS Redishift",
name: "AWS Redshift",
sessionDatabase: newRedshiftDatabase(t, fixtures.SAMLOktaCertPEM),
expectServerName: "redshift-cluster-1.abcdefghijklmnop.us-east-1.redshift.amazonaws.com",
expectRootCAs: awsCertPool,
+1 -1
View File
@@ -407,7 +407,7 @@ func (c *Client) start() {
return
}
} else {
c.cfg.Log.Warning("Recieved an empty clipboard message")
c.cfg.Log.Warning("Received an empty clipboard message")
}
case tdp.SharedDirectoryAnnounce:
if c.cfg.AllowDirectorySharing {
+1 -1
View File
@@ -221,7 +221,7 @@ func (cfg *HeartbeatConfig) CheckAndSetDefaults() error {
return trace.BadParameter("missing parameter AnnouncePeriod")
}
if cfg.ServerTTL == 0 {
return trace.BadParameter("missing parmeter ServerTTL")
return trace.BadParameter("missing parameter ServerTTL")
}
if cfg.GetServerInfo == nil {
return trace.BadParameter("missing parameter GetServerInfo")
+2 -2
View File
@@ -5372,7 +5372,7 @@ func TestDiagnoseKubeConnection(t *testing.T) {
},
},
{
name: "user choosed to impersonate invalid kube_users",
name: "user chose to impersonate invalid kube_users",
roleFunc: roleWithFullAccess,
kubeGroups: validKubeGroups,
kubeUsers: multiKubeUsers,
@@ -5397,7 +5397,7 @@ func TestDiagnoseKubeConnection(t *testing.T) {
},
},
{
name: "user choosed to impersonate invalid kube_group",
name: "user chose to impersonate invalid kube_group",
roleFunc: roleWithFullAccess,
kubeGroups: validKubeGroups,
kubeUsers: multiKubeUsers,
+1 -1
View File
@@ -60,7 +60,7 @@ func (c *transportConfig) Check() error {
return trace.BadParameter("access point missing")
}
if len(c.cipherSuites) == 0 {
return trace.BadParameter("cipe suites misings")
return trace.BadParameter("cipe suites missing")
}
if c.identity == nil {
return trace.BadParameter("identity missing")
+1 -1
View File
@@ -90,7 +90,7 @@ func main() {
syncPeriod, err := time.ParseDuration(syncPeriodString)
if err != nil {
setupLog.Error(err, "invalid sync-period, please ensure the value is currectly parsed with https://pkg.go.dev/time#ParseDuration")
setupLog.Error(err, "invalid sync-period, please ensure the value is correctly parsed with https://pkg.go.dev/time#ParseDuration")
os.Exit(1)
}
+1 -1
View File
@@ -249,7 +249,7 @@ func Run(options Options) (app *kingpin.Application, executedCommand string, con
dbConfigureCreate.Flag("azure-mysql-discovery", "List of Azure regions in which the agent will discover MySQL servers.").StringsVar(&dbConfigCreateFlags.AzureMySQLDiscoveryRegions)
dbConfigureCreate.Flag("azure-postgres-discovery", "List of Azure regions in which the agent will discover Postgres servers.").StringsVar(&dbConfigCreateFlags.AzurePostgresDiscoveryRegions)
dbConfigureCreate.Flag("azure-redis-discovery", "List of Azure regions in which the agent will discover Azure Cache For Redis servers.").StringsVar(&dbConfigCreateFlags.AzureRedisDiscoveryRegions)
dbConfigureCreate.Flag("azure-sqlserver-discovery", "List of Azure regions in which the agent will discover Azure SQL Databaes and Managed Instances.").StringsVar(&dbConfigCreateFlags.AzureSQLServerDiscoveryRegions)
dbConfigureCreate.Flag("azure-sqlserver-discovery", "List of Azure regions in which the agent will discover Azure SQL Databases and Managed Instances.").StringsVar(&dbConfigCreateFlags.AzureSQLServerDiscoveryRegions)
dbConfigureCreate.Flag("azure-subscription", "List of Azure subscription IDs for Azure discoveries. Default is \"*\".").Default(types.Wildcard).StringsVar(&dbConfigCreateFlags.AzureSubscriptions)
dbConfigureCreate.Flag("azure-resource-group", "List of Azure resource groups for Azure discoveries. Default is \"*\".").Default(types.Wildcard).StringsVar(&dbConfigCreateFlags.AzureResourceGroups)
dbConfigureCreate.Flag("azure-tags", "(Only for Azure discoveries) Comma-separated list of Azure resource tags to match, for example env=dev,dept=it").StringVar(&dbConfigCreateFlags.AzureRawTags)
+1 -1
View File
@@ -308,7 +308,7 @@ func localListenerAddr() string {
func waitForEvents(t *testing.T, svc service.Supervisor, events ...string) {
for _, event := range events {
_, err := svc.WaitForEventTimeout(30*time.Second, event)
require.NoError(t, err, "service server didn't receved %v event after 30s", event)
require.NoError(t, err, "service server didn't receive %v event after 30s", event)
}
}