pythonamazon-web-servicesboto3aws-service-catalog

AWS ServiceCatalog provision-product error


I am automating (python, boto3) the creation of products and their launch in service catalog from the command line. I create the product, grab the productId from the response. I then pull the launch path using list-launch-paths. When I finally get down to provisioning the product I receive an error:

An error occurred (ResourceNotFoundException) when calling the ProvisionProduct operation: Product prod-vfwmgz65lckke not found.

I switched over to using the aws cli and get the same error. However, I can provision the product from the AWS Console. Here is the command line I am using

aws servicecatalog provision-product --product-id="prod-vfwmgz65lckke" --provisioning-artifact-id="mytester" --provisioned-product-name="mytester" --path-id="lp-wkgbq4zcd74v6"

Here is the listing from search_products:

.....................................
.....................................
.....................................                                 
'ProductViewSummaries': [   {   'HasDefaultPath': False,
                                'Id': 'prodview-3u7zx4fbb4ekg',
                                'Name': 'my-test-server-13',
                                'Owner': 'Felicia Rosemond',
                                'ProductId': 'prod-vfwmgz65lckke',
                                'Type': 'CLOUD_FORMATION_TEMPLATE'},
 .................................
 .................................
 .................................

Any ideas on what I am missing?


Solution

  • I found the answer to my problem. I was missing the Provisioning Artifact Id, after including that the stack launched perfectly. It seems the error was a red herring.