Skip to content

Commit

Permalink
fix: Allow env variables to overwrite config options
Browse files Browse the repository at this point in the history
  • Loading branch information
becem-gharbi committed Nov 14, 2023
1 parent dd839c0 commit 71f4003
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,15 @@ export default defineNuxtModule<ModuleOptions>({

nuxt.options.runtimeConfig = defu(nuxt.options.runtimeConfig, {
app: {},
s3: options,
s3: {
driver: options.driver,
fsBase: options.fsBase,
accessKeyId: options.accessKeyId,
secretAccessKey: options.secretAccessKey,
endpoint: options.endpoint,
region: options.region,
bucket: options.bucket
},
public: {
s3: {
accept: options.accept,
Expand Down

0 comments on commit 71f4003

Please sign in to comment.