aws / aws-toolkit-visual-studio

AWS Toolkit for Visual Studio - a plugin to interact with AWS
https://aws.amazon.com/visualstudio/
Apache License 2.0
107 stars 29 forks source link

unable to publish asp.net application to AWS using AWS Toolkit in Visual Studio #347

Closed 20220255 closed 1 year ago

20220255 commented 1 year ago

Describe the bug

urrent credentials could not be used to assume 'arn:aws:iam::000069705177:role/cdk-hnb659fds-deploy-role-000069705177-us-east-1', but are for the right account. Proceeding anyway. [0%] start: Building 5d54540b162b1810871eb421c0392d2537dbea050eab03963e99e44ec74b6106:000069705177-us-east-1 [0%] start: Building 4f23eb4f0d5e18fd0845a073ea7bfd18ded2b8f8a2fec90283f37a42f28bd906:000069705177-us-east-1 [50%] success: Built 5d54540b162b1810871eb421c0392d2537dbea050eab03963e99e44ec74b6106:000069705177-us-east-1 [100%] success: Built 4f23eb4f0d5e18fd0845a073ea7bfd18ded2b8f8a2fec90283f37a42f28bd906:000069705177-us-east-1

SnapwashApp: assets built

SnapwashApp: deploying... current credentials could not be used to assume 'arn:aws:iam::000069705177:role/cdk-hnb659fds-deploy-role-000069705177-us-east-1', but are for the right account. Proceeding anyway. [0%] start: Publishing 5d54540b162b1810871eb421c0392d2537dbea050eab03963e99e44ec74b6106:000069705177-us-east-1 [0%] start: Publishing 4f23eb4f0d5e18fd0845a073ea7bfd18ded2b8f8a2fec90283f37a42f28bd906:000069705177-us-east-1 current credentials could not be used to assume 'arn:aws:iam::000069705177:role/cdk-hnb659fds-file-publishing-role-000069705177-us-east-1', but are for the right account. Proceeding anyway. current credentials could not be used to assume 'arn:aws:iam::000069705177:role/cdk-hnb659fds-file-publishing-role-000069705177-us-east-1', but are for the right account. Proceeding anyway. [50%] fail: No bucket named 'cdk-hnb659fds-assets-000069705177-us-east-1'. Is account 000069705177 bootstrapped? [100%] fail: No bucket named 'cdk-hnb659fds-assets-000069705177-us-east-1'. Is account 000069705177 bootstrapped?

❌ SnapwashApp failed: Error: Failed to publish one or more assets. See the error messages above for more information. at publishAssets (C:\Users\admin.aws-dotnet-deploy\node_modules\aws-cdk\lib\util\asset-publishing.ts:53:11) at processTicksAndRejections (node:internal/process/task_queues:95:5) at CloudFormationDeployments.publishStackAssets (C:\Users\admin.aws-dotnet-deploy\node_modules\aws-cdk\lib\api\cloudformation-deployments.ts:530:7) at CloudFormationDeployments.deployStack (C:\Users\admin.aws-dotnet-deploy\node_modules\aws-cdk\lib\api\cloudformation-deployments.ts:380:7) at deployStack2 (C:\Users\admin.aws-dotnet-deploy\node_modules\aws-cdk\lib\cdk-toolkit.ts:240:24) at C:\Users\admin.aws-dotnet-deploy\node_modules\aws-cdk\lib\deploy.ts:39:11 at run (C:\Users\admin.aws-dotnet-deploy\node_modules\p-queue\dist\index.js:163:29)

❌ Deployment failed: Error: Stack Deployments Failed: Error: Failed to publish one or more assets. See the error messages above for more information. at deployStacks (C:\Users\admin.aws-dotnet-deploy\node_modules\aws-cdk\lib\deploy.ts:61:11) at processTicksAndRejections (node:internal/process/task_queues:95:5) at CdkToolkit.deploy (C:\Users\admin.aws-dotnet-deploy\node_modules\aws-cdk\lib\cdk-toolkit.ts:312:7) at initCommandLine (C:\Users\admin.aws-dotnet-deploy\node_modules\aws-cdk\lib\cli.ts:349:12)

Stack Deployments Failed: Error: Failed to publish one or more assets. See the error messages above for more information.

SnapwashApp could not be published as ASP.NET Core App to AWS Elastic Beanstalk on Windows: We had an issue deploying your application to AWS. Check the deployment output for more details. Deployment took 44.1s. Snapwash failed to publish to AWS.

To Reproduce

Expected behavior Should be able to publish the app since it is working on local server

Screenshots

Computer (please complete the following information):

Additional context

ashovlin commented 1 year ago

The publish experience uses AWS CDK, which relies on a bootstrap CloudFormation stack that deploys the resources such as an S3 bucket, ECR repository, IAM roles, etc. that will be used while deploying your applications.

This looks like it's unable to access the S3 bucket that's part of the bootstrap stack while deploying your application,

Some possibilities:

github-actions[bot] commented 1 year ago

This issue is missing required information and will be closed in 7 days. To keep the issue open, leave a comment.