mirror of
https://github.com/nestriness/nestri.git
synced 2025-12-11 00:05:36 +02:00
26 lines
555 B
TypeScript
26 lines
555 B
TypeScript
import { domain } from "./stage";
|
|
import { secret } from "./secrets";
|
|
import { database } from "./database";
|
|
|
|
const authStorage = new sst.cloudflare.Kv("AuthStorage");
|
|
|
|
export const auth = new sst.cloudflare.Worker("Auth", {
|
|
handler: "cloud/packages/functions/src/auth/index.ts",
|
|
domain: `auth.${domain}`,
|
|
url: true,
|
|
link: [
|
|
database,
|
|
authStorage,
|
|
secret.POLAR_API_KEY,
|
|
secret.DISCORD_CLIENT_ID,
|
|
secret.DISCORD_CLIENT_SECRET,
|
|
],
|
|
transform: {
|
|
worker: {
|
|
placement: {
|
|
mode: "smart",
|
|
},
|
|
},
|
|
},
|
|
});
|