commonparams

package
v1.120.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 3, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	IAMFormatParamName               = "iam-format"
	FilterDeletedIAMMembersParamName = "filter-deleted-iam-members"
	OAuth2TokenParamName             = "oauth2-token"
	OutputParamName                  = "output"
	ResourceFormatParamName          = "resource-format"

	PartialPolicyFormatOption   = "partialpolicy"
	PolicyIAMFormatOption       = "policy"
	PolicyMemberIAMFormatOption = "policymember"
	NoneIAMFormatOption         = "none"

	KRMResourceFormatOption = outputsink.KRMResourceFormat
	HCLResourceFormatOption = outputsink.HCLResourceFormat

	IAMFormatDefault               = PolicyIAMFormatOption
	FilterDeletedIAMMembersDefault = false
	OAuth2TokenDefault             = ""
	OutputDefault                  = ""
	ResourceFormatDefault          = KRMResourceFormatOption

	OAuth2TokenUsage = "" /* 152-byte string literal not displayed */
	OutputUsage      = "" /* 206-byte string literal not displayed */
)

Variables

View Source
var (
	IAMFormatUsage               = fmt.Sprintf("specify the IAM resource format or disable IAM output, options are '%v', '%v', '%v', or '%v'", PartialPolicyFormatOption, PolicyIAMFormatOption, PolicyMemberIAMFormatOption, NoneIAMFormatOption)
	FilterDeletedIAMMembersUsage = fmt.Sprintf("specify whether to filter out deleted IAM members, options are '%v' or '%v', (default: '%v')", true, false, FilterDeletedIAMMembersDefault)
	ResourceFormatUsage          = fmt.Sprintf("specify the format of the outputted resources, options are '%v' or '%v' (default: '%v')", KRMResourceFormatOption, HCLResourceFormatOption, ResourceFormatDefault)
)

Functions

func AddFilterDeletedIAMMembersParam

func AddFilterDeletedIAMMembersParam(cmd *cobra.Command, value *bool)

func AddIAMFormatParam

func AddIAMFormatParam(cmd *cobra.Command, value *string)

func AddOAuth2TokenParam

func AddOAuth2TokenParam(cmd *cobra.Command, value *string)

func AddOutputParam

func AddOutputParam(cmd *cobra.Command, value *string)

func AddResourceFormatParam

func AddResourceFormatParam(cmd *cobra.Command, value *string)

func IAMFormatParamToStreamIAMFormat

func IAMFormatParamToStreamIAMFormat(iamFormatParam string) (stream.IAMFormat, error)

Convert from the an IAMPolicyParam supplied on the command line to the stream type

func ValidateIAMFormat

func ValidateIAMFormat(value string) error

func ValidateResourceFormat

func ValidateResourceFormat(resourceFormat, iamFormat string) error

Types

type IAMFormatOption

type IAMFormatOption string

type ResourceFormatOption

type ResourceFormatOption string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL