Results 1 to 10 of 10

Thread: Django project on server 12.04 LTS ubuntu

  1. #1
    Join Date
    Oct 2012
    Beans
    212
    Distro
    Ubuntu 12.04 Precise Pangolin

    Question Django project on server 12.04 LTS ubuntu

    Hi guys...i (as usual) followed this guide http://jeffbaier.com/articles/instal...-linux-server/ for installing a django project .
    and (Also as usual) i got a problem .

    my problem is : when visiting 192.168.1.4 (where ubuntu server ) all what i got apache server's default page .

    my ubuntu server is on a oracle VMBox .

    any an idea ?

    thank you .

  2. #2
    Join Date
    May 2007
    Location
    NY's first capital
    Beans
    2,868
    Distro
    Ubuntu 20.04 Focal Fossa

    Re: Installing a django project on server 12.4 LTS ubuntu

    After quickly skimming the how-to it seems your Django install should be located at
    Code:
    http://192.168.1.4/media
    I have not used symlinks for directing apache to different directories. I usually just modify/create a virtual host file and use the DocumentRoot directive.
    Nothing is ever easy, but if it is difficult you must be doing it wrong.

  3. #3
    Join Date
    Oct 2012
    Beans
    212
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Installing a django project on server 12.4 LTS ubuntu

    Quote Originally Posted by volkswagner View Post
    After quickly skimming the how-to it seems your Django install should be located at
    Code:
    http://192.168.1.4/media
    I have not used symlinks for directing apache to different directories. I usually just modify/create a virtual host file and use the DocumentRoot directive.
    Hi...there is no URL with http://192.168.1.4/media/admin or http://192.168.1.4/media/Recording (my project)

    but with http://192.168.1.4/media i got a page like ftp pages with filezilla .

  4. #4
    Join Date
    May 2007
    Location
    NY's first capital
    Beans
    2,868
    Distro
    Ubuntu 20.04 Focal Fossa

    Re: Installing a django project on server 12.4 LTS ubuntu

    Can you determine the actual directory you have landed at? Compare the listings to your webroot.

    Can you post a screenshot?
    Nothing is ever easy, but if it is difficult you must be doing it wrong.

  5. #5
    Join Date
    Oct 2012
    Beans
    212
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Installing a django project on server 12.4 LTS ubuntu

    Quote Originally Posted by volkswagner View Post
    Can you determine the actual directory you have landed at? Compare the listings to your webroot.

    Can you post a screenshot?
    I'm sorry but where is webroot ? (/var/www/ ?)

    Also i did't understand your question : Can you determine the actual directory you have landed at ?

    Also



    thank you....
    Last edited by Raafat1991; January 30th, 2013 at 01:15 PM.

  6. #6
    Join Date
    May 2007
    Location
    NY's first capital
    Beans
    2,868
    Distro
    Ubuntu 20.04 Focal Fossa

    Re: Django project on server 12.04 LTS ubuntu

    Sorry for the poorly worded question. "Landed" meaning from the screenshot above, can you navigate to /var/www/media and see an empty directory?


    Code:
    ls -alt /var/www
    Code:
    ls -alt /var/www/media

    Either /var/www/media is empty, the symbolic link is not working, or Apache2 does not have permission to follow the link.


    A side note: I'm not sure how much time you have invested in this server, or if you have an available Virtual Machine host (hypervisor)... check out TurnkeyLinux for a prebuilt image you can deploy with Django already setup.
    Nothing is ever easy, but if it is difficult you must be doing it wrong.

  7. #7
    Join Date
    Oct 2012
    Beans
    212
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Django project on server 12.04 LTS ubuntu

    Quote Originally Posted by volkswagner View Post
    Sorry for the poorly worded question. "Landed" meaning from the screenshot above, can you navigate to /var/www/media and see an empty directory?


    Code:
    ls -alt /var/www
    Code:
    ls -alt /var/www/media
    Either /var/www/media is empty, the symbolic link is not working, or Apache2 does not have permission to follow the link.


    A side note: I'm not sure how much time you have invested in this server, or if you have an available Virtual Machine host (hypervisor)... check out TurnkeyLinux for a prebuilt image you can deploy with Django already setup.
    Yes it's empty .

    Code:
    ls -alt /var/www
    its output :

    Code:
    drwxr-xr-x  2 root root 4096 Jan 31 13:52 .
    drwxr-xr-x 13 root root 4096 Jan 30 15:25 ..
    lrwxrwxrwx  1 root root   50 Jan 23 21:45 admin_media -> /home/raafat/django_src/django/contrib/admin/media
    lrwxrwxrwx  1 root root   18 Jan 23 21:45 media -> /home/raafat/media
    -rw-r--r--  1 root root  177 Jan  5 23:01 index.html

    Code:
    ls -alt /var/www/media
    its output :

    Code:
    lrwxrwxrwx 1 root root 18 Jan 23 21:45 /var/www/media -> /home/raafat/media
    i will check your side note .

    thank you .

  8. #8
    Join Date
    Oct 2012
    Beans
    212
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Django project on server 12.04 LTS ubuntu

    Guys i'm waiting you...please .

  9. #9
    Join Date
    May 2007
    Location
    NY's first capital
    Beans
    2,868
    Distro
    Ubuntu 20.04 Focal Fossa

    Re: Django project on server 12.04 LTS ubuntu

    It seems the how to you used is incomplete. It assumes you know how to configure apache2 for mod_python.

    I suggest you look for a better how to specific to Debian or Ubuntu.

    Take a look at this how-to, specifically look at /etc/apache2/sites-available/default edits.

    I'm sorry I've never used mod_python.

    Perhaps you should post your vhost file.
    Nothing is ever easy, but if it is difficult you must be doing it wrong.

  10. #10
    Join Date
    Oct 2012
    Beans
    212
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Django project on server 12.04 LTS ubuntu

    Quote Originally Posted by volkswagner View Post
    It seems the how to you used is incomplete. It assumes you know how to configure apache2 for mod_python.

    I suggest you look for a better how to specific to Debian or Ubuntu.

    Take a look at this how-to, specifically look at /etc/apache2/sites-available/default edits.

    I'm sorry I've never used mod_python.

    Perhaps you should post your vhost file.
    Many thanks...thank you everyone .

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •