Skip to content

johanchow/clothing-try-on

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

安装环境

  1. 先清空当前虚拟环境;再创建虚拟环境,然后安装依赖包
rm -rf venv/
python -m venv venv
pip install -r requirements.txt
  1. 查看已安装包的版本
pip list | grep numpy

本地开发

  1. 设置环境变量,便于flask找到入口文件
export FLASK_APP=app/main.py
flask run # 用flask启动
uwsgi --ini uwsgi-dev.ini # 使用uwsgi启动,更接近容器里情况

编译

# 进入到项目根目录
cp ../.env . # 复制.env文件到当前目录
docker build -t clothing-try-on .
# 如果磁盘空间不够: 删除未使用的镜像、容器和卷
docker system prune -a --volumes

启动运行

docker stop clothing-try-on-container # 停止容器
docker rm clothing-try-on-container # 删除旧容器
docker run -d -p 8080:80 --name clothing-try-on-container --env-file .env clothing-try-on

登录到容器里

docker exec -it clothing-try-on-container /bin/bash

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published