Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: can not use docker-compose -f docker-compose.local.yml up to build Quivr on cloud server #1803

Closed
BabaSarf opened this issue Dec 4, 2023 · 3 comments
Labels
area: backend Related to backend functionality or under the /backend directory area: frontend Related to frontend functionality or under the /frontend directory bug Something isn't working Stale

Comments

@BabaSarf
Copy link

BabaSarf commented Dec 4, 2023

What happened?

I am no longer able to install Quivr on cloud server with docker-compose -f docker-compose.local.yml up using online supabase.com
here is the docker file

version: "3"

services:
traefik:
image: traefik:v2.7
container_name: traefik
command:
- "--api.insecure=true"
- "--providers.docker=true"
- "--providers.docker.exposedbydefault=false"
- "--entrypoints.web.address=:80"
- "--entrypoints.websecure.address=:443"
- "--certificatesresolvers.myresolver.acme.tlschallenge=true"
- "--certificatesresolvers.myresolver.acme.email=${EMAIL}"
- "--certificatesresolvers.myresolver.acme.storage=/letsencrypt/acme.json"
ports:
- "80:80"
- "443:443"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
- "./letsencrypt:/letsencrypt"
restart: always
env_file:
- .env

frontend:
env_file:
- ./frontend/.env
build:
context: frontend
dockerfile: Dockerfile
container_name: web
restart: always
labels:
- "traefik.enable=true"
- "traefik.http.routers.frontend.rule=Host(${DOMAIN_NAME})"
- "traefik.http.routers.frontend.entrypoints=websecure"
- "traefik.http.routers.frontend.tls.certresolver=myresolver"
depends_on:
- traefik

backend-core:
env_file:
- ./backend/.env
build:
context: backend
dockerfile: Dockerfile
container_name: backend-core
restart: always
volumes:
- ./backend/:/code/
depends_on:
- redis
- worker
- beat
- traefik
labels:
- "traefik.enable=true"
- "traefik.http.routers.backend-core.rule=Host(${API_DOMAIN_NAME})"
- "traefik.http.routers.backend-core.entrypoints=websecure"
- "traefik.http.routers.backend-core.tls.certresolver=myresolver"
- "traefik.http.services.backend-core.loadbalancer.server.port=5050"

redis:
image: redis:latest
container_name: redis
restart: always

worker:
env_file:
- ./backend/.env
build:
context: backend
dockerfile: Dockerfile
container_name: worker
command: celery -A celery_worker worker -l info
restart: always
depends_on:
- redis

beat:
env_file:
- ./backend/.env
build:
context: backend
dockerfile: Dockerfile
container_name: beat
command: celery -A celery_worker beat -l info
restart: always
depends_on:
- redis

flower:
env_file:
- ./backend/.env
build:
context: backend
dockerfile: Dockerfile
container_name: flower
command: celery -A celery_worker flower -l info --port=5555
restart: always
depends_on:
- redis
- worker
- beat
labels:
- "traefik.enable=true"
- "traefik.http.routers.flower.rule=Host(flower.${API_DOMAIN_NAME})"
- "traefik.http.routers.flower.entrypoints=websecure"
- "traefik.http.routers.flower.tls.certresolver=myresolver"
- "traefik.http.services.flower.loadbalancer.server.port=5555"

Relevant log output

