QuivrHQ / quivr

Opiniated RAG for integrating GenAI in your apps 🧠 Focus on your product rather than the RAG. Easy integration in existing products with customisation! Any LLM: GPT4, Groq, Llama. Any Vectorstore: PGVector, Faiss. Any Files. Anyway you want.
https://core.quivr.com
Other
36.79k stars 3.6k forks source link

[Bug]: ERROR [frontend deps 1/5] RUN apk add --no-cache libc6-compat python3 make g++ #3033

Closed jasonyang-ytl closed 1 week ago

jasonyang-ytl commented 3 months ago

What happened?

Error while spawning docker image

Relevant log output

WARN[0000] /home/jasonyang/quivr/docker-compose.yml: the attribute `version` is obsolete, it will be ignored, please remove it to avoid potential confusion
[+] Building 11.9s (9/21)                                                                                                                                                                                                    docker:default
 => [frontend internal] load build definition from Dockerfile                                                                                                                                                                          0.0s
 => => transferring dockerfile: 2.90kB                                                                                                                                                                                                 0.0s
 => [frontend internal] load metadata for docker.io/library/node:18.19.0-alpine                                                                                                                                                        1.6s
 => [frontend internal] load .dockerignore                                                                                                                                                                                             0.0s
 => => transferring context: 340B                                                                                                                                                                                                      0.0s
 => CACHED [frontend base 1/1] FROM docker.io/library/node:18.19.0-alpine@sha256:0085670310d2879621f96a4216c893f92e2ded827e9e6ef8437672e1bd72f437                                                                                      0.0s
 => [frontend internal] load build context                                                                                                                                                                                             0.1s
 => => transferring context: 71.83kB                                                                                                                                                                                                   0.0s
 => CACHED [frontend builder 1/4] WORKDIR /app                                                                                                                                                                                         0.0s
 => CACHED [frontend runner 2/8] RUN addgroup --system --gid 1001 nodejs                                                                                                                                                               0.0s
 => CACHED [frontend runner 3/8] RUN adduser --system --uid 1001 nextjs                                                                                                                                                                0.0s
 => ERROR [frontend deps 1/5] RUN apk add --no-cache libc6-compat python3 make g++                                                                                                                                                    10.3s
------
 > [frontend deps 1/5] RUN apk add --no-cache libc6-compat python3 make g++:
0.248 fetch https://dl-cdn.alpinelinux.org/alpine/v3.19/main/x86_64/APKINDEX.tar.gz
5.254 WARNING: fetching https://dl-cdn.alpinelinux.org/alpine/v3.19/main: temporary error (try again later)
5.254 fetch https://dl-cdn.alpinelinux.org/alpine/v3.19/community/x86_64/APKINDEX.tar.gz
10.26 WARNING: fetching https://dl-cdn.alpinelinux.org/alpine/v3.19/community: temporary error (try again later)
10.26 ERROR: unable to select packages:
10.26   g++ (no such package):
10.26     required by: world[g++]
10.26   libc6-compat (no such package):
10.26     required by: world[libc6-compat]
10.26   make (no such package):
10.26     required by: world[make]
10.26   python3 (no such package):
10.26     required by: world[python3]
------
failed to solve: process "/bin/sh -c apk add --no-cache libc6-compat python3 make g++" did not complete successfully: exit code: 4

Twitter / LinkedIn details

No response

linear[bot] commented 3 months ago

CORE-156 [Bug]: ERROR [frontend deps 1/5] RUN apk add --no-cache libc6-compat python3 make g++

dosubot[bot] commented 3 months ago

Hello, @jasonyang-ytl! I'm here to help you with any bugs, questions, or contributions you may have while waiting for a human maintainer. Let's tackle this together!

To resolve the error when running apk add --no-cache libc6-compat python3 make g++ in the Docker build process, you can ensure that the libc6-compat package is available in the Alpine repositories. The provided Dockerfile already includes the necessary command to add these packages:

RUN apk add --no-cache libc6-compat python3 make g++

If you are encountering errors, it might be due to a temporary issue with the Alpine package repositories or a network issue. Here are a few steps you can take to troubleshoot and resolve the issue:

  1. Update the package index: Ensure that the package index is up-to-date before installing the packages.
  2. Check network connectivity: Ensure that your Docker build process has network access to the Alpine package repositories.
  3. Specify a different Alpine version: Sometimes, using a different version of Alpine can resolve package availability issues.

Here is an updated snippet of the Dockerfile with the package index update and additional steps to ensure Python is properly set up:

FROM node:18.13.0-alpine

# Install Python and essential build tools
RUN apk add --update --no-cache libc6-compat python3 make g++ && ln -sf python3 /usr/bin/python
RUN python3 -m ensurepip
RUN pip3 install --no-cache --upgrade pip setuptools

# Create the directory on the node image where our Next.js app will live
RUN mkdir -p /app

# Set /app as the working directory
WORKDIR /app

# Copy package.json and yarn.lock to the /app working directory
COPY package*.json yarn.lock ./

# Install dependencies in /app
RUN yarn install --network-timeout 1000000

# Copy the rest of our Next.js folder into /app
COPY . .

# Ensure port 3000 is accessible to our system
EXPOSE 3000

# Run yarn dev, as we would via the command line 
CMD ["yarn", "dev"]

If the issue persists, you may need to check the specific error message for more details or try using a different base image that includes the required dependencies [1][2].

To continue talking to Dosu, mention @dosu.

StanGirard commented 3 months ago

Hello, this seems like a network issue. Could you please retry ?

github-actions[bot] commented 1 week ago

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.