Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pages/aws/config.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ If you want to look at a full example, you can check [the full example](/aws/con

### Opt out of default poweredByHeader

By default Next.js will add the [`x-powered-by`]((https://nextjs.org/docs/app/api-reference/next-config-js/poweredByHeader)) header. OpenNext will also add a header `x-opennext`. To opt-out of this, open `next.config.js` and disable the poweredByHeader property in the configuration:
By default Next.js will add the [`x-powered-by`](https://nextjs.org/docs/app/api-reference/config/next-config-js/poweredByHeader) header. OpenNext will also add a header `x-opennext`. To opt-out of this, open `next.config.js` and disable the poweredByHeader property in the configuration:
```ts
module.exports = {
poweredByHeader: false,
Expand Down
20 changes: 6 additions & 14 deletions pages/aws/config/simple_example.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,7 @@ Here you can find the most common `open-next.config.ts` file examples that you c

## Streaming with lambda

<Callout type="warning" emoji="⚠️">
AWS has a bunch of different implementations of streaming in production. You
might be lucky and have a fully working one, but you might have one that are
not suitable for production. Be aware that there is nothing to do to prevent
AWS from breaking your deployment (same code and same runtime might break from
one day to another) [Thread
1](https://discord.com/channels/983865673656705025/1230482660913184800)
[Thread
2](https://discord.com/channels/983865673656705025/1249368592558985247) <br />{' '}
<br /> On some AWS accounts the response can hang if the body is empty. There
is a workaround for that on OpenNext 3.0.3+, setting environment variable
`OPEN_NEXT_FORCE_NON_EMPTY_RESPONSE` to `"true"`. This will ensure that the
stream body is not empty. <br /> <br />
<Callout type="info" emoji="ℹ️">
If you have an issue with streaming send a message on [discord](https://discord.com/channels/1283128968140161065/1286094576788177059)
and contact AWS support to let them know of the issue.
</Callout>
Expand All @@ -34,6 +22,10 @@ const config = {
export default config;
```

Be aware that there has been some issues in the past with AWS breaking streaming from one day to another. This seems to be resolved now.
[Thread 1](https://discord.com/channels/983865673656705025/1230482660913184800)
[Thread 2](https://discord.com/channels/983865673656705025/1249368592558985247)

## Splitting the server

```ts
Expand Down Expand Up @@ -105,7 +97,7 @@ export default config;
## Bundle for a classic Node server (With function splitting)

<Callout type="info" emoji="i">
This is not implemented in sst yet. You'll have to use your own IAC construct to deploy this.
This is not implemented in SST yet. You'll have to use your own IAC construct to deploy this.

Be aware that this uses the exact same system for ISR/SSG as the default lambda setup. So it will have to have all the proper permissions and env variable to interact with S3, DynamoDB and SQS (Or whatever you override it with). You can see [here](/aws/inner_workings/components/server/node#special-overrides) for more details
</Callout>
Expand Down
4 changes: 2 additions & 2 deletions pages/aws/get_started.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For more information, check out the SST docs: https://sst.dev/docs/start/aws/nex

### Other Frameworks

The OpenNext community has contributed deployment options for a few other frameworks.
The OpenNext community has contributed deployment options for a few other frameworks. Many of these are no longer maintained, so newer versions of OpenNext may not be supported.

- CDK (TS): https://github.com/jetbridge/cdk-nextjs
- CDK (TS, Java, Go, Py, .NET): https://github.com/datasprayio/open-next-cdk
Expand All @@ -24,7 +24,7 @@ The OpenNext community has contributed deployment options for a few other framew
To use these, you'll need to run the following inside your Next.js app.

```bash
$ npx open-next@latest build
$ npx @opennextjs/aws@latest build
```

If you are using OpenNext to deploy using a framework that is not listed here, please let us know so we can add it to the list.