⬆️ Upgrade pnpm, turbo, isolated-vm (#1609)
Closes https://github.com/baptisteArno/typebot.io/issues/1554
This commit is contained in:
@ -3,6 +3,8 @@ ENCRYPTION_SECRET=do+UspMmB/rewbX2K/rskFmtgGSSZ8Ta
|
|||||||
|
|
||||||
DATABASE_URL=postgresql://postgres:typebot@typebot-db:5432/typebot
|
DATABASE_URL=postgresql://postgres:typebot@typebot-db:5432/typebot
|
||||||
|
|
||||||
|
NODE_OPTIONS=--no-node-snapshot
|
||||||
|
|
||||||
NEXTAUTH_URL=
|
NEXTAUTH_URL=
|
||||||
NEXT_PUBLIC_VIEWER_URL=
|
NEXT_PUBLIC_VIEWER_URL=
|
||||||
|
|
||||||
|
1
.vscode/extensions.json
vendored
1
.vscode/extensions.json
vendored
@ -5,7 +5,6 @@
|
|||||||
"bradlc.vscode-tailwindcss",
|
"bradlc.vscode-tailwindcss",
|
||||||
"unifiedjs.vscode-mdx",
|
"unifiedjs.vscode-mdx",
|
||||||
"lokalise.i18n-ally",
|
"lokalise.i18n-ally",
|
||||||
"ms-playwright.playwright",
|
|
||||||
"Prisma.prisma"
|
"Prisma.prisma"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
FROM node:18-bullseye-slim AS base
|
FROM node:20-bullseye-slim AS base
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
ARG SCOPE
|
ARG SCOPE
|
||||||
ENV SCOPE=${SCOPE}
|
ENV SCOPE=${SCOPE}
|
||||||
@ -8,13 +8,13 @@ RUN apt-get -qy update \
|
|||||||
&& apt-get autoremove -yq \
|
&& apt-get autoremove -yq \
|
||||||
&& apt-get clean \
|
&& apt-get clean \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
RUN npm --global install pnpm@8
|
RUN npm --global install pnpm@9.5.0
|
||||||
|
|
||||||
FROM base AS pruner
|
FROM base AS pruner
|
||||||
RUN npm --global install turbo@1.11.3
|
RUN npm --global install turbo@2.0.5
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY . .
|
COPY . .
|
||||||
RUN turbo prune --scope=${SCOPE} --docker
|
RUN turbo prune ${SCOPE} --docker
|
||||||
|
|
||||||
FROM base AS builder
|
FROM base AS builder
|
||||||
RUN apt-get -qy update && apt-get -qy --no-install-recommends install openssl git python3 g++ build-essential
|
RUN apt-get -qy update && apt-get -qy --no-install-recommends install openssl git python3 g++ build-essential
|
||||||
|
@ -69,7 +69,7 @@
|
|||||||
"google-spreadsheet": "4.1.1",
|
"google-spreadsheet": "4.1.1",
|
||||||
"immer": "10.0.2",
|
"immer": "10.0.2",
|
||||||
"ioredis": "^5.4.1",
|
"ioredis": "^5.4.1",
|
||||||
"isolated-vm": "4.7.2",
|
"isolated-vm": "5.0.1",
|
||||||
"jsonwebtoken": "9.0.1",
|
"jsonwebtoken": "9.0.1",
|
||||||
"ky": "1.2.4",
|
"ky": "1.2.4",
|
||||||
"libphonenumber-js": "1.10.37",
|
"libphonenumber-js": "1.10.37",
|
||||||
|
@ -13,3 +13,5 @@ writeFileSync(
|
|||||||
'./openapi/builder.json',
|
'./openapi/builder.json',
|
||||||
JSON.stringify(openApiDocument, null, 2)
|
JSON.stringify(openApiDocument, null, 2)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
process.exit()
|
||||||
|
@ -1057,7 +1057,33 @@
|
|||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"message": {
|
"message": {
|
||||||
"type": "string",
|
"oneOf": [
|
||||||
|
{
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"enum": [
|
||||||
|
"text"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"text": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"attachedFileUrls": {
|
||||||
|
"type": "array",
|
||||||
|
"items": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"description": "Can only be provided if current input block is a text input block that allows attachments"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type",
|
||||||
|
"text"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
"description": "Only provide it if your flow starts with an input block and you'd like to directly provide an answer to it."
|
"description": "Only provide it if your flow starts with an input block and you'd like to directly provide an answer to it."
|
||||||
},
|
},
|
||||||
"isStreamEnabled": {
|
"isStreamEnabled": {
|
||||||
@ -1448,7 +1474,33 @@
|
|||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties": {
|
||||||
"message": {
|
"message": {
|
||||||
"type": "string"
|
"oneOf": [
|
||||||
|
{
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"enum": [
|
||||||
|
"text"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"text": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"attachedFileUrls": {
|
||||||
|
"type": "array",
|
||||||
|
"items": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"description": "Can only be provided if current input block is a text input block that allows attachments"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type",
|
||||||
|
"text"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"textBubbleContentFormat": {
|
"textBubbleContentFormat": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
@ -1792,7 +1844,33 @@
|
|||||||
"default": false
|
"default": false
|
||||||
},
|
},
|
||||||
"message": {
|
"message": {
|
||||||
"type": "string"
|
"oneOf": [
|
||||||
|
{
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"type": {
|
||||||
|
"type": "string",
|
||||||
|
"enum": [
|
||||||
|
"text"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"text": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"attachedFileUrls": {
|
||||||
|
"type": "array",
|
||||||
|
"items": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"description": "Can only be provided if current input block is a text input block that allows attachments"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"required": [
|
||||||
|
"type",
|
||||||
|
"text"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"isOnlyRegistering": {
|
"isOnlyRegistering": {
|
||||||
"type": "boolean",
|
"type": "boolean",
|
||||||
@ -2915,6 +2993,9 @@
|
|||||||
"properties": {
|
"properties": {
|
||||||
"id": {
|
"id": {
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
},
|
||||||
|
"caption": {
|
||||||
|
"type": "string"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"required": [
|
"required": [
|
||||||
@ -2949,6 +3030,9 @@
|
|||||||
"properties": {
|
"properties": {
|
||||||
"id": {
|
"id": {
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
},
|
||||||
|
"caption": {
|
||||||
|
"type": "string"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"required": [
|
"required": [
|
||||||
@ -3017,6 +3101,9 @@
|
|||||||
"properties": {
|
"properties": {
|
||||||
"id": {
|
"id": {
|
||||||
"type": "string"
|
"type": "string"
|
||||||
|
},
|
||||||
|
"caption": {
|
||||||
|
"type": "string"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"required": [
|
"required": [
|
||||||
@ -5872,6 +5959,25 @@
|
|||||||
},
|
},
|
||||||
"isLong": {
|
"isLong": {
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
|
},
|
||||||
|
"attachments": {
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"isEnabled": {
|
||||||
|
"type": "boolean"
|
||||||
|
},
|
||||||
|
"saveVariableId": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"visibility": {
|
||||||
|
"type": "string",
|
||||||
|
"enum": [
|
||||||
|
"Auto",
|
||||||
|
"Public",
|
||||||
|
"Private"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -12,4 +12,4 @@
|
|||||||
"tsx": "4.6.2",
|
"tsx": "4.6.2",
|
||||||
"dotenv-cli": "7.4.1"
|
"dotenv-cli": "7.4.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -22,7 +22,7 @@ title: Manual
|
|||||||
## Requirements
|
## Requirements
|
||||||
|
|
||||||
- A PostgresDB database hosted somewhere. [Supabase](https://supabase.com/) offer great free options. But you can also setup your own database on your server.
|
- A PostgresDB database hosted somewhere. [Supabase](https://supabase.com/) offer great free options. But you can also setup your own database on your server.
|
||||||
- A server with Node.js 14+, Nginx, and PM2 installed.
|
- A server with Node.js 20+, Nginx, and PM2 installed.
|
||||||
- Experience deploying Next.js applications with PM2. Check out [this guide](https://www.coderrocketfuel.com/article/how-to-deploy-a-next-js-website-to-a-digital-ocean-server/) for more information.
|
- Experience deploying Next.js applications with PM2. Check out [this guide](https://www.coderrocketfuel.com/article/how-to-deploy-a-next-js-website-to-a-digital-ocean-server/) for more information.
|
||||||
|
|
||||||
## Getting Started
|
## Getting Started
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
"cors": "2.8.5",
|
"cors": "2.8.5",
|
||||||
"google-spreadsheet": "4.1.1",
|
"google-spreadsheet": "4.1.1",
|
||||||
"got": "12.6.0",
|
"got": "12.6.0",
|
||||||
"isolated-vm": "4.7.2",
|
"isolated-vm": "5.0.1",
|
||||||
"ky": "1.2.4",
|
"ky": "1.2.4",
|
||||||
"next": "14.1.0",
|
"next": "14.1.0",
|
||||||
"nextjs-cors": "2.1.2",
|
"nextjs-cors": "2.1.2",
|
||||||
|
@ -10,3 +10,5 @@ const openApiDocument = generateOpenApiDocument(appRouter, {
|
|||||||
})
|
})
|
||||||
|
|
||||||
writeFileSync('./openapi/viewer.json', JSON.stringify(openApiDocument, null, 2))
|
writeFileSync('./openapi/viewer.json', JSON.stringify(openApiDocument, null, 2))
|
||||||
|
|
||||||
|
process.exit()
|
||||||
|
@ -35,12 +35,12 @@
|
|||||||
"cz-emoji": "1.3.2-canary.2",
|
"cz-emoji": "1.3.2-canary.2",
|
||||||
"husky": "8.0.3",
|
"husky": "8.0.3",
|
||||||
"prettier": "2.8.8",
|
"prettier": "2.8.8",
|
||||||
"turbo": "1.11.3"
|
"turbo": "2.0.5"
|
||||||
},
|
},
|
||||||
"config": {
|
"config": {
|
||||||
"commitizen": {
|
"commitizen": {
|
||||||
"path": "node_modules/cz-emoji"
|
"path": "node_modules/cz-emoji"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"packageManager": "pnpm@8.15.4"
|
"packageManager": "pnpm@9.5.0"
|
||||||
}
|
}
|
||||||
|
@ -33,7 +33,7 @@
|
|||||||
"openai": "4.47.1",
|
"openai": "4.47.1",
|
||||||
"qs": "6.11.2",
|
"qs": "6.11.2",
|
||||||
"stripe": "12.13.0",
|
"stripe": "12.13.0",
|
||||||
"isolated-vm": "4.7.2"
|
"isolated-vm": "5.0.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@typebot.io/forge": "workspace:*",
|
"@typebot.io/forge": "workspace:*",
|
||||||
|
@ -22,6 +22,9 @@ const indexConfig = {
|
|||||||
format: 'es',
|
format: 'es',
|
||||||
},
|
},
|
||||||
onwarn,
|
onwarn,
|
||||||
|
watch: {
|
||||||
|
clearScreen: false,
|
||||||
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
resolve({ extensions }),
|
resolve({ extensions }),
|
||||||
babel({
|
babel({
|
||||||
|
@ -18,6 +18,9 @@ const indexConfig = {
|
|||||||
format: 'es',
|
format: 'es',
|
||||||
},
|
},
|
||||||
external: ['next/dynamic', 'react', 'react/jsx-runtime'],
|
external: ['next/dynamic', 'react', 'react/jsx-runtime'],
|
||||||
|
watch: {
|
||||||
|
clearScreen: false,
|
||||||
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
resolve({ extensions }),
|
resolve({ extensions }),
|
||||||
babel({
|
babel({
|
||||||
|
@ -18,6 +18,9 @@ const indexConfig = {
|
|||||||
format: 'es',
|
format: 'es',
|
||||||
},
|
},
|
||||||
external: ['react', 'react/jsx-runtime'],
|
external: ['react', 'react/jsx-runtime'],
|
||||||
|
watch: {
|
||||||
|
clearScreen: false,
|
||||||
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
resolve({ extensions }),
|
resolve({ extensions }),
|
||||||
babel({
|
babel({
|
||||||
|
@ -6,6 +6,6 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@typebot.io/lib": "workspace:*",
|
"@typebot.io/lib": "workspace:*",
|
||||||
"@typebot.io/tsconfig": "workspace:*",
|
"@typebot.io/tsconfig": "workspace:*",
|
||||||
"isolated-vm": "4.7.2"
|
"isolated-vm": "5.0.1"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
25232
pnpm-lock.yaml
generated
25232
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
20
turbo.json
20
turbo.json
@ -1,7 +1,9 @@
|
|||||||
{
|
{
|
||||||
"baseBranch": "origin/main",
|
"$schema": "https://turbo.build/schema.json",
|
||||||
"globalDotEnv": [".env"],
|
"ui": "stream",
|
||||||
"pipeline": {
|
"globalDependencies": [".env"],
|
||||||
|
"globalEnv": ["DATABASE_URL", "SKIP_ENV_CHECK"],
|
||||||
|
"tasks": {
|
||||||
"lint": {
|
"lint": {
|
||||||
"outputs": []
|
"outputs": []
|
||||||
},
|
},
|
||||||
@ -14,9 +16,12 @@
|
|||||||
"@typebot.io/prisma#db:generate",
|
"@typebot.io/prisma#db:generate",
|
||||||
"@typebot.io/prisma#db:push"
|
"@typebot.io/prisma#db:push"
|
||||||
],
|
],
|
||||||
"cache": false
|
"cache": false,
|
||||||
|
"persistent": true
|
||||||
},
|
},
|
||||||
"build": {
|
"build": {
|
||||||
|
"passThroughEnv": ["ENCRYPTION_SECRET"],
|
||||||
|
"env": ["VERCEL_*", "NEXTAUTH_URL", "SENTRY_*"],
|
||||||
"dependsOn": ["^build", "@typebot.io/prisma#db:generate"],
|
"dependsOn": ["^build", "@typebot.io/prisma#db:generate"],
|
||||||
"outputs": [
|
"outputs": [
|
||||||
".next/**",
|
".next/**",
|
||||||
@ -25,13 +30,13 @@
|
|||||||
"build/**",
|
"build/**",
|
||||||
"public/__ENV.js"
|
"public/__ENV.js"
|
||||||
],
|
],
|
||||||
"outputMode": "new-only",
|
"inputs": ["$TURBO_DEFAULT$", ".env"],
|
||||||
"dotEnv": [".env"]
|
"outputLogs": "new-only"
|
||||||
},
|
},
|
||||||
"docs#build": {
|
"docs#build": {
|
||||||
"dependsOn": ["api:generate"],
|
"dependsOn": ["api:generate"],
|
||||||
"outputs": ["build/**"],
|
"outputs": ["build/**"],
|
||||||
"outputMode": "new-only"
|
"outputLogs": "new-only"
|
||||||
},
|
},
|
||||||
"api:generate": {
|
"api:generate": {
|
||||||
"dependsOn": ["bot-engine#build", "@typebot.io/prisma#db:generate"],
|
"dependsOn": ["bot-engine#build", "@typebot.io/prisma#db:generate"],
|
||||||
@ -48,6 +53,7 @@
|
|||||||
"cache": false
|
"cache": false
|
||||||
},
|
},
|
||||||
"checkAndReportChatsUsage": {
|
"checkAndReportChatsUsage": {
|
||||||
|
"env": ["STRIPE_*", "NEXTAUTH_URL", "SMTP_*"],
|
||||||
"dependsOn": ["@typebot.io/prisma#db:generate"],
|
"dependsOn": ["@typebot.io/prisma#db:generate"],
|
||||||
"cache": false
|
"cache": false
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user