Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The method of Apache deployed online in Django

2025-02-25 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Environment:

1.Windows Server 2016 Datacenter 64-bit

2.SQL Server 2016 Enterprise 64-bit

3.Python 3.6.0 64-bit

4.administrator user, no domain environment, highest privileges

Request:

Deploy sequentially

1. Install the database

two。 Install the database client [SSMS]

3. Install Python

4. Download apache2.4 (httpd-2.4.41-win64-VC14.zip)

5. Extract to the root directory of C disk and open cmd to execute: C:\ Apache24\ bin\ httpd.exe-k install

6. Download the compiled wsgi (mod_wsgi-4.5.24+ap24vc14-cp36-cp36m-win_amd64.whl)

7.cmd execution: pip install [path]\ mod_wsgi-4.5.24+ap24vc14-cp36-cp36m-win_amd64.whl

8.cmd execution: mod_wsgi-express module-config (the execution result is appended to [httpd.conf])

LoadFile "d:/programs/python/python36.dll" LoadModule wsgi_module "d:/programs/python/lib/site-packages/mod_wsgi/server/mod_wsgi.cp36-win_amd64.pyd" WSGIPythonHome "d:/programs/python"

9. Modify [httpd.conf]

Define SRVROOT "c:/Apache24" ServerName [IP]: 80 Include conf/extra/httpd-vhosts.conf (uncomment)

10. Modify [extra/httpd-vhosts.conf] as follows:

ServerName "192.168.70.111" DocumentRoot "${SRVROOT} / htdocs/MySite" ErrorLog "logs/project-error.log" CustomLog "commonAlias / media/" ${SRVROOT} / htdocs/MySite/media/ "Require all grantedAlias / static/" ${SRVROOT} / htdocs/MySite/static/ "Require all grantedWSGIScriptAlias /" ${SRVROOT} / htdocs/MySite/project/wsgi.py "Require all granted

11. Start c:\ Apache24\ bin\ ApacheMonitor.exe

Summary

The above is the method of Django online deployment of Apache introduced by the editor. I hope it will be helpful to you. If you have any questions, please leave me a message and the editor will reply you in time. Thank you very much for your support to the website!

If you think this article is helpful to you, you are welcome to reprint it, please indicate the source, thank you!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report