Skip to content

A demo for children's hospital, use it on wechat

Notifications You must be signed in to change notification settings

haobin12358/hospital

Repository files navigation

hospital

A demo for children's hospital, use it on wechat

  • python3.6

  • 依赖

    • 新增依赖
    pip freeze > requirments.txt
    • 导入依赖
    pip install -r requirments.txt
  • 环境变量

vim ~/.bashrc
export DXX_DB_HOST='ip地址'
export DXX_DB_NAME='数据库名字'
export DXX_DB_USER='数据库用户名'
export DXX_DB_PWD='数据库密码'

export DXXAPPID='appid'
export DXXAPPSECRET='appsecret'
source ~/.bashrc

数据库迁移

更改model后使用

  • 生成迁移文件
alembic revision --autogenerate -m 'add'
  • 执行
alembic upgrade head
  • 回滚
alembic downgrade 上个版本号 # 可在本次迁移文件头部中找到'Revises' 

启动和关闭

  • 启动
./start.sh start
  • 重启
./start.sh restart
  • 关闭
./start.sh stop

119测试服

  • 数据库迁移需要先进入容器,在任意目录下使用 ddd 可进入容器bash下

  • 容器外任意目录下使用 dss 可重启服务

  • redis

redis-server /usr/local/redis/redis.conf
  • supervisor
supervisord -c /opt/python_planet/supervisord.conf
  • nginx && mysql
nginx && service mysql start

日志

/tmp/planet/log*

错误码

405001 参数错误
405002 方法不支持
405003 无权限
405004 not found
405005 系统错误
405006 接口未注册
405007 未登录
405008 重复数据
405009 敬请期待
405010
405011 状态错误

About

A demo for children's hospital, use it on wechat

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages