大网数据广告活动
网站运营与故障问答

Trying to install web2py on a shared server (Dreamhost)

· 52CE 我爱测

I've been trying to install web2py on a subdomain on my shared account at Dreamhost. There used to be some info in their knowledge base, but it has been removed for outdated. I've found lots of tutorials, but most date back at le…

问题原文

原帖链接 · jcoppens · CC BY-SA 3.0

I've been trying to install web2py on a subdomain on my shared account at Dreamhost. There used to be some info in their knowledge base, but it has been removed for outdated. I've found lots of tutorials, but most date back at least 6 years. The website of flup is confusing - the dates of the forum seem all wrong (comments of version 0.9 are more recent that those of 1.0.3xxx).

Seemingly one of the most applicable 'recipes' installs well, but produces a 500 error. When I try to execute the web2py.fcgi, it reports Premature end of script. No obvious errors in the Apache logs.

I started Python from the virtual environment manually. import sys worked well, but from flup.server.fcgi_fork import WSGIServer caused an error which was apparently a Python 2/3 incompatibility. Installing an earlier version of flup did the trick.

Now, executing (still manually) import gluon.main produces: ImportError: No module named gluon.main. I can understand that - gluon is not in the sys.path. I can't imagine the instructions being so wrong, so it's probably something I'm doing.

  • Anyone know about a reliable install recipe for web2py on a remote shared server?

  • Or a pointer to a good description on how Apache, and web2py are supposed to communicate with each other (role of flup, `WSGI'...)

  • Is there any way to get more info for debugging?

已采纳解答

原帖链接 · jcoppens · CC BY-SA 4.0

Well, I wasn't able to get things working following this tutorial, and many tests and variations.

Finally, I found a very interesting link in the uWSGI site, which actually made things work!

The only issue left, is enabling https without self-signed certificates. I'll post another question, as it seems to be a separate matter.

UPDATE: By 'accident', I encountered this recipe, which today (Jan 2022) works perfectly. Just be careful to substitute the correct user name in all lines where necessary. (Cheers, Aubrey!)

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Webmasters Stack Exchange
适用范围
以原帖系统、软件版本与发布日期为准(2016-08-14)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0 / CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。