Jump to content

[Solved] How to deploy different Django apps under different sub-domains on Heliohost


sopython

Recommended Posts

I have tried the tutorial on wiki.helionet.org/Django, it works well. But now I want to deploy two Django apps on two subdomains on heliohost. I created two subdomians (e.g. Hello1 and Hello2), and the sub-folders Hello1 and Hello2 were created under public_html. Then I upload the Django apps to these subfolders and did the similar configurations to the .htaccess, dispatch.wsgi, etc separately. but it didn't work.

 

Is there any tutorial for this kind of situation? 

 

Thanks!

Link to comment
Share on other sites

I don't know of any reason why it shouldn't work, but nobody's ever asked this before. Django in general can be a bit of a pain though. Lets see if Krydos knows how to do this (I would've done the same thing as you, just modified the paths).

Link to comment
Share on other sites

You had a lot of things going on that were wrong. Rather than try to fix them all I just started you over fresh. http://pystone.sopython.heliohost.org/

 

As is always a good idea when debugging and developing make small changes and test it frequently to make sure your updates aren't breaking it. Let us know if you have any questions.

Link to comment
Share on other sites

Hi Krydos,

 

I did the following changes:

1) create a sub-folder pyStone under pyStone

2) move dispathc.wsgi , urls.py and settings.py into the new pyStone

3) update the .htaccess (add pyStone in the path)

 

Then the failure raised again, and the error info is:

[Fri Mar 29 15:57:40.169951 2019] [wsgi:error] [pid 27149:tid 140458021799680] [client 58.33.178.52:51715]   File "/home1/sopython/public_html/pyStone/pyStone/dispatch.wsgi", line 9, in <module>
[Fri Mar 29 15:57:40.169519 2019] [wsgi:error] [pid 27149:tid 140458021799680] [client 58.33.178.52:51715] mod_wsgi (pid=27149): Exception occurred processing WSGI script '/home1/sopython/public_html/pyStone/pyStone/dispatch.wsgi'.
[Fri Mar 29 15:57:40.169458 2019] [wsgi:error] [pid 27149:tid 140458021799680] [client 58.33.178.52:51715] mod_wsgi (pid=27149): Target WSGI script '/home1/sopython/public_html/pyStone/pyStone/dispatch.wsgi' cannot be loaded as Python module.
[Fri Mar 29 15:57:40.168364 2019] [wsgi:info] [pid 27149:tid 140458021799680] [client 58.33.178.52:51715] mod_wsgi (pid=27149, process='', application='pystone.sopython.heliohost.org|/pystone/dispatch.wsgi'): Loading WSGI script '/home1/sopython/public_html/pyStone/pyStone/dispatch.wsgi'.
 

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...