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

[Feature Request]: Provide docker image for Mac with ARM #434

Closed
1 task done
yingfeng opened this issue Apr 18, 2024 · 14 comments
Closed
1 task done

[Feature Request]: Provide docker image for Mac with ARM #434

yingfeng opened this issue Apr 18, 2024 · 14 comments
Labels
good first issue Good for newcomers

Comments

@yingfeng
Copy link
Member

Is there an existing issue for the same feature request?

  • I have checked the existing issues.

Is your feature request related to a problem?

No response

Describe the feature you'd like

There are several builtin models depending on PyTorch, ONNXRuntime,...,etc, which requires extra works for migrating.

Describe implementation you've considered

No response

Documentation, adoption, use case

No response

Additional information

No response

@yingfeng yingfeng added the good first issue Good for newcomers label Apr 18, 2024
@yingfeng
Copy link
Member Author

@KevinHuSh pls give some instructions to build mac images.

@KevinHuSh
Copy link
Collaborator

ragflow/Dockerfile.scratch has every necessary steps to build an image.

@1of13
Copy link

1of13 commented Apr 21, 2024

Hi. I tried using Dockerfile.scratch and the image was not built successfully. Would you mind writing detailed instructions on how to set up on Mac with ARM?

@1of13
Copy link

1of13 commented Apr 22, 2024

The Dockerfile.scratch file has many issues. For example, it points to the wrong URL for Miniconda3. It should be something like this: https://repo.anaconda.com/miniconda/Miniconda3-py311_24.3.0-0-MacOSX-arm64.sh, instead of the "... latest-Linux-x86_64 ..." used in the script. The latest version of Miniconda3 uses Python3.12, and consequently, some of the libraries included in the requirements are incompatible, as they require Python3.11 at most.

@xbl916
Copy link

xbl916 commented Apr 25, 2024

I tried to run it on Oracle's ARM host and rebuild docker image. I removed some packages which isn't supported on ARM platform such as Aspose.Slides and N-card. Therefore, Some features won't work any more, for example, Powerpoint file isn't support any more. Updated requirements.txt and Dockerfile.scratch are attached.
requirements.txt
Dockerfile.scratch.txt

@zhengwu119
Copy link

I tried to run it on Oracle's ARM host and rebuild docker image. I removed some packages which isn't supported on ARM platform such as Aspose.Slides and N-card. Therefore, Some features won't work any more, for example, Powerpoint file isn't support any more. Updated requirements.txt and Dockerfile.scratch are attached. requirements.txt Dockerfile.scratch.txt

it works!

@qmy777
Copy link

qmy777 commented Jun 9, 2024

I tried to run it on Oracle's ARM host and rebuild docker image. I removed some packages which isn't supported on ARM platform such as Aspose.Slides and N-card. Therefore, Some features won't work any more, for example, Powerpoint file isn't support any more. Updated requirements.txt and Dockerfile.scratch are attached. requirements.txt Dockerfile.scratch.txt

Excuse me. How to run zhe docker image with the changed files?
I just known how to use docker compose run the program in the docker folder

@chminsc
Copy link

chminsc commented Jul 14, 2024

does it support mps on Mac M1 chip?

@FellowTraveler
Copy link

Having trouble running ragflow on M3 Silicon Mac or even building the docker:
docker build --no-cache -t infiniflow/ragflow:dev -f Dockerfile.arm .

Output:

Dockerfile.arm:7
--------------------
   6 |     COPY requirements_arm.txt /ragflow/requirements.txt
   7 | >>> RUN pip install -i https://mirrors.aliyun.com/pypi/simple/ --default-timeout=1000 -r requirements.txt &&\
   8 | >>> python -c "import nltk;nltk.download('punkt');nltk.download('wordnet')"
   9 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c pip install -i https://mirrors.aliyun.com/pypi/simple/ --default-timeout=1000 -r requirements.txt &&python -c \"import nltk;nltk.download('punkt');nltk.download('wordnet')\"" did not complete successfully: exit code: 1

View build details: docker-desktop://dashboard/build/desktop-linux/desktop-linux/fvay1k2wtt4fzbb2yijrj0r2t

@dorhunova
Copy link

Has the issue been resolved?

@yangboz
Copy link
Contributor

yangboz commented Aug 21, 2024

Having trouble running ragflow on M3 Silicon Mac or even building the docker: docker build --no-cache -t infiniflow/ragflow:dev -f Dockerfile.arm .

Output:

Dockerfile.arm:7
--------------------
   6 |     COPY requirements_arm.txt /ragflow/requirements.txt
   7 | >>> RUN pip install -i https://mirrors.aliyun.com/pypi/simple/ --default-timeout=1000 -r requirements.txt &&\
   8 | >>> python -c "import nltk;nltk.download('punkt');nltk.download('wordnet')"
   9 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c pip install -i https://mirrors.aliyun.com/pypi/simple/ --default-timeout=1000 -r requirements.txt &&python -c \"import nltk;nltk.download('punkt');nltk.download('wordnet')\"" did not complete successfully: exit code: 1

View build details: docker-desktop://dashboard/build/desktop-linux/desktop-linux/fvay1k2wtt4fzbb2yijrj0r2t

same here,
and

ERROR [linux/amd64 internal] load metadata for docker.io/library/python:3.11

any idea ?

KevinHuSh pushed a commit that referenced this issue Aug 28, 2024
Fix building on ARM architecture.

### What problem does this PR solve?

Fix building on ARM architecture.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)


### Related issues

- #2137
- #610
- #434
- #253
@yuzhichang
Copy link
Member

We've published multi-arch image ragflow:dev-slim. Here's how we do it: https://github.com/infiniflow/ragflow/blob/main/docs/guides/develop/build_docker_image.md

Halfknow pushed a commit to Halfknow/ragflow that referenced this issue Nov 11, 2024
Fix building on ARM architecture.

### What problem does this PR solve?

Fix building on ARM architecture.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)


### Related issues

- infiniflow#2137
- infiniflow#610
- infiniflow#434
- infiniflow#253
@peterzyk
Copy link

peterzyk commented Jan 9, 2025

我们已经发布了多架构镜像ragflow:dev-slim。具体操作如下:https: //github.com/infiniflow/ragflow/blob/main/docs/guides/develop/build_docker_image.md

这个链接失效了

@KevinHuSh
Copy link
Collaborator

Here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests