WARP-Clash-API icon indicating copy to clipboard operation
WARP-Clash-API copied to clipboard

按照说明用docker安装了之后,无法成功运行,帮忙看看是什么原因。

Open sarsmark-git opened this issue 1 year ago • 2 comments

log的内容为:

FileNotFoundError: [Errno 2] No such file or directory: './config/cf-config.json' /usr/local/lib/python3.11/site-packages/tzlocal/unix.py:193: UserWarning: Can not find any timezone configuration, defaulting to UTC. warnings.warn("Can not find any timezone configuration, defaulting to UTC.") 2024-02-22 08:08:22,353 - INFO - Start scheduler Traceback (most recent call last): File "/app/app.py", line 82, in main() File "/app/app.py", line 54, in main from services.web_service import createApp File "/app/services/web_service.py", line 6, in from services.subscription import generateClashSubFile, generateWireguardSubFile, generateSurgeSubFile File "/app/services/subscription.py", line 18, in CF_CONFIG = json.load(open("./config/cf-config.json", "r", encoding="utf8")) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ FileNotFoundError: [Errno 2] No such file or directory: './config/cf-config.json'

sarsmark-git avatar Feb 22 '24 09:02 sarsmark-git

另外docker有没有通过cli安装,或者用docker-compose安装(不需要手动编译那种)的方式。谢谢。

sarsmark-git avatar Feb 22 '24 09:02 sarsmark-git

您可以使用下面的docker-compose文件来进行部署(记得预先在部署的文件夹内创建accountlogs子文件夹)

version: "3.8"
services:
  warp-clash:
    image: vvbbnn00/warp-clash-api:latest
    ports:
      - "21001:3000"
    env_file:
      - .env.local
    volumes:
      - ./account:/app/account
      - ./logs:/app/logs

vvbbnn00 avatar Feb 22 '24 18:02 vvbbnn00

您可以使用下面的docker-compose文件来进行部署(记得预先在部署的文件夹内创建accountlogs子文件夹)

version: "3.8"
services:
  warp-clash:
    image: vvbbnn00/warp-clash-api:latest
    ports:
      - "21001:3000"
    env_file:
      - .env.local
    volumes:
      - ./account:/app/account
      - ./logs:/app/logs

感谢,我修改了一下成功。谢谢

sarsmark-git avatar Feb 23 '24 01:02 sarsmark-git