[frontend builder 4/4] RUN yarn build:
0.554 yarn run v1.22.19
0.590 $ next build
1.243 - info Loaded env from /app/.env
1.436 Attention: Next.js now collects completely anonymous telemetry regarding usage.
1.436 This information is used to shape Next.js' roadmap and prioritize features.
1.437 You can learn more, including how to opt-out if you'd not like to participate in this anonymous program, by visiting the following URL:
1.437 https://nextjs.org/telemetry
1.437 
1.566 - info Creating an optimized production build...
82.95 - info Compiled successfully
82.96 - info Linting and checking validity of types...
134.0 
134.0 ./app/(auth)/login/hooks/useLogin.ts
134.0 18:6  Warning: React Hook useEffect has a missing dependency: 'track'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/App.tsx
134.0 27:6  Warning: React Hook useEffect has missing dependencies: 'fetchAllBrains', 'fetchDefaultBrain', and 'fetchPublicPrompts'. Either include them or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/brains-management/[brainId]/components/BrainManagementTabs/components/KnowledgeOrSecretsTab/hooks/useKnowledge.ts
134.0 13:36  Warning: Forbidden non-null assertion.  @typescript-eslint/no-non-null-assertion
134.0 14:47  Warning: Forbidden non-null assertion.  @typescript-eslint/no-non-null-assertion
134.0 
134.0 ./app/brains-management/[brainId]/components/BrainManagementTabs/components/SettingsTab/components/PublicPrompts/hooks/usePublicPrompts.ts
134.0 20:6  Warning: React Hook useEffect has a missing dependency: 'getPublicPrompts'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/brains-management/[brainId]/components/BrainManagementTabs/components/SettingsTab/hooks/usePrompt.ts
134.0 60:6  Warning: React Hook useEffect has a missing dependency: 'fetchPrompt'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 158:11  Warning: Caution: `axios` also has a named export `isAxiosError`. Check if you meant to write `import {isAxiosError} from 'axios'` instead.  import/no-named-as-default-member
134.0 
134.0 ./app/brains-management/[brainId]/components/BrainManagementTabs/components/SettingsTab/hooks/useSettingsTab.ts
134.0 56:15  Warning: The ref value 'formRef.current' will likely have changed by the time this effect cleanup function runs. If this ref points to a node rendered by React, copy 'formRef.current' to a variable inside the effect, and use that variable in the cleanup function.  react-hooks/exhaustive-deps
134.0 58:6  Warning: React Hook useEffect has a missing dependency: 'handleSubmit'. Either include it or remove the dependency array. Mutable values like 'formRef.current' aren't valid dependencies because mutating them doesn't re-render the component.  react-hooks/exhaustive-deps
134.0 71:11  Warning: Caution: `axios` also has a named export `isAxiosError`. Check if you meant to write `import {isAxiosError} from 'axios'` instead.  import/no-named-as-default-member
134.0 119:11  Warning: Caution: `axios` also has a named export `isAxiosError`. Check if you meant to write `import {isAxiosError} from 'axios'` instead.  import/no-named-as-default-member
134.0 
134.0 ./app/brains-management/[brainId]/components/BrainManagementTabs/hooks/useBrainFetcher.ts
134.0 31:32  Warning: Forbidden non-null assertion.  @typescript-eslint/no-non-null-assertion
134.0 38:34  Warning: Forbidden non-null assertion.  @typescript-eslint/no-non-null-assertion
134.0 
134.0 ./app/chat/[chatId]/components/ActionsBar/components/ChatInput/components/ChatEditor/components/Editor/hooks/useCreateEditorState.ts
134.0 1:8  Warning: Using exported name 'Document' as identifier for default export.  import/no-named-as-default
134.0 2:8  Warning: Using exported name 'HardBreak' as identifier for default export.  import/no-named-as-default
134.0 3:8  Warning: Using exported name 'Paragraph' as identifier for default export.  import/no-named-as-default
134.0 4:8  Warning: Using exported name 'Placeholder' as identifier for default export.  import/no-named-as-default
134.0 5:8  Warning: Using exported name 'Text' as identifier for default export.  import/no-named-as-default
134.0 
134.0 ./app/chat/[chatId]/components/ActionsBar/components/ChatInput/components/ConfigModal/hooks/useConfigModal.ts
134.0 46:6  Warning: React Hook useEffect has a missing dependency: 'setValue'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/chat/[chatId]/components/ActionsBar/components/ChatInput/components/OnboardingQuestions/components/OnboardingQuestion/hooks/useOnboardingQuestion.ts
134.0 59:6  Warning: React Hook useEffect has a missing dependency: 'addQuestionAndAnswerToChat'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 77:6  Warning: React Hook useEffect has missing dependencies: 'chatId' and 'updateStreamingHistory'. Either include them or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/chat/[chatId]/components/ChatDialogueArea/components/ChatDialogue/hooks/useChatDialogue.ts
134.0 16:26  Warning: React Hook useCallback received a function whose dependencies are unknown. Pass an inline function instead.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/chat/components/ChatsList/hooks/useChatNotificationsSync.ts
134.0 56:6  Warning: React Hook useEffect has a missing dependency: 'setNotifications'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 74:6  Warning: React Hook useEffect has missing dependencies: 'getChatItems', 'setMessages', 'setNotifications', and 'setShouldDisplayFeedCard'. Either include them or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/chat/components/ChatsList/hooks/useChatsList.ts
134.0 39:6  Warning: React Hook useEffect has a missing dependency: 'setAllChats'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/chat/components/NotificationBanner/hooks/useNotificationBanner.tsx
134.0 40:6  Warning: React Hook useEffect has a missing dependency: 'notificationBanner'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./app/invitation/[brainId]/hooks/useInvitation.ts
134.0 46:13  Warning: Caution: `axios` also has a named export `isAxiosError`. Check if you meant to write `import {isAxiosError} from 'axios'` instead.  import/no-named-as-default-member
134.0 63:6  Warning: React Hook useEffect has missing dependencies: 'getInvitation', 'publish', 'router', and 't'. Either include them or remove the dependency array.  react-hooks/exhaustive-deps
134.0 78:11  Warning: Caution: `axios` also has a named export `isAxiosError`. Check if you meant to write `import {isAxiosError} from 'axios'` instead.  import/no-named-as-default-member
134.0 110:11  Warning: Caution: `axios` also has a named export `isAxiosError`. Check if you meant to write `import {isAxiosError} from 'axios'` instead.  import/no-named-as-default-member
134.0 
134.0 ./lib/components/AddBrainModal/components/AddBrainConfig/hooks/useAddBrainConfig.ts
134.0 153:11  Warning: Caution: `axios` also has a named export `isAxiosError`. Check if you meant to write `import {isAxiosError} from 'axios'` instead.  import/no-named-as-default-member
134.0 
134.0 ./lib/components/BrainUsers/hooks/useBrainUsers.ts
134.0 37:6  Warning: React Hook useEffect has a missing dependency: 'fetchBrainUsers'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./lib/components/UserToInvite.tsx
134.0 36:6  Warning: React Hook useEffect has missing dependencies: 'onChange' and 'roleAssignation'. Either include them or remove the dependency array. If 'onChange' changes too often, find the parent component that defines it and wrap that definition in useCallback.  react-hooks/exhaustive-deps
134.0 
134.0 ./lib/context/BrainProvider/hooks/useBrainProvider.ts
134.0 87:5  Warning: React Hook useCallback has a missing dependency: 't'. Either include it or remove the dependency array.  react-hooks/exhaustive-deps
134.0 
134.0 ./lib/hooks/useShareBrain.ts
134.0 84:11  Warning: Caution: `axios` also has a named export `isAxiosError`. Check if you meant to write `import {isAxiosError} from 'axios'` instead.  import/no-named-as-default-member
134.0 
134.0 info  - Need to disable some ESLint rules? Learn more here: https://nextjs.org/docs/basic-features/eslint#disabling-rules
134.0 - info Collecting page data...
161.7 - info Generating static pages (0/11)
161.8 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.8     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.8     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.8     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.8     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.8     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.8     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.8 
161.8 Error occurred prerendering page "/brains-management/library". Read more: https://nextjs.org/docs/messages/prerender-error
161.8 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.8     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.8     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.8     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.8     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.8     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.8     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.8 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.8     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.8     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.8     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.8     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.8     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.8     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.9 
161.9 Error occurred prerendering page "/brains-management". Read more: https://nextjs.org/docs/messages/prerender-error
161.9 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.9     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.9     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.9     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.9     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.9     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.9     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.9 - info Generating static pages (2/11)
161.9 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.9     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.9     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.9     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.9     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.9     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.9     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.9 
161.9 Error occurred prerendering page "/chat". Read more: https://nextjs.org/docs/messages/prerender-error
161.9 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.9     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.9     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.9     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.9     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.9     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.9     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.9 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.9     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.9     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.9     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.9     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.9     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.9     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.9 
161.9 Error occurred prerendering page "/contact". Read more: https://nextjs.org/docs/messages/prerender-error
161.9 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.9     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.9     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.9     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.9     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.9     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.9     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.9 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.9     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.9     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.9     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.9     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.9     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.9     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.9 
161.9 Error occurred prerendering page "/user". Read more: https://nextjs.org/docs/messages/prerender-error
161.9 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.9     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.9     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.9     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.9     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.9     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.9     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
161.9 - info Generating static pages (5/11)
161.9 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
161.9     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
161.9     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
161.9     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
161.9     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
161.9     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
161.9     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
162.0 
162.0 Error occurred prerendering page "/login". Read more: https://nextjs.org/docs/messages/prerender-error
162.0 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
162.0     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
162.0     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
162.0     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
162.0     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
162.0     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
162.0     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
162.0 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
162.0     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
162.0     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
162.0     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
162.0     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
162.0     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
162.0     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
162.0 
162.0 Error occurred prerendering page "/". Read more: https://nextjs.org/docs/messages/prerender-error
162.0 Error: either NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY env variables or supabaseUrl and supabaseKey are required!
162.0     at createServerComponentSupabaseClient (/app/.next/server/chunks/191.js:40732:15)
162.0     at RootLayout (/app/.next/server/chunks/264.js:1938:66)
162.0     at preloadComponent (/app/node_modules/next/dist/server/app-render/preload-component.js:23:22)
162.0     at /app/node_modules/next/dist/server/app-render/app-render.js:615:101
162.0     at async createComponentTree (/app/node_modules/next/dist/server/app-render/app-render.js:615:29)
162.0     at async /app/node_modules/next/dist/server/app-render/app-render.js:836:64
163.1 - info Generating static pages (8/11)
163.5 - info Generating static pages (11/11)
163.5 
163.5 > Export encountered errors on following paths:
163.5   /(auth)/login/page: /login
163.5   /(home)/page: /
163.5   /brains-management/library/page: /brains-management/library
163.5   /brains-management/page: /brains-management
163.5   /chat/page: /chat
163.5   /contact/page: /contact
163.5   /user/page: /user
163.6 error Command failed with exit code 1.
163.6 info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
------
failed to solve: process "/bin/sh -c yarn build" did not complete successfully: exit code: 1

