当前位置:网站首页>宝塔的安装和flask项目部署
宝塔的安装和flask项目部署
2022-07-06 09:05:00 【东方】
部署flask
我按这种方式宝塔python项目管理器安装的时候报错,提醒我需要虚拟环境。
然后听闻远方大佬给出了解决方法
要进入虚拟环境然后在启动
在这之前你需要先 cd 命令 进入项目的目录下。
source venv/bin/activate
python app.py
和大佬的思路不谋而合,那么我猜想应该是必须要虚拟环境(来隔离包冲突)。
直接运行远方大佬给我的命令行就行了。
群里有一本flask的书籍应该也有写到。
但其实不知道为什么每过一段时间 都会有数据库错误。
重启一下再进行访问就可以了。
查了一些相关资料,应该是 数据库连接的问题。
数据库报错的话 ,每次都要进行重启服务。
安装参考
运行完指令之后:
云服务器端口放行
必须要放行 8888 端口
如需完整使用宝塔的所有功能 你还需要放行如下端口:
建防火墙
编辑防火墙规则,增加以下端口:8888,888,80,443,20,21
修改外网防火墙为新建的防火墙
安装后的使用
http://117.50.181.88:8888/74e59d27
username: l9qfim2z
password: a1ccf6f5
忘记密码:
边栏推荐
- Control the operation of the test module through the panel in canoe (Advanced)
- Hugo blog graphical writing tool -- QT practice
- 嵌入式开发比单片机要难很多?谈谈单片机和嵌入式开发设计经历
- June brush question 02 - string
- 机械工程师和电气工程师方向哪个前景比较好?
- Listen to my advice and learn according to this embedded curriculum content and curriculum system
- tn-c为何不可用2p断路器?
- Download address of canoe, download and activation of can demo 16, and appendix of all canoe software versions
- 五月刷题01——数组
- Cooperative development in embedded -- function pointer
猜你喜欢

Compilation of libwebsocket

Contest3145 - the 37th game of 2021 freshman individual training match_ C: Tour guide

【深度学习】语义分割:论文阅读:(CVPR 2022) MPViT(CNN+Transformer):用于密集预测的多路径视觉Transformer

MapReduce instance (VII): single table join

在CANoe中通過Panel面板控制Test Module 運行(初級)

Nc29 search in two-dimensional array

DCDC power ripple test

Selection of software load balancing and hardware load balancing

CANoe的数据回放(Replay Block),还是要结合CAPL脚本才能说的明白

Take you back to spark ecosystem!
随机推荐
MapReduce instance (IV): natural sorting
美疾控中心:美国李斯特菌疫情暴发与冰激凌产品有关
手把手教您怎么编写第一个单片机程序
Download address of canoe, download and activation of can demo 16, and appendix of all canoe software versions
June brush question 01 - array
嵌入式开发中的防御性C语言编程
Compilation of libwebsocket
机械工程师和电气工程师方向哪个前景比较好?
在CANoe中通过Panel面板控制Test Module 运行(高级)
vscode 常用的指令
[NLP] bert4vec: a sentence vector generation tool based on pre training
MapReduce instance (IX): reduce end join
May brush question 02 - string
Single chip microcomputer realizes modular programming: Thinking + example + system tutorial (the degree of practicality is appalling)
[CV] target detection: derivation of common terms and map evaluation indicators
[untitled]
竞赛vscode配置指南
Can I learn PLC at the age of 33
Some thoughts on the study of 51 single chip microcomputer
五月刷题26——并查集