update
This commit is contained in:
parent
11815eb985
commit
3547ab677c
@ -12,6 +12,15 @@ RUN apt-get update && apt-get install -y \
|
||||
# 复制项目文件
|
||||
COPY . /app/
|
||||
|
||||
# 创建虚拟环境
|
||||
RUN python -m venv venv
|
||||
|
||||
# 激活虚拟环境
|
||||
RUN source venv/bin/activate
|
||||
|
||||
# 安装setuptools
|
||||
RUN pip install setuptools
|
||||
|
||||
# 安装Python依赖
|
||||
RUN pip install -r requirements.txt
|
||||
|
||||
|
||||
@ -19,8 +19,8 @@ from cryptoai.utils.config_loader import ConfigLoader
|
||||
def main():
|
||||
try:
|
||||
print("程序启动")
|
||||
# 设置每个整点运行一次
|
||||
schedule.every().hour.do(CryptoAgent().start_agent)
|
||||
# 设置每个4小时运行一次
|
||||
schedule.every(4).hours.do(CryptoAgent().start_agent)
|
||||
|
||||
# 启动定时任务
|
||||
while True:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user