Closed franciscopaniskaseker closed 1 year ago
What version of docker-compose
are you running?
docker-compose -v
Locally I'm on Docker Compose version v2.10.2
For the yarn command you are running the setup
command in the root package.json
. So the expanded command is yarn run setup
while in the project root.
Additionally, are you sure you installed yarn
and not cmdtest
See how to fix: https://github.com/yarnpkg/yarn/issues/3708#issuecomment-317358958
root@ip-172-31-47-141:~# docker-compose -v
docker-compose version 1.29.2, build unknown
however, at the same time, the plugin version is:
docker-compose-plugin is already the newest version (2.21.0-1~ubuntu.22.04~jammy).
For the yarn command you are running the setup command in the root package.json. So the expanded command is yarn run setup while in the project root.
root@:~/anything-llm# yarn run setup
00h00m00s 0/0: : ERROR: [Errno 2] No such file or directory: 'run'
Additionally, are you sure you installed yarn and not cmdtest
Not sure how to test if is cmdtest or not. what I did, then:
apt remove yarn cmdtest
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
sudo apt update && sudo apt install yarn
these are official steps from yarn official site.
then I tried:
root@:~/anything-llm# yarn run setup
yarn run v1.22.19
error anything-llm@0.2.0: The engine "node" is incompatible with this module. Expected version ">=18". Got "12.22.9"
error Commands cannot run with an incompatible environment.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
So seems that cmdtest was installed. Now i need to upgrade the node version:
apt install npm
npm install -g n
n latest
root@:~/anything-llm# node --version
v21.1.0
Now the command
yarn run setup
executed as expected. Now I build the docker image again and seems that worked. I will try to use.
I encountered the same issue, what was your exact fix?
I receive this error when I attempt to build the docker
ERROR: The Compose file './docker-compose.yml' is invalid because: 'project-name' does not match any of the regexes: '^x-'
You might be seeing this error because you're using the wrong Compose file version. Either specify a supported version (e.g "2.2" or "3.3") and place your service definitions under the services
key, or omit the version
key and place your service definitions at the root of the file to use version 1.
For more on the Compose file format versions, see https://docs.docker.com/compose/compose-file/
@bryceartstew I was going to close this thread, but in general - that issue sounds like your install of docker-compose is not able to read the specific YAML we have defined. So I would start there if the Dockerfile cannot even be parsed!
@bryceartstew i removed that line and did:
export COMPOSE_PROJECT_NAME=anythingllm
After correctly image build process (according official steps), we still can not use the anythingllm:
For now the dev will stop to try anythingllm. Too much problems. we expect something easier from docker image. thank you all.
For what it's worth, it's because you have incorrect permissions on the database file in the host machine and docker cannot write to it from its process. If that cant be debugged I'm sorry and we will work to improve our docker install
I am following this doc: https://github.com/Mintplex-Labs/anything-llm/blob/master/docker/HOW_TO_USE_DOCKER.md
about the step:
yarn setup
Not sure if is asking to setup yarn or to execute yarn setup in the root directory. i did both:Then I tried to build:
i did the clone today, so the first lines of composer files are:
So i removed the line "name" and did:
and the bulding process started to work.
Seems that the docker situation is something related with composer version, I am not sure. What I am sure is folowing the official steps to build the image will not work (at least with recent docker composer version).