mirror of
https://github.com/nestriness/nestri.git
synced 2025-12-12 16:55:37 +02:00
## Description <!-- Briefly describe the purpose and scope of your changes --> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Introduced a real-time Steam login flow using QR codes and server-sent events (SSE) for team creation and authentication. - Added Steam account and friend management, including secure credential storage and friend list synchronization. - Integrated Steam login endpoints into the API, enabling QR code-based login and automated team setup. - **Improvements** - Enhanced data security by implementing encrypted storage for sensitive tokens. - Updated database schema to support Steam accounts, teams, memberships, and social connections. - Refined type definitions and consolidated account-related information for improved consistency. - **Bug Fixes** - Fixed trade ban status representation for Steam accounts. - **Chores** - Removed legacy C# Steam authentication service and related configuration files. - Updated and cleaned up package dependencies and development tooling. - Streamlined type declaration files and resource definitions. - **Style** - Redesigned the team creation page UI with a modern, animated QR code login interface. - **Documentation** - Updated OpenAPI documentation for new Steam login endpoints. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
70 lines
1.6 KiB
TypeScript
70 lines
1.6 KiB
TypeScript
import { vpc } from "./vpc";
|
|
import { isPermanentStage } from "./stage";
|
|
import { steamEncryptionKey } from "./secret";
|
|
|
|
// TODO: Add a dev db to use, this will help with running zero locally... and testing it
|
|
export const postgres = new sst.aws.Aurora("Database", {
|
|
vpc,
|
|
engine: "postgres",
|
|
scaling: isPermanentStage
|
|
? undefined
|
|
: {
|
|
min: "0 ACU",
|
|
max: "1 ACU",
|
|
},
|
|
transform: {
|
|
clusterParameterGroup: {
|
|
parameters: [
|
|
{
|
|
name: "rds.logical_replication",
|
|
value: "1",
|
|
applyMethod: "pending-reboot",
|
|
},
|
|
{
|
|
name: "max_slot_wal_keep_size",
|
|
value: "10240",
|
|
applyMethod: "pending-reboot",
|
|
},
|
|
{
|
|
name: "rds.force_ssl",
|
|
value: "0",
|
|
applyMethod: "pending-reboot",
|
|
},
|
|
{
|
|
name: "max_connections",
|
|
value: "1000",
|
|
applyMethod: "pending-reboot",
|
|
},
|
|
],
|
|
},
|
|
},
|
|
});
|
|
|
|
|
|
new sst.x.DevCommand("Studio", {
|
|
link: [postgres, steamEncryptionKey],
|
|
dev: {
|
|
command: "bun db:dev studio",
|
|
directory: "packages/core",
|
|
autostart: true,
|
|
},
|
|
});
|
|
|
|
// const migrator = new sst.aws.Function("DatabaseMigrator", {
|
|
// handler: "packages/functions/src/migrator.handler",
|
|
// link: [postgres],
|
|
// copyFiles: [
|
|
// {
|
|
// from: "packages/core/migrations",
|
|
// to: "./migrations",
|
|
// },
|
|
// ],
|
|
// });
|
|
|
|
// if (!$dev) {
|
|
// new aws.lambda.Invocation("DatabaseMigratorInvocation", {
|
|
// input: Date.now().toString(),
|
|
// functionName: migrator.name,
|
|
// });
|
|
// }
|