Twitter / LinkedIn details

No response

@BabaSarf BabaSarf added the bug Something isn't working label Dec 4, 2023
Copy link

dosubot bot commented Dec 4, 2023

🤖

Hello @BabaSarf,

Nice to see you again! I hope you've been doing well. Let's take a look at this together.

Based on the error you're encountering, it seems like the NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY environment variables or supabaseUrl and supabaseKey are not correctly set in your environment file.

In the Quivr repository, there are similar solved issues that might help you:

  1. [Bug]: installation does not succeed
  2. [Issue] Install error
  3. Need guidance/explaination on SUPABASE envs

The common solution in these issues is to ensure that you have correctly updated the backend/.env and frontend/.env files with the correct variables. This includes your supabase_service_key, JWT_SECRET_KEY, and NEXT_PUBLIC_BACKEND_URL.

To resolve your issue, you need to ensure that these variables are correctly set in your environment file. The .env.example file in the Quivr repository contains these variables:

NEXT_PUBLIC_SUPABASE_URL=http://localhost:8000
NEXT_PUBLIC_SUPABASE_ANON_KEY=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyAgCiAgICAicm9sZSI6ICJhbm9uIiwKICAgICJpc3MiOiAic3VwYWJhc2UtZGVtbyIsCiAgICAiaWF0IjogMTY0MTc2OTIwMCwKICAgICJleHAiOiAxNzk5NTM1NjAwCn0.dc_X5iR_VP_qT0zsiyj_I_OZ2T9FtRU2BBNWN8Bu4GE

