Skip to content
This repository has been archived by the owner on Jan 28, 2025. It is now read-only.

Autogenerate Serverless Config #418

Merged
merged 15 commits into from
May 31, 2020

Conversation

danielcondemarin
Copy link
Contributor

@danielcondemarin danielcondemarin commented May 28, 2020

Currently it is required that users specify "serverless" target in their config or "experimental-serverless-trace".

This PR makes serverless-next.js autogenerate the config. by creating a temporary next.config.js overriding the target specified with "serverless" or "experimental-serverless-trace". This will allow in future to transparently swap out which target is used behind the scenes without users even noticing.

To opt-in for "experimental-serverless-trace" simply:

# serverless.yml
component: serverless-next.js@version
inputs: 
 useServerlessTraceTarget: true

@danielcondemarin danielcondemarin merged commit 0f9a176 into master May 31, 2020
@danielcondemarin danielcondemarin deleted the auto-generate-serverless-config branch May 31, 2020 19:55
sclaughl pushed a commit to sclaughl/serverless-next.js that referenced this pull request Jul 16, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant