def CommonArgs(parser): # Flags specific to managed CR managed_group = flags.GetManagedArgGroup(parser) flags.AddRegionArg(managed_group) flags.AddAllowUnauthenticatedFlag(managed_group) flags.AddRevisionSuffixArg(managed_group) flags.AddServiceAccountFlag(managed_group) flags.AddCloudSQLFlags(managed_group) # Flags specific to CRoGKE gke_group = flags.GetGkeArgGroup(parser) concept_parsers.ConceptParser([resource_args.CLUSTER_PRESENTATION ]).AddToParser(gke_group) # Flags not specific to any platform service_presentation = presentation_specs.ResourcePresentationSpec( 'SERVICE', resource_args.GetServiceResourceSpec(prompt=True), 'Service to deploy to.', required=True, prefixes=False) flags.AddSourceRefFlags(parser) flags.AddFunctionArg(parser) flags.AddMutexEnvVarsFlags(parser) flags.AddMemoryFlag(parser) flags.AddConcurrencyFlag(parser) flags.AddTimeoutFlag(parser) flags.AddAsyncFlag(parser) concept_parsers.ConceptParser([service_presentation ]).AddToParser(parser)
def Args(parser): service_presentation = presentation_specs.ResourcePresentationSpec( 'SERVICE', resource_args.GetServiceResourceSpec(prompt=True), 'Service to deploy to.', required=True, prefixes=False) flags.AddSourceRefFlags(parser) flags.AddRegionArg(parser) flags.AddPlatformArg(parser) flags.AddKubeconfigFlags(parser) flags.AddFunctionArg(parser) flags.AddMutexEnvVarsFlags(parser) flags.AddCpuFlag(parser) flags.AddMemoryFlag(parser) flags.AddConcurrencyFlag(parser) flags.AddTimeoutFlag(parser) flags.AddAsyncFlag(parser) flags.AddEndpointVisibilityEnum(parser) flags.AddCloudSQLFlags(parser) flags.AddAllowUnauthenticatedFlag(parser) flags.AddServiceAccountFlag(parser) concept_parsers.ConceptParser( [resource_args.CLUSTER_PRESENTATION, service_presentation]).AddToParser(parser)
def Args(parser): service_presentation = presentation_specs.ResourcePresentationSpec( 'SERVICE', resource_args.GetServiceResourceSpec(prompt=True), 'Service to deploy to.', required=True, prefixes=False) flags.AddSourceRefFlags(parser) flags.AddRegionArg(parser) flags.AddFunctionArg(parser) flags.AddMutexEnvVarsFlags(parser) flags.AddMemoryFlag(parser) flags.AddConcurrencyFlag(parser) flags.AddAsyncFlag(parser) concept_parsers.ConceptParser( [resource_args.CLUSTER_PRESENTATION, service_presentation]).AddToParser(parser)