S3 Object Storage

This commit is contained in:
Moritz Utcke
2025-03-18 18:25:24 -03:00
parent e01de6f03e
commit 8d73143932
13 changed files with 336 additions and 102 deletions

View File

@@ -1,4 +1,5 @@
import { Enums } from "#lib/client/prisma.js";
import { S3Client } from "@aws-sdk/client-s3";
export const API_ACCESS_TOKEN_COOKIE_NAME = "accessToken";
export const API_REFRESH_TOKEN_COOKIE_NAME = "refreshToken";
@@ -94,3 +95,13 @@ export const SERVICES: Record<
export const BASE_URI = process.env.NODE_ENV == "production" ? "https://online-energieausweis.org" : "http://localhost:3000";
export const LEX_OFFICE_API_KEY = process.env.NODE_ENV == "production" ? "iwQLCU_ZAq6bVV7hmR8RO8MiC8Q" : "znjmkmbA3Hbx9dC7wdKp7TnOf1pcRl_tCUwEBZys7bj-QRPG"
export const s3Client = new S3Client({
region: "eu-central-1",
endpoint: "https://s3-eu-central-1.ionoscloud.com",
credentials: {
accessKeyId: "EEAAAAHYzkBh2aRNC4OEVfqCRCviXoIZ3wm9UieAVCeLbWnJrQAAAAECGy6_AAAAAAIbLr9zLHhcZE7kGJngOPTFoODh",
secretAccessKey: "zlRI0jK+A8CIxir0QPdXNFUV+L9XjFTGyBvdUT1dvgY4FNlsOJgNJ+5xW5oShzmy",
},
forcePathStyle: true,
});