- pgSchema "mesh" with 4 tables isolating the peer mesh domain - Enums: visibility, transport, tier, role - audit_log is metadata-only (E2E encryption enforced at broker/client) - Cascade on mesh delete, soft-delete via archivedAt/revokedAt Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
35 lines
978 B
TypeScript
35 lines
978 B
TypeScript
/* eslint-disable turbo/no-undeclared-env-vars */
|
|
/* eslint-disable @typescript-eslint/no-unsafe-assignment */
|
|
/* eslint-disable @typescript-eslint/no-unsafe-argument */
|
|
import { defineEnv } from "envin";
|
|
import * as z from "zod";
|
|
|
|
import { envConfig } from "@turbostarter/shared/constants";
|
|
|
|
import type { Preset } from "envin/types";
|
|
|
|
export const preset = {
|
|
id: "posthog",
|
|
clientPrefix: "VITE_",
|
|
client: {
|
|
VITE_POSTHOG_KEY: z.string(),
|
|
VITE_POSTHOG_HOST: z
|
|
.string()
|
|
.optional()
|
|
.default("https://us.i.posthog.com"),
|
|
},
|
|
} as const satisfies Preset;
|
|
|
|
export const env = defineEnv({
|
|
...envConfig,
|
|
...preset,
|
|
env: {
|
|
VITE_POSTHOG_KEY: import.meta.env.VITE_POSTHOG_KEY,
|
|
VITE_POSTHOG_HOST: import.meta.env.VITE_POSTHOG_HOST,
|
|
},
|
|
skip:
|
|
(!!import.meta.env.SKIP_ENV_VALIDATION &&
|
|
["1", "true"].includes(import.meta.env.SKIP_ENV_VALIDATION)) ||
|
|
["lint", "postinstall"].includes(import.meta.env.npm_lifecycle_event),
|
|
});
|