Skip to content

Commit

Permalink
fix(config): Detected S3 credentials now works
Browse files Browse the repository at this point in the history
detected-s3-creds: Previously it was using a logical OR to check whether the `STORE_ACCESS_KEY` and `STORE_SECRET_KEY` were required (i.e. either the credentials are not detected OR the credentials were not already configured), but now uses a logical AND instead.
  • Loading branch information
tecc committed Nov 18, 2022
1 parent 6fc2f7d commit 2431c96
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libs/server/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,11 @@ export function loadConfig() {
store.detectCredentials ??= true;
store.accessKey = env.getEnvRaw(
'STORE_ACCESS_KEY',
!store.detectCredentials || !store.accessKey
!store.detectCredentials && !store.accessKey
) ?? store.accessKey;
store.secretKey = env.getEnvRaw(
'STORE_SECRET_KEY',
!store.detectCredentials || !store.secretKey
!store.detectCredentials && !store.secretKey
) ?? store.secretKey;
store.bucket = env.getEnvRaw(
'STORE_BUCKET',
Expand Down

0 comments on commit 2431c96

Please sign in to comment.