You need to replace http://localhost:8000 and the provided key with your actual Supabase URL and anonymous key. If you are deploying on a cloud server, your Supabase URL will not be localhost.

After updating these values, save the file as .env (not .env.example) in the root directory of your project. Docker will then use these environment variables during the build process.

If you are still encountering the error, ensure that your Docker environment is correctly loading the .env file. If you are using docker-compose, your .env file should be in the same directory as your docker-compose.yml file.

Regarding the Dockerfile, it starts from a base image of Python 3.11.6-slim-bullseye, installs the necessary dependencies, sets the working directory to /code, copies the requirements.txt file into the /code directory, upgrades pip to the latest version, installs the Python dependencies listed in requirements.txt with a timeout of 200 seconds, conditionally installs debugpy if DEV_MODE is set to "true", copies the rest of the application into the /code directory, exposes port 5050 to the system, and finally, runs the command to start the Uvicorn server with 6 workers on port 5050.

I hope this helps! If you have any other questions or need further clarification, feel free to ask.

Sources


This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.

Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.

If you want to continue the conversation, start your reply with @dosu-bot.

@dosubot dosubot bot added area: backend Related to backend functionality or under the /backend directory area: frontend Related to frontend functionality or under the /frontend directory labels Dec 4, 2023
@ardab
Copy link

ardab commented Dec 15, 2023

Where can we find the docker-compose.local.yml mentioned in the documentation? It's doesn't seem to be in the repo anymore

Copy link
Contributor

Thanks for your contributions, we'll be closing this issue as it has gone stale. Feel free to reopen if you'd like to continue the discussion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: backend Related to backend functionality or under the /backend directory area: frontend Related to frontend functionality or under the /frontend directory bug Something isn't working Stale
Projects
None yet
Development

No branches or pull requests

2 participants