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

add: s3-lite override for imageLoader #750

Merged
merged 8 commits into from
Feb 21, 2025

Conversation

sommeeeer
Copy link
Contributor

@sommeeeer sommeeeer commented Feb 21, 2025

  • Uses aws4fetch
  • New env variable BUCKET_REGION. Falls back to AWS_REGION ?? AWS_DEFAULT_REGION if undefined. This way no change in IAC is needed for most users.

Add an open-next.config.ts with these options:

import type { OpenNextConfig } from '@opennextjs/aws/types/open-next';
const config = {
  default: {},
   imageOptimization: {
     loader: 's3-lite',
   },
} satisfies OpenNextConfig;

export default config;

Copy link

changeset-bot bot commented Feb 21, 2025

🦋 Changeset detected

Latest commit: aa76b0c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@opennextjs/aws Patch
app-pages-router Patch
app-router Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

pkg-pr-new bot commented Feb 21, 2025

Open in Stackblitz

pnpm add https://pkg.pr.new/@opennextjs/aws@750

commit: aa76b0c

@sommeeeer
Copy link
Contributor Author

thanks for review Nico. didn't know about AWS_DEFAULT_REGION. i'll update the changeset aswell in another commit

@sommeeeer sommeeeer requested a review from conico974 February 21, 2025 08:57
@sommeeeer sommeeeer requested a review from conico974 February 21, 2025 10:12
Copy link
Contributor

@conico974 conico974 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM Thanks

@conico974 conico974 merged commit c4b0a78 into opennextjs:main Feb 21, 2025
3 checks passed
@github-actions github-actions bot mentioned this pull request Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants