How To Setup Django Applications with Apache and mod_wsgi on Ubuntu

แชร์
ฝัง
  • เผยแพร่เมื่อ 7 ม.ค. 2025

ความคิดเห็น • 72

  • @StudyGyaan
    @StudyGyaan  4 ปีที่แล้ว

    Django CRM Playlist - th-cam.com/play/PLSPMgrv4IuJ4WLURdlzKNx4sgsyqW8d5q.html
    Django Tips Playlist - th-cam.com/play/PLSPMgrv4IuJ6jm66M2rSZM_qIakywFoIr.html
    Django Rest Framework Playlist - th-cam.com/play/PLSPMgrv4IuJ4tPeMgDGx7XV-4VRrjzZ8t.html
    Django Oscar Shopping Website Playlist - th-cam.com/play/PLSPMgrv4IuJ5tX9Sk7hjNrHsQRC3ppRtG.html
    All Playlist - th-cam.com/users/ProfessionalCipherplaylists

  • @StudyGyaan
    @StudyGyaan  4 ปีที่แล้ว +1

    Do you like this video??? Comment and tell me.....
    Complete Tutorial for BUILD DJANGO CRM FROM SCRATCH - th-cam.com/play/PLSPMgrv4IuJ4WLURdlzKNx4sgsyqW8d5q.html

    • @Funtime-ge3xu
      @Funtime-ge3xu 4 ปีที่แล้ว

      Static files arent loading if I turn off debug mode in settings.py help me please

  • @marciosouza7083
    @marciosouza7083 4 ปีที่แล้ว +1

    Thank you a lot. I´ve tried about 14 or more configurations and no one has work wright. So I tried follow you directions and work ok. GREAT JOB.

    • @StudyGyaan
      @StudyGyaan  4 ปีที่แล้ว

      Happy to hear that 😊

  • @jkumwenda
    @jkumwenda 4 ปีที่แล้ว +4

    I struggled with this but this tutorial makes the whole thing easy.. Thanks mate.

  • @tomha1
    @tomha1 2 ปีที่แล้ว

    this is an excellent tutorial. only took me a few hours to do something that would have been several days

  • @anoniem012
    @anoniem012 4 ปีที่แล้ว

    Djazak'Allahu khairan brother I was installing Modoboa this particular command helped me a lot:
    sudo apt-get install libapache2-mod-wsgi-py3

  • @sonamkori8169
    @sonamkori8169 3 ปีที่แล้ว

    Thank you allot... This made my life easy. Struggling from past 2 weeks.

  • @abhikhatri5414
    @abhikhatri5414 4 ปีที่แล้ว +2

    Bro you have very clearly and simply demonstrated on how to deploy Django applications on Apache2 Server with mod_wsgi using Virtual Host
    Also if you have demonstrated a little bit more about wsgi.py and the activation process as well as the permission issues then even a very newbie will be able to do the things easily without any error
    Because of this, some newbies will be facing errors on deploying Django applications on Apache2 Server with mod_wsgi, and the interesting thing is that they may be thinking that the way you are demonstrating is not the better and easy way, and also they may be thinking this method as the wrong way of deploying .......
    I do hope you may take this point bro
    Thank you so much bro for guiding newbies ....
    God bless you ...

    • @MaxAdams-c7f
      @MaxAdams-c7f 2 หลายเดือนก่อน

      can i ask what was the aswer to the permission issues?

  • @DamienMalakay
    @DamienMalakay 4 ปีที่แล้ว +6

    This definitely needs a lot more explanation than the instructor mentions here. A lot of copy and paste and not very much explanation. One thing that is key here is the WSGI Module and this can be a headache to setup especially if you are using different versions of Python like 3.5 and 3.8 and if you install that library libapache2-mod-wsgi-py3 it will not work. I had to dig around a lot to find out that WSGI needs to be setup with pip3 install mod_wsgi and some libraries are missing like python3.8-dev and python3.8-gdbm to get started. Also the /etc/apache2/mods-enabled/wsgi.load needs to point to your /var/www/django_project/env/lib/python3.8/site-packages/mod_wsgi/server (you can use a symbolic link I guess). If you have templates then this also needs to be addressed as well as the wsgi.py needs to be edited os.environ.setdefault should be confirmed here as I learned

    • @siddhanthmetla9638
      @siddhanthmetla9638 4 ปีที่แล้ว +1

      So were you successful in hosting your web application? If yes, can you please explain how?

  • @SAQIBGHATTE
    @SAQIBGHATTE 4 ปีที่แล้ว +2

    Thank you so much...! This one video solved all my doubts.!

    • @StudyGyaan
      @StudyGyaan  4 ปีที่แล้ว +1

      Glad to hear that 👍

  • @ShubhamSinghMCS
    @ShubhamSinghMCS 3 ปีที่แล้ว

    You are awsm buddy 🔥🔥

  • @jodybaudoin7577
    @jodybaudoin7577 4 ปีที่แล้ว +1

    You did a lot of work on this. Good job.

  • @ayoubboulehfa3932
    @ayoubboulehfa3932 4 ปีที่แล้ว +3

    4:20 add import os at the top

  • @valdumarmelvinwalters3432
    @valdumarmelvinwalters3432 3 ปีที่แล้ว

    Thank you very much man! Enjoyed the tutorial page on your website, it's easy to follow and has quite a few good tips.

  • @bun4bun
    @bun4bun 3 ปีที่แล้ว

    Fantastic.
    Thank you very much

  • @saliksheraz6236
    @saliksheraz6236 3 ปีที่แล้ว

    Awesome tutorial brother, really helpful thanks

  • @semwong9591
    @semwong9591 3 ปีที่แล้ว

    thanks for this tutorial dude I subscribe

  • @shaikbyte
    @shaikbyte 5 ปีที่แล้ว +1

    I can say,,, ....kirrrak.......excellent

  • @shauryayamdagni
    @shauryayamdagni 2 ปีที่แล้ว

    very nice dude

  • @stefanAH97
    @stefanAH97 3 ปีที่แล้ว

    Awesome, thnx a lot

  • @siddhanthmetla9638
    @siddhanthmetla9638 4 ปีที่แล้ว +1

    Yet another amazing video by professional cipher. But can you please help me? Everything works fine as per the video but now how can public access this website?

  • @潘文傑-v2g
    @潘文傑-v2g 4 ปีที่แล้ว +1

    thanks a lot , if i create a django and apache on virtual box which address should be access on my computer (not in virtual box)

  • @lavanyapadma3024
    @lavanyapadma3024 3 ปีที่แล้ว +1

    Hi Sir, Thanks for the video, is the process same for windows too? If no can you pls send me link if the process for windows is in studygyan website ? Please help me with this

  • @enesyurtsever
    @enesyurtsever 4 ปีที่แล้ว

    You are master!!

  • @Ocean999K
    @Ocean999K 3 ปีที่แล้ว

    Very helpful, thanks! Do you have document of using Posgresql?

  • @tinman222
    @tinman222 5 ปีที่แล้ว +2

    Wsywig editors like tinymce and ckeditor and also django file uploader is not working on production environment plz make a video on this plz...help me........I have upload my website ...but i didnt know earlier ..everything is fine static files are seving greatly but these things are not working

  • @nirushamunikar3675
    @nirushamunikar3675 5 ปีที่แล้ว +4

    I really like the video. Thank you so much, can you show how to add Postgresql to the django project.

    • @StudyGyaan
      @StudyGyaan  5 ปีที่แล้ว +1

      Yeah sure very soon i will upload

    • @MrKatdar
      @MrKatdar 5 ปีที่แล้ว +1

      I used
      Professional Cipher's article to setup apache and django. Then I configured Postgresql on that environment. I just wrote an article about this. You can check from: selimatmaca.com/index.php/django/205-how-to-install-apache-django-postgresql-on-ubuntu-18-04-part2

    • @nirushamunikar3675
      @nirushamunikar3675 5 ปีที่แล้ว

      @@StudyGyaan umm okay waiting ☺️☺️😊

    • @nirushamunikar3675
      @nirushamunikar3675 5 ปีที่แล้ว

      @@MrKatdar thankyou !! i will definitely try this one.... 😊

    • @izenish
      @izenish 2 ปีที่แล้ว

      Have you found the solution to this!?

  • @dgiri2333
    @dgiri2333 3 ปีที่แล้ว

    Apache how many requests handel per network, can you do one video for Apache run on https..

  • @jairocb6887
    @jairocb6887 3 ปีที่แล้ว

    Tnx, a lot. One question. And from another local pc to connect to the server. What address would you put in the URL? For example if 192.168.5.100 is the server IP instead of > it would be like djangoproject.192.168.5.100? Or what would be the correct way? What additional should I configure?

  • @wiki-infodevelopment3369
    @wiki-infodevelopment3369 2 ปีที่แล้ว

    Could you setup it again on Windows?

  • @pablobellido8306
    @pablobellido8306 4 ปีที่แล้ว +1

    If I have a domain, where do I put it?
    an you show how to add mysql to the django project.

    • @StudyGyaan
      @StudyGyaan  4 ปีที่แล้ว

      th-cam.com/video/A6mTN6G-adM/w-d-xo.html

  • @manicsurfing
    @manicsurfing ปีที่แล้ว

    thank you

  • @djmfcp
    @djmfcp 3 ปีที่แล้ว

    Thanks for the tutorial, got it working running on my raspi. Does anyone know what needs to be done to make the apache server accessible to computers on the local network? I'm getting a permission denied (402) error when I type in the raspberrys IP address. To access it, I can run the django server using manage.py, but is it possible to modify the permissions we set in this tutorial to access the apache one off the network without the django server running via manage.py?

  • @petersilva3422
    @petersilva3422 3 ปีที่แล้ว

    Nice video man, very useful. I have a question regarding data migration. You mentioned that it is possible to migrate data to a postgresql so my question is: How can I do that?

    • @Ocean999K
      @Ocean999K 3 ปีที่แล้ว

      Do you happen to do this with PostgreSQL?

  • @sagarbentur6331
    @sagarbentur6331 4 ปีที่แล้ว +1

    Hi I don't know why everything work untill I restart the apache server.. after restarting the server the page won't load.. it keep on loading..

    • @sagarbentur6331
      @sagarbentur6331 4 ปีที่แล้ว

      No it worked later.. I forgot to reload the server after editing in django.. thanks for the help

  • @mikecoleman4628
    @mikecoleman4628 4 ปีที่แล้ว +4

    Basically you're copying and pasting out of the documentation, and not offering any extra explanation.

  • @abdulsaboor8931
    @abdulsaboor8931 4 ปีที่แล้ว +1

    i am getting a 403 forbidden error please help

  • @rameshpradhan2308
    @rameshpradhan2308 5 ปีที่แล้ว +2

    Hello sir, How can I upload django project in Cpanel with no root access ?

    • @abhikhatri5414
      @abhikhatri5414 4 ปีที่แล้ว

      My recommendation is don't use shared hosting to serve django application, instead use vps however for better (dedicated is recommended) but you can host and serve django application via shared hosting and it's not hard ...
      If you really want to host django applications on shared hosting with cpanel let me know your mail i can help you on that
      but again I repeat never host and serve django applications or even Java app via shared hosting...
      But to try and learn you can host your Django applications on 👉 heruku 👈, the free hosting provider for limited purposes
      You can find documentation by Heruku on how to host and serve Django applications via Heruku.com
      Best of Luck

    • @Speaks4itself
      @Speaks4itself 4 ปีที่แล้ว

      @@abhikhatri5414 whats wrong with cpanel?

  • @SURJEETSINGH-ms9iu
    @SURJEETSINGH-ms9iu 4 ปีที่แล้ว +1

    thank you bro but admin page is not working

  • @CraigThompson213
    @CraigThompson213 2 ปีที่แล้ว

    One piece that I feel was left out.
    When the virtualenv is created be certain to add privileges.
    sudo chmod -R 777 env

    • @CraigThompson213
      @CraigThompson213 2 ปีที่แล้ว

      I thought that might be the resolution to the 403 error I keep getting but no such luck.
      I've worked through the tutorial now 5 times and keep getting the same Forbidden error.
      Any help would be greatly appreciated.

  • @subhammitra7599
    @subhammitra7599 4 ปีที่แล้ว +2

    This tutorial is fooling us. Basically it is running the same Django server and not the Apache. Please don't teach wrong things

    • @StudyGyaan
      @StudyGyaan  4 ปีที่แล้ว

      How can you say that, just check out the url, have you tried the tutorial, actually you are fooling people HAHAHA

    • @subhammitra7599
      @subhammitra7599 4 ปีที่แล้ว +1

      @@StudyGyaan yes, just stop the Django server and check whether the url is opening or not. Apache server is doing nothing here.

    • @subhammitra7599
      @subhammitra7599 4 ปีที่แล้ว +1

      And first try to learn things before teaching anything. You concept about server is not clear. Django and apache both are servers and we want to use apache instead of Django server. But you are running Django server in the background, then what is the meaning of running apache?

    • @StudyGyaan
      @StudyGyaan  4 ปีที่แล้ว

      @@subhammitra7599 Hello brother, just follow the tutorial and try it, when you run django server on apache or ngnix, the server runs forever. if you try to stop also it wont stop, that's why i have given error log information. Just read the comment, you will find video genuine. Thank you.

    • @StudyGyaan
      @StudyGyaan  4 ปีที่แล้ว

      @@subhammitra7599 First you try it. Just see video you can't judge HAHAHAHAHa