docker compose -f docker-compose.yaml up -d出现问题 #31

Closed
opened 2026-02-21 17:25:39 -05:00 by yindo · 8 comments
Owner

Originally created by @Hanliber on GitHub (May 16, 2023).

我按照官网要求,直接run官方的docker-compose.yaml。所有镜像下载后,启动容器时出现以下错误:
[+] Running 0/0
⠋ Container -weaviate-1 Creating 0.0s
⠋ Container -db-1 Creating 0.0s
⠋ Container -web-1 Creating 0.0s
⠋ Container -redis-1 Creating 0.0s
Error response from daemon: Invalid container name (-weaviate-1), only [a-zA-Z0-9][a-zA-Z0-9_.-] are allowed
为什么我的容器命名不规范(明明什么也没动),是yaml文件里的问题,还是我的问题,感谢各位能够给我解答

Originally created by @Hanliber on GitHub (May 16, 2023). 我按照官网要求,直接run官方的docker-compose.yaml。所有镜像下载后,启动容器时出现以下错误: [+] Running 0/0 ⠋ Container -weaviate-1 Creating 0.0s ⠋ Container -db-1 Creating 0.0s ⠋ Container -web-1 Creating 0.0s ⠋ Container -redis-1 Creating 0.0s Error response from daemon: Invalid container name (-weaviate-1), only [a-zA-Z0-9][a-zA-Z0-9_.-] are allowed 为什么我的容器命名不规范(明明什么也没动),是yaml文件里的问题,还是我的问题,感谢各位能够给我解答
yindo closed this issue 2026-02-21 17:25:39 -05:00
Author
Owner

@takatost commented on GitHub (May 16, 2023):

麻烦给一下执行的目录和代码 clone 后执行的命令

@takatost commented on GitHub (May 16, 2023): 麻烦给一下执行的目录和代码 clone 后执行的命令
Author
Owner

@Hanliber commented on GitHub (May 16, 2023):

我是直接把官网的docker-compose.yaml文件copy到我的ubuntu桌面上之后,直接在我的桌面上直接执行docker compose -f docker-compose.yaml up -d命令,是要另外创建一个文件夹吗?

--------------原始邮件--------------
发件人:"John Wang @.>;
发送时间:2023年5月16日(星期二) 晚上11:45
收件人:"langgenius/dify" @.
>;
抄送:"Hanliber @.>;"Author @.>;
主题:Re: [langgenius/dify] docker compose -f docker-compose.yaml up -d出现问题 (Issue #59)

麻烦给一下执行的目录和代码 clone 后执行的命令


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: @.***>

@Hanliber commented on GitHub (May 16, 2023): 我是直接把官网的docker-compose.yaml文件copy到我的ubuntu桌面上之后,直接在我的桌面上直接执行docker compose -f docker-compose.yaml up -d命令,是要另外创建一个文件夹吗? --------------原始邮件-------------- 发件人:"John Wang ***@***.***>; 发送时间:2023年5月16日(星期二) 晚上11:45 收件人:"langgenius/dify" ***@***.***>; 抄送:"Hanliber ***@***.***>;"Author ***@***.***>; 主题:Re: [langgenius/dify] docker compose -f docker-compose.yaml up -d出现问题 (Issue #59) ----------------------------------- 麻烦给一下执行的目录和代码 clone 后执行的命令 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: ***@***.***>
Author
Owner

@takatost commented on GitHub (May 16, 2023):

至少把 docker 这个文件夹拷出来,有需要的配置文件和 volume

@takatost commented on GitHub (May 16, 2023): 至少把 docker 这个文件夹拷出来,有需要的配置文件和 volume
Author
Owner

@Hanliber commented on GitHub (May 16, 2023):

我试试,谢谢你
--------------原始邮件--------------
发件人:"John Wang @.>;
发送时间:2023年5月17日(星期三) 凌晨0:22
收件人:"langgenius/dify" @.
>;
抄送:"Hanliber @.>;"Author @.>;
主题:Re: [langgenius/dify] docker compose -f docker-compose.yaml up -d出现问题 (Issue #59)

至少把 docker 这个文件夹拷出来,有需要的配置文件和 volume


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: @.***>

@Hanliber commented on GitHub (May 16, 2023): 我试试,谢谢你 --------------原始邮件-------------- 发件人:"John Wang ***@***.***>; 发送时间:2023年5月17日(星期三) 凌晨0:22 收件人:"langgenius/dify" ***@***.***>; 抄送:"Hanliber ***@***.***>;"Author ***@***.***>; 主题:Re: [langgenius/dify] docker compose -f docker-compose.yaml up -d出现问题 (Issue #59) ----------------------------------- 至少把 docker 这个文件夹拷出来,有需要的配置文件和 volume — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: ***@***.***>
Author
Owner

@Hanliber commented on GitHub (May 16, 2023):

至少把 docker 这个文件夹拷出来,有需要的配置文件和 volume
我在docker文件夹下执行了这个命令,有些容器成功了,但是nginx容器并没有成功,出现了以下错误:
⠿ Container docker-nginx-1 Starting 1.2s
Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: error during container init: error mounting "/var/lib/docker/nginx/nginx.conf" to rootfs at "/etc/nginx/nginx.conf": mount /var/lib/docker/nginx/nginx.conf:/etc/nginx/nginx.conf (via /proc/self/fd/6), flags: 0x5000: not a directory: unknown: Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type

请问这是个什么原因?

@Hanliber commented on GitHub (May 16, 2023): > 至少把 docker 这个文件夹拷出来,有需要的配置文件和 volume 我在docker文件夹下执行了这个命令,有些容器成功了,但是nginx容器并没有成功,出现了以下错误: ⠿ Container docker-nginx-1 Starting 1.2s Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: error during container init: error mounting "/var/lib/docker/nginx/nginx.conf" to rootfs at "/etc/nginx/nginx.conf": mount /var/lib/docker/nginx/nginx.conf:/etc/nginx/nginx.conf (via /proc/self/fd/6), flags: 0x5000: not a directory: unknown: Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type 请问这是个什么原因?
Author
Owner

@Hanliber commented on GitHub (May 16, 2023):

 我在docker文件夹下执行了这个命令,有些容器成功了,但是nginx容器并没有成功,出现了以下错误:
⠿ Container docker-nginx-1 Starting 1.2s
Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: error during container init: error mounting "/var/lib/docker/nginx/nginx.conf" to rootfs at "/etc/nginx/nginx.conf": mount /var/lib/docker/nginx/nginx.conf:/etc/nginx/nginx.conf (via /proc/self/fd/6), flags: 0x5000: not a directory: unknown: Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type
请问这是个什么原因?

------------------ Original ------------------
From: @.>;
Date:  Wed, May 17, 2023 00:22 AM
To: @.
>;
Cc: @.>; @.>;
Subject:  Re: [langgenius/dify] docker compose -f docker-compose.yaml up -d出现问题 (Issue #59)

 

至少把 docker 这个文件夹拷出来,有需要的配置文件和 volume


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: @.***>

@Hanliber commented on GitHub (May 16, 2023):  我在docker文件夹下执行了这个命令,有些容器成功了,但是nginx容器并没有成功,出现了以下错误: ⠿ Container docker-nginx-1 Starting 1.2s Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: error during container init: error mounting "/var/lib/docker/nginx/nginx.conf" to rootfs at "/etc/nginx/nginx.conf": mount /var/lib/docker/nginx/nginx.conf:/etc/nginx/nginx.conf (via /proc/self/fd/6), flags: 0x5000: not a directory: unknown: Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type 请问这是个什么原因? ------------------ Original ------------------ From: ***@***.***>; Date:  Wed, May 17, 2023 00:22 AM To: ***@***.***>; Cc: ***@***.***>; ***@***.***>; Subject:  Re: [langgenius/dify] docker compose -f docker-compose.yaml up -d出现问题 (Issue #59)   至少把 docker 这个文件夹拷出来,有需要的配置文件和 volume — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: ***@***.***>
Author
Owner

@takatost commented on GitHub (May 16, 2023):

docker 文件夹中所有的内容都复制了吗,推荐整个仓库都 clone 后,进入 docker 目录部署,单独复制不好定位问题

@takatost commented on GitHub (May 16, 2023): docker 文件夹中所有的内容都复制了吗,推荐整个仓库都 clone 后,进入 docker 目录部署,单独复制不好定位问题
Author
Owner

@Hanliber commented on GitHub (May 16, 2023):

太傻了我,我是在我的docker安装目录里操作的,没有直接git clone整个仓库。现在问题解决了,感谢感谢。

--------------原始邮件--------------
发件人:"John Wang @.>;
发送时间:2023年5月17日(星期三) 上午10:07
收件人:"langgenius/dify" @.
>;
抄送:"Hanliber @.>;"Author @.>;
主题:Re: [langgenius/dify] docker compose -f docker-compose.yaml up -d出现问题 (Issue #59)

docker 文件夹中所有的内容都复制了吗,推荐整个仓库都 clone 后,进入 docker 目录部署,单独复制不好定位问题


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: @.***>

@Hanliber commented on GitHub (May 16, 2023): 太傻了我,我是在我的docker安装目录里操作的,没有直接git clone整个仓库。现在问题解决了,感谢感谢。 --------------原始邮件-------------- 发件人:"John Wang ***@***.***>; 发送时间:2023年5月17日(星期三) 上午10:07 收件人:"langgenius/dify" ***@***.***>; 抄送:"Hanliber ***@***.***>;"Author ***@***.***>; 主题:Re: [langgenius/dify] docker compose -f docker-compose.yaml up -d出现问题 (Issue #59) ----------------------------------- docker 文件夹中所有的内容都复制了吗,推荐整个仓库都 clone 后,进入 docker 目录部署,单独复制不好定位问题 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: ***@***.***>
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#31