-
Notifications
You must be signed in to change notification settings - Fork 4.5k
update servicecatalog cli example docs #9957
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Changes from all commits
49a622b
77f7929
50cfdb1
086c251
81d5f4b
17f7cff
7f41c46
b4d8420
4508265
3c0d709
312aa37
2990a13
e5c826e
7bc036c
f91fd18
9f82347
0d0c777
9510280
8172923
9f21f7f
afe3bea
d984592
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,25 @@ | ||||||
| **To create a constraints** | ||||||
|
|
||||||
| The following ``create-constraint`` example creates a constraint. :: | ||||||
|
|
||||||
| aws servicecatalog create-constraint \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --portfolio-id port-y3fnkesxxxxx \ | ||||||
| --product-id prod-cfrfxmraxxxxx \ | ||||||
| --type LAUNCH \ | ||||||
| --parameters '{"RoleArn" : "arn:aws:iam::123456789012:role/LaunchRole"}' | ||||||
|
|
||||||
| Output:: | ||||||
|
|
||||||
| { | ||||||
| "ConstraintDetail": { | ||||||
| "ConstraintId": "cons-7tr6gei4bxxxx", | ||||||
| "Type": "LAUNCH", | ||||||
| "Owner": "123456789012", | ||||||
| "ProductId": "prod-cfrfxmra3xxxx", | ||||||
| "PortfolioId": "port-y3fnkeslpxxxx" | ||||||
| }, | ||||||
| "ConstraintParameters": "{\"RoleArn\" : \"arn:aws:iam::123456789012:role/LaunchRole\"}", | ||||||
| "Status": "CREATING" | ||||||
| } | ||||||
|
|
||||||
| For more information, see `Using AWS Service Catalog Constraints <https://docs.aws.amazon.com/servicecatalog/latest/adminguide/constraints.html>`__ in the *AWS Service Catalog User Guide*. | ||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| **To create a plan** | ||
|
|
||
| The following ``create-provisioned-product-plan`` example creates a plan. :: | ||
|
|
||
| aws servicecatalog create-provisioned-product-plan \ | ||
| --plan-name test-plan \ | ||
| --plan-type CLOUDFORMATION \ | ||
| --product-id prod-cfrfxmraxxxxx \ | ||
| --provisioned-product-name test-pp \ | ||
| --provisioning-artifact-id pa-7wz4cu5cxxxxx | ||
|
|
||
| Output:: | ||
|
|
||
| { | ||
| "PlanName": "test-plan", | ||
| "PlanId": "plan-cuxae3z6gxxxx", | ||
| "ProvisionProductId": "pp-7kh7wbc4xxxxx", | ||
| "ProvisionedProductName": "test-pp", | ||
| "ProvisioningArtifactId": "pa-7wz4cu5cxxxxx" | ||
| } |
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,10 @@ | ||||||
| **To delete a constraint** | ||||||
|
|
||||||
| The following ``delete-constraint`` example deletes a constraint. :: | ||||||
|
|
||||||
| aws servicecatalog delete-constraint \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --constraint-id cons-7tr6gei4bxxxx | ||||||
|
|
||||||
| This command produces no output. | ||||||
|
|
||||||
| For more information, see `Using AWS Service Catalog Constraints <https://docs.aws.amazon.com/servicecatalog/latest/adminguide/constraints.html>`__ in the *AWS Service Catalog User Guide*. | ||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| **To delete a provisioned product plan** | ||
|
|
||
| The following ``delete-provisioned-product-plan`` example deletes a provisioned product plan. :: | ||
|
|
||
| aws servicecatalog delete-provisioned-product-plan \ | ||
| --plan-id plan-cuxae3z6gxxxx | ||
|
|
||
| This command produces no output. |
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,22 @@ | ||||||
| **To describe a constraint** | ||||||
|
|
||||||
| The following ``describe-constraint`` example describes a constraint. :: | ||||||
|
|
||||||
| aws servicecatalog describe-constraint \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --id "cons-oqp52evr4bxxxx" | ||||||
|
|
||||||
| Output:: | ||||||
|
|
||||||
| { | ||||||
| "ConstraintDetail": { | ||||||
| "ConstraintId": "cons-7tr6gei4bxxxx", | ||||||
| "Type": "LAUNCH", | ||||||
| "Owner": "123456789012", | ||||||
| "ProductId": "prod-cfrfxmra3xxxx", | ||||||
| "PortfolioId": "port-y3fnkeslpxxxx" | ||||||
| }, | ||||||
| "ConstraintParameters": "{\"RoleArn\" : \"arn:aws:iam::123456789012:role/LaunchRole\"}", | ||||||
| "Status": "AVAILABLE" | ||||||
| } | ||||||
|
|
||||||
| For more information, see `Using AWS Service Catalog Constraints <https://docs.aws.amazon.com/servicecatalog/latest/adminguide/constraints.html>`__ in the *AWS Service Catalog User Guide*. | ||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,23 @@ | ||||||
| **To describe portfolio share status** | ||||||
|
|
||||||
| The following ``describe-portfolio-share-status`` example describes portfolio share status. :: | ||||||
|
|
||||||
| aws servicecatalog describe-portfolio-share-status \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --portfolio-share-token "share-agngcybu4xxxx" | ||||||
|
|
||||||
| Output:: | ||||||
|
|
||||||
| { | ||||||
| "PortfolioShareToken": "share-agngcybu4xxxx", | ||||||
| "PortfolioId": "port-y3fnkeslxxxxx", | ||||||
| "OrganizationNodeValue": "123456789012", | ||||||
| "Status": "COMPLETED", | ||||||
| "ShareDetails": { | ||||||
| "SuccessfulShares": [ | ||||||
| "210987654321" | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Account ID doesn't follow the suggested pattern from the style guide: https://aws.github.io/aws-cli/docs_styleguide.html#sanitizing-sensitive-information |
||||||
| ], | ||||||
| "ShareErrors": [] | ||||||
| } | ||||||
| } | ||||||
|
|
||||||
| For more information, see `Sharing a Portfolio <https://docs.aws.amazon.com/servicecatalog/latest/adminguide/catalogs_portfolios_sharing_how-to-share.html>`__ in the *AWS Service Catalog User Guide*. | ||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,30 @@ | ||||||
| **To describe portfolio shares** | ||||||
|
|
||||||
| The following ``describe-portfolio-shares`` example describes portfolio shares. :: | ||||||
|
|
||||||
| aws servicecatalog describe-portfolio-shares \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --portfolio-id port-y3fnkeslxxxxx \ | ||||||
| --type ACCOUNT | ||||||
|
|
||||||
| Output:: | ||||||
|
|
||||||
| { | ||||||
| "PortfolioShareDetails": [ | ||||||
| { | ||||||
| "PrincipalId": "012345678901", | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Account ID doesn't follow the suggested pattern from the style guide: https://aws.github.io/aws-cli/docs_styleguide.html#sanitizing-sensitive-information |
||||||
| "Type": "ACCOUNT", | ||||||
| "Accepted": true, | ||||||
| "ShareTagOptions": false, | ||||||
| "SharePrincipals": false | ||||||
| }, | ||||||
| { | ||||||
| "PrincipalId": "098765432109", | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Account ID doesn't follow the suggested pattern from the style guide: https://aws.github.io/aws-cli/docs_styleguide.html#sanitizing-sensitive-information |
||||||
| "Type": "ACCOUNT", | ||||||
| "Accepted": false, | ||||||
| "ShareTagOptions": false, | ||||||
| "SharePrincipals": false | ||||||
| } | ||||||
| ] | ||||||
| } | ||||||
|
|
||||||
| For more information, see `Sharing a Portfolio <https://docs.aws.amazon.com/servicecatalog/latest/adminguide/catalogs_portfolios_sharing_how-to-share.html>`__ in the *AWS Service Catalog User Guide*. | ||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,54 @@ | ||||||
| **To describe a product** | ||||||
|
|
||||||
| The following ``describe-product`` example describes a product. :: | ||||||
|
|
||||||
| aws servicecatalog describe-product \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --id prod-dybl43puxxxxx | ||||||
|
|
||||||
| Output:: | ||||||
|
|
||||||
| { | ||||||
| "ProductViewSummary": { | ||||||
| "Id": "prodview-vkvy2kum5xxxx", | ||||||
| "ProductId": "prod-dybl43puxxxxx", | ||||||
| "Name": "ec2-test", | ||||||
| "Owner": "user", | ||||||
| "ShortDescription": "", | ||||||
| "Type": "CLOUD_FORMATION_TEMPLATE", | ||||||
| "Distributor": "", | ||||||
| "HasDefaultPath": false, | ||||||
| "SupportEmail": "", | ||||||
| "SupportDescription": "", | ||||||
| "SupportUrl": "" | ||||||
| }, | ||||||
| "ProvisioningArtifacts": [ | ||||||
| { | ||||||
| "Id": "pa-j7fs6ybztxxxx", | ||||||
| "Name": "v2", | ||||||
| "Description": "", | ||||||
| "CreatedTime": "2021-07-16T15:20:24-05:00", | ||||||
| "Guidance": "DEFAULT" | ||||||
| }, | ||||||
| { | ||||||
| "Id": "pa-s6z7i2nivxxxx", | ||||||
| "Description": "Create EC2 and KMS", | ||||||
| "CreatedTime": "2024-06-13T18:27:54-05:00", | ||||||
| "Guidance": "DEFAULT" | ||||||
| }, | ||||||
| { | ||||||
| "Id": "pa-6573v3bloxxxx", | ||||||
| "Name": "v3", | ||||||
| "CreatedTime": "2024-06-13T18:45:14-05:00", | ||||||
| "Guidance": "DEFAULT" | ||||||
| } | ||||||
| ], | ||||||
| "Budgets": [], | ||||||
| "LaunchPaths": [ | ||||||
| { | ||||||
| "Id": "lpv3-y3fnkeslpxxxx", | ||||||
| "Name": "TestPort" | ||||||
| } | ||||||
| ] | ||||||
| } | ||||||
|
|
||||||
| For more information, see `Managing Products <https://docs.aws.amazon.com/servicecatalog/latest/adminguide/catalogs_products.html>`__ in the *AWS Service Catalog User Guide*. | ||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,25 @@ | ||||||
| **To describe a provisioned product plan** | ||||||
|
|
||||||
| The following ``describe-provisioned-product-plan`` example describes a provisioned product plan. :: | ||||||
|
|
||||||
| aws servicecatalog describe-provisioned-product-plan \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --plan-id "plan-g7iwsaf3mxxxx" | ||||||
|
|
||||||
| Output:: | ||||||
|
|
||||||
| { | ||||||
| "ProvisionedProductPlanDetails": { | ||||||
| "CreatedTime": "2025-11-09T18:09:37.808000-06:00", | ||||||
| "PathId": "lpv3-y3fnkeslpxxxx", | ||||||
| "ProductId": "prod-cfrfxmraxxxxx", | ||||||
| "PlanName": "test-plan", | ||||||
| "PlanId": "plan-g7iwsaf3mxxxx", | ||||||
| "ProvisionProductId": "pp-mkbnbztzxxxxx", | ||||||
| "ProvisionProductName": "test-pp", | ||||||
| "PlanType": "CLOUDFORMATION", | ||||||
| "ProvisioningArtifactId": "pa-7wz4cu5cxxxxx", | ||||||
| "Status": "CREATE_SUCCESS", | ||||||
| "UpdatedTime": "2025-11-09T18:09:46.524000-06:00", | ||||||
| "Tags": [] | ||||||
| } | ||||||
| } | ||||||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,63 @@ | ||||||
| **To describe provisioning parameters** | ||||||
|
|
||||||
| The following ``describe-provisioning-parameters`` example describes provisioning parameters. :: | ||||||
|
|
||||||
| aws servicecatalog describe-provisioning-parameters \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --product-id prod-cfrfxmraxxxxx \ | ||||||
| --provisioning-artifact-id pa-7wz4cu5cxxxxx \ | ||||||
| --path-id lpv3-y3fnkeslpxxxx | ||||||
|
|
||||||
| Output:: | ||||||
|
|
||||||
| { | ||||||
| "ProvisioningArtifactParameters": [ | ||||||
| { | ||||||
| "ParameterKey": "Size", | ||||||
| "ParameterType": "String", | ||||||
| "IsNoEcho": false, | ||||||
| "ParameterConstraints": { | ||||||
| "AllowedValues": [] | ||||||
| } | ||||||
| } | ||||||
| ], | ||||||
| "ConstraintSummaries": [ | ||||||
| { | ||||||
| "Type": "LAUNCH" | ||||||
| } | ||||||
| ], | ||||||
| "UsageInstructions": [ | ||||||
| { | ||||||
| "Type": "rules", | ||||||
| "Value": "{}" | ||||||
| }, | ||||||
| { | ||||||
| "Type": "version", | ||||||
| "Value": "2010-09-09" | ||||||
| }, | ||||||
| { | ||||||
| "Type": "launchAsRole", | ||||||
| "Value": "arn:aws:iam::123456789012:role/NewLaunchRole" | ||||||
| }, | ||||||
| { | ||||||
| "Type": "tagUpdateOnProvisionedProduct", | ||||||
| "Value": "NOT_ALLOWED" | ||||||
| } | ||||||
| ], | ||||||
| "TagOptions": [ | ||||||
| { | ||||||
| "Key": "Application Name", | ||||||
| "Values": [ | ||||||
| "Testing Tag", | ||||||
| "Testing Tag Options" | ||||||
| ] | ||||||
| } | ||||||
| ], | ||||||
| "ProvisioningArtifactPreferences": {}, | ||||||
| "ProvisioningArtifactOutputs": [ | ||||||
| { | ||||||
| "Key": "pa-7wz4cu5cxxxxx", | ||||||
| "Description": "" | ||||||
| } | ||||||
| ], | ||||||
| "ProvisioningArtifactOutputKeys": [] | ||||||
| } | ||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,54 @@ | ||
| **Example 1: To list all constraints for a portfolio** | ||
|
|
||
| The following ``list-constraints-for-portfolio`` example lists all constraints for a portfolio. :: | ||
|
|
||
| aws servicecatalog list-constraints-for-portfolio \ | ||
| --portfolio-id port-y3fnkeslpxxxx | ||
|
|
||
| Output:: | ||
|
|
||
| { | ||
| "ConstraintDetails": [ | ||
| { | ||
| "ConstraintId": "cons-dgdyqdqrxxxxx", | ||
| "Type": "LAUNCH", | ||
| "Description": "Launch as local role TestLaunchRole", | ||
| "Owner": "123456789012", | ||
| "ProductId": "prod-j6pd3hf6xxxxx", | ||
| "PortfolioId": "port-y3fnkeslxxxxx" | ||
| }, | ||
| { | ||
| "ConstraintId": "cons-tzxjnj4l6xxxx", | ||
| "Type": "RESOURCE_UPDATE", | ||
| "Owner": "123456789012", | ||
| "ProductId": "prod-sphewkokxxxxx", | ||
| "PortfolioId": "port-y3fnkeslxxxxx" | ||
| } | ||
| ] | ||
| } | ||
|
|
||
|
|
||
| **Example 2: To list constraints on a product** | ||
|
|
||
| The following ``list-constraints-for-portfolio`` example lists constraints on a product. :: | ||
|
|
||
| aws servicecatalog list-constraints-for-portfolio \ | ||
| --portfolio-id port-y3fnkeslxxxxx \ | ||
| --product-id prod-j6pd3hf6xxxxx | ||
|
|
||
| Output:: | ||
|
|
||
| { | ||
| "ConstraintDetails": [ | ||
| { | ||
| "ConstraintId": "cons-dgdyqdqrxxxxx", | ||
| "Type": "LAUNCH", | ||
| "Description": "Launch as local role TestLaunchRole", | ||
| "Owner": "123456789012", | ||
| "ProductId": "prod-j6pd3hf6xxxxx", | ||
| "PortfolioId": "port-y3fnkeslxxxxx" | ||
| } | ||
| ] | ||
| } | ||
|
|
||
| For more information, see `Using AWS Service Catalog Constraints <https://docs.aws.amazon.com/servicecatalog/latest/adminguide/constraints.html>`__ in the *AWS Service Catalog User Guide*. |
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,23 @@ | ||||||
| **To list launch paths** | ||||||
|
|
||||||
| The following ``list-launch-paths`` example lists launch paths for a portfolio. :: | ||||||
|
|
||||||
| aws servicecatalog list-launch-paths \ | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
| --product-id prod-cfrfxmraxxxxx | ||||||
|
|
||||||
| Output:: | ||||||
|
|
||||||
| { | ||||||
| "LaunchPathSummaries": [ | ||||||
| { | ||||||
| "Id": "lpv3-y3fnkeslpxxxx", | ||||||
| "ConstraintSummaries": [ | ||||||
| { | ||||||
| "Type": "LAUNCH" | ||||||
| } | ||||||
| ], | ||||||
| "Tags": [], | ||||||
| "Name": "TestPort" | ||||||
| } | ||||||
| ] | ||||||
| } | ||||||
Uh oh!
There was an error while loading. Please reload this page.