Search code examples
pythondjangopython-2.7deploymentpythonanywhere

Is it convinient to change the app build in django 1.7 to django 1.3 version


I have developed a django app in django 1.7 version with python 2.7 and want to deploy it in python anywhere with free version, but python anywhere does not support it-

enter image description here

But it only supports django 1.3 with python 2.7. So what changes i have to make to run my code in it with django 1.3.

Else if anybody is having any other option for django(1.7) app deployment plz suggest me.

Also i have deployed my django app(1.7) with 3rd option selected(python 2.7, django 1.7) then the output is - link to my deployed app


Solution

  • PythonAnywhere dev here- you can actually install the version of Django that you want using a virtualenv!

    The commands to run from bash are just

    mkvirtualenv Django17
    pip install django==1.7
    

    And then making sure that you set your virtualenv path correctly in your webapps tab! (in this case your path would be /home/your-user-name/.virtualenvs/Django17/)

    Setting your Virtualenv

    ie. You would have to set the virtualenv path as shown in the picture above

    ps: on an unrelated issue to 1.7 vs 1.3, the reason that you are seeing the Django welcome page of the hello world/congrats on your first webapp variety is because that is the sample webapp that we have made for you.

    You would need to correctly set up the paths to point to your source-code for your actual website to be displayed.