mirror of
https://github.com/swissmakers/swiss-datashare.git
synced 2026-04-17 04:33:15 +02:00
chore: optimize prisma migration
This commit is contained in:
@@ -3,9 +3,9 @@ import * as crypto from "crypto";
|
||||
|
||||
const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
{
|
||||
id: 1,
|
||||
order: 0,
|
||||
key: "SETUP_FINISHED",
|
||||
description: "Whether the setup has been finished",
|
||||
description: "Status of the setup wizard",
|
||||
type: "boolean",
|
||||
value: "false",
|
||||
category: "internal",
|
||||
@@ -13,53 +13,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
locked: true,
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
key: "APP_URL",
|
||||
description: "On which URL Pingvin Share is available",
|
||||
type: "string",
|
||||
value: "http://localhost:3000",
|
||||
category: "general",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
key: "SHOW_HOME_PAGE",
|
||||
description: "Whether to show the home page",
|
||||
type: "boolean",
|
||||
value: "true",
|
||||
category: "general",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
key: "ALLOW_REGISTRATION",
|
||||
description: "Whether registration is allowed",
|
||||
type: "boolean",
|
||||
value: "true",
|
||||
category: "share",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
id: 5,
|
||||
key: "ALLOW_UNAUTHENTICATED_SHARES",
|
||||
description: "Whether unauthorized users can create shares",
|
||||
type: "boolean",
|
||||
value: "false",
|
||||
category: "share",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
id: 6,
|
||||
|
||||
key: "MAX_SHARE_SIZE",
|
||||
description: "Maximum share size in bytes",
|
||||
type: "number",
|
||||
value: "1073741824",
|
||||
category: "share",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
id: 7,
|
||||
order: 0,
|
||||
key: "JWT_SECRET",
|
||||
description: "Long random string used to sign JWT tokens",
|
||||
type: "string",
|
||||
@@ -68,7 +22,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
locked: true,
|
||||
},
|
||||
{
|
||||
id: 8,
|
||||
order: 0,
|
||||
key: "TOTP_SECRET",
|
||||
description: "A 16 byte random string used to generate TOTP secrets",
|
||||
type: "string",
|
||||
@@ -77,7 +31,54 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
locked: true,
|
||||
},
|
||||
{
|
||||
id: 9,
|
||||
order: 1,
|
||||
key: "APP_URL",
|
||||
description: "On which URL Pingvin Share is available",
|
||||
type: "string",
|
||||
value: "http://localhost:3000",
|
||||
category: "general",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
order: 2,
|
||||
key: "SHOW_HOME_PAGE",
|
||||
description: "Whether to show the home page",
|
||||
type: "boolean",
|
||||
value: "true",
|
||||
category: "general",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
order: 3,
|
||||
key: "ALLOW_REGISTRATION",
|
||||
description: "Whether registration is allowed",
|
||||
type: "boolean",
|
||||
value: "true",
|
||||
category: "share",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
order: 4,
|
||||
key: "ALLOW_UNAUTHENTICATED_SHARES",
|
||||
description: "Whether unauthorized users can create shares",
|
||||
type: "boolean",
|
||||
value: "false",
|
||||
category: "share",
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
order: 5,
|
||||
|
||||
key: "MAX_SHARE_SIZE",
|
||||
description: "Maximum share size in bytes",
|
||||
type: "number",
|
||||
value: "1073741824",
|
||||
category: "share",
|
||||
secret: false,
|
||||
},
|
||||
|
||||
{
|
||||
order: 6,
|
||||
key: "ENABLE_SHARE_EMAIL_RECIPIENTS",
|
||||
description:
|
||||
"Whether to allow emails to share recipients. Only enable this if you have enabled SMTP.",
|
||||
@@ -87,7 +88,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
id: 10,
|
||||
order: 7,
|
||||
key: "SHARE_RECEPIENTS_EMAIL_MESSAGE",
|
||||
description:
|
||||
"Message which gets sent to the share recipients. {creator} and {shareUrl} will be replaced with the creator's name and the share URL.",
|
||||
@@ -97,7 +98,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
category: "email",
|
||||
},
|
||||
{
|
||||
id: 11,
|
||||
order: 8,
|
||||
key: "SHARE_RECEPIENTS_EMAIL_SUBJECT",
|
||||
description:
|
||||
"Subject of the email which gets sent to the share recipients.",
|
||||
@@ -106,7 +107,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
category: "email",
|
||||
},
|
||||
{
|
||||
id: 12,
|
||||
order: 9,
|
||||
key: "REVERSE_SHARE_EMAIL_MESSAGE",
|
||||
description:
|
||||
"Message which gets sent when someone created a share with your reverse share link. {shareUrl} will be replaced with the creator's name and the share URL.",
|
||||
@@ -116,7 +117,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
category: "email",
|
||||
},
|
||||
{
|
||||
id: 13,
|
||||
order: 10,
|
||||
key: "REVERSE_SHARE_EMAIL_SUBJECT",
|
||||
description:
|
||||
"Subject of the email which gets sent when someone created a share with your reverse share link.",
|
||||
@@ -125,7 +126,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
category: "email",
|
||||
},
|
||||
{
|
||||
id: 14,
|
||||
order: 11,
|
||||
key: "SMTP_ENABLED",
|
||||
description:
|
||||
"Whether SMTP is enabled. Only set this to true if you entered the host, port, email, user and password of your SMTP server.",
|
||||
@@ -135,7 +136,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
secret: false,
|
||||
},
|
||||
{
|
||||
id: 15,
|
||||
order: 12,
|
||||
key: "SMTP_HOST",
|
||||
description: "Host of the SMTP server",
|
||||
type: "string",
|
||||
@@ -143,7 +144,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
category: "smtp",
|
||||
},
|
||||
{
|
||||
id: 16,
|
||||
order: 13,
|
||||
key: "SMTP_PORT",
|
||||
description: "Port of the SMTP server",
|
||||
type: "number",
|
||||
@@ -151,7 +152,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
category: "smtp",
|
||||
},
|
||||
{
|
||||
id: 17,
|
||||
order: 14,
|
||||
key: "SMTP_EMAIL",
|
||||
description: "Email address which the emails get sent from",
|
||||
type: "string",
|
||||
@@ -159,7 +160,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
category: "smtp",
|
||||
},
|
||||
{
|
||||
id: 18,
|
||||
order: 15,
|
||||
key: "SMTP_USERNAME",
|
||||
description: "Username of the SMTP server",
|
||||
type: "string",
|
||||
@@ -167,7 +168,7 @@ const configVariables: Prisma.ConfigCreateInput[] = [
|
||||
category: "smtp",
|
||||
},
|
||||
{
|
||||
id: 19,
|
||||
order: 16,
|
||||
key: "SMTP_PASSWORD",
|
||||
description: "Password of the SMTP server",
|
||||
type: "string",
|
||||
|
||||
Reference in New Issue
Block a user