python - 在 Ubuntu 16.04 LTS 上使用 pgadmin4.15 和 apache 时出现内部服务器错误
问题描述
我几乎按照这篇文章进行了设置,pgadmin 4
我ubuntu 16.04
跳过了安装的第一步PostgreSql
,因为我想使用 AWS RDS。但是当我尝试启动时http://myipaddress/pgadmin4/
,我得到了500 Internal Server Error
. http://myipaddress
确实让我进入了Apache2 Ubuntu Default Page,但不确定我缺少什么配置。
我也遵循了这一点并添加了建议的修复程序,但它对我不起作用。
这是error.log
[wsgi:warn] [pid 19605:tid 140528707069824] mod_wsgi: Compiled for Python/3.5.1+.
[wsgi:warn] [pid 19605:tid 140528707069824] mod_wsgi: Runtime using Python/3.5.2.
[mpm_event:notice] [pid 19605:tid 140528707069824] AH00489: Apache/2.4.18 (Ubuntu) mod_wsgi/4.3.0 Python/3.5.2 configured -- resuming normal operations
[core:notice] [pid 19605:tid 140528707069824] AH00094: Command line: '/usr/sbin/apache2'
[wsgi:error] [pid 19608:tid 140528601200384] [remote 8.28.16.254:0] mod_wsgi (pid=19608): Exception occurred processing WSGI script '/usr/share/pgadmin4/web/pgAdmin4.wsgi'.
[wsgi:error] [pid 19608:tid 140528601200384] [remote 8.28.16.254:0] Traceback (most recent call last):
[wsgi:error] [pid 19608:tid 140528601200384] [remote 8.28.16.254:0] File "/usr/lib/python3/dist-packages/flask/app.py", line 1836, in __call__
[wsgi:error] [pid 19608:tid 140528601200384] [remote 8.28.16.254:0] return self.wsgi_app(environ, start_response)
[wsgi:error] [pid 19608:tid 140528601200384] [remote 8.28.16.254:0] File "/usr/share/pgadmin4/web/pgAdmin4.py", line 95, in __call__
[pid 19608:tid 140528601200384] [remote 8.28.16.254:0] return self.app(environ, start_response)
[wsgi:error] [pid 19608:tid 140528601200384] [remote 8.28.16.254:0] AttributeError: 'ReverseProxied' object has no attribute 'app'
解决方案
我没有+符号。由于某种原因,我的缩进搞砸了。一旦我修复它,它就可以正常工作。
File "/usr/share/pgadmin4/web/pgAdmin4.py", line 83
except ImportError:
^
IndentationError: unindent does not match any outer indentation level
推荐阅读
- c# - 我怎样才能永远摧毁一个游戏对象?
- excel - 发送电子邮件会生成运行时错误“-2147417851 (80010105)”:对象“_MailItem”的方法“收件人”失败
- android - 如何将数据返回到kotlin中的调用活动?
- reactjs - 使用地图功能反应循环组件,索引错误
- javascript - Discord.js 禁止命令
- java - Angular:检测用户何时停止输入
- javascript - ngOnDestroy() 可以在条件下触发吗?选择复选框时,即使在网格重新加载后,它也会记住我以前的选择
- python - 将值添加到 Dataframe 保留索引
- 2d - Godot:2D Raycast 正朝着相反的方向发展
- node.js - Nodejs sendFile() 禁用换行