diff --git a/Dockerfile b/Dockerfile index 9dfaf33..76c7b1e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,6 +4,7 @@ WORKDIR /app COPY . /app -RUN pip install --no-cache -r requirements.txt +# 指定源, 如果后期源挂了, 更换个源就可以. +RUN pip install --no-cache -i https://pypi.mirrors.ustc.edu.cn/simple/ -r requirements.txt CMD [ "python", "main.py" ] \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 925fd95..aff40ff 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,10 +1,15 @@ -version: '1' -name: 'lx-music' +version: "3.8" services: - api: + lx: + container_name: lx-server build: . - restart: always ports: - "9763:9763" volumes: - .:/app + environment: + TZ: 'Asia/Shanghai' + restart: always +networks: + default: +