Skip to content
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

(aws-cdk/aws-amplify): (Add Platform property to amplify.App) #24076

Closed
1 of 2 tasks
kevinold opened this issue Feb 8, 2023 · 3 comments · Fixed by #26861
Closed
1 of 2 tasks

(aws-cdk/aws-amplify): (Add Platform property to amplify.App) #24076

kevinold opened this issue Feb 8, 2023 · 3 comments · Fixed by #26861
Labels
@aws-cdk/aws-amplify Related to AWS Amplify effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2

Comments

@kevinold
Copy link

kevinold commented Feb 8, 2023

Describe the feature

Amplify accepts a Platform property via CloudFormation, but this is not accessible via the CDK.

Use Case

I am looking to deploy single-page applications (SPAs) and server-rendered applications (SSR) to Amplify via CDK.

The Platform defaults to "WEB" if not set, and deploying an SSR application via the CDK, I need a way to set the Platform to "WEB_COMPUTE".

Proposed Solution

Add a platform property to the AppProps for amplify.App.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.63.2

Environment details (OS name and version, etc.)

MacOS Monterey 12.6.2

@kevinold kevinold added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Feb 8, 2023
@github-actions github-actions bot added the @aws-cdk/aws-amplify Related to AWS Amplify label Feb 8, 2023
kevinold added a commit to kevinold/aws-cdk that referenced this issue Feb 8, 2023
Adds AppPlatforms enum for WEB, WEB_COMPUTE or WEB_DYNAMIC
Adds platform property to AppProps
Passes platform property to declared Amplify app

fixes aws#24076
kevinold added a commit to kevinold/aws-cdk that referenced this issue Feb 8, 2023
Adds AppPlatforms enum for WEB, WEB_COMPUTE or WEB_DYNAMIC
Adds platform property to AppProps
Passes platform property to declared Amplify app

fixes aws#24076
@khushail khushail added p2 effort/small Small work item – less than a day of effort and removed needs-triage This issue or PR still needs to be triaged. labels Feb 8, 2023
kevinold added a commit to kevinold/aws-cdk that referenced this issue Feb 8, 2023
Adds AppPlatforms enum for WEB, WEB_COMPUTE or WEB_DYNAMIC
Adds platform property to AppProps
Passes platform property to declared Amplify app

fixes aws#24076
@kevinold
Copy link
Author

kevinold commented Feb 9, 2023

PR for this feature #23818

@peterwoodworth
Copy link
Contributor

Thanks again for the issue and PR kevinold, the new PR for this issue is here #23818

@mergify mergify bot closed this as completed in #26861 Aug 25, 2023
mergify bot pushed a commit that referenced this issue Aug 25, 2023
### Problem:
The Amplify App L2 construct does not support the ability for customers to configure a SSR app without reaching down into the lower level L1.

### Solution:
Expose the `platform` field used to set SSG vs SSR hosted applications. Do not expose `WEB_DYNAMIC` as SSRv1 is on the deprecation path.

### Testing Done:
* `yarn build+test`
* added new tests for `platform` field
* updated snapshots for new default value

Closes #24076 and #23325

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
@github-actions
Copy link

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-amplify Related to AWS Amplify effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2
Projects
None yet
3 participants