Installing Django/Python on IIS6 - python

We are currently installing the latest version of Django and Python on IIS6. We have followed the instructions on the following site:
http://code.djangoproject.com/wiki/DjangoOnWindowsWithIISAndSQLServer
We are receiving a 403 error when trying to access our Django application via the IIS server.
We have verified the python installation on IIS6 and it is working properly.
We have also verified the Django installation. Our application runs fine under the built-in Django server, but we are having difficulties getting it to run under IIS.
We presume we could be getting errors from "Linking Django to PyISAPIe" section of the instructions provided on the link above.
Thanks.

Did you create a separate Application Pool to run PyISAPI (i.e. not the DefaultAppPool)? If so, what user/group does the pool run under? It's possible that you need to assign that user the proper rights. For example, see this page:
http://support.asimo.nl/activekb/questions.php?questionid=6
UPDATE: Here's another link with more detailed steps to check that your user permissions are set correctly:
http://forum.dotnetpanel.com/forums/t/602.aspx

Related

Deploying python application

I have created a python application containing rest apis which call machine learning code on PyCharm IDE. I want to deploy rest apis on IIS.
I copy and past complete PyCharm project in virtual directory. The issue I am facing is dependencies like tensorflow and keras are not being found due to which API is giving "Internal server error", however I am able to call rest services.
please guide.
As FishingCode suggested please share code snippet to understand the exact issue.
Please include and install requirements.txt file in virtual environment.
Also, you may try installing using docker tutorial

Why is my Read the Docs build failing?

I'm trying to make documentation with read the docs for a dummy package, to learn how to use RTD. I followed this tutorial and successfully made index.html and pushed my changes to git (though I'm using gitlab instead of github to host my code). However I cannot get it to be hosted on RTD.
I've connected RTD to my gitlab project via a webhook (and tested it on gitlab; it passed the test). I have both the gitlab project and the RTD project set to public. However I've tried building a version on RTD and it fails every time, without providing a warning/reason.
The first few times when I clicked on the RTD link for my project it said the page doesn't exist, now I get the following error:
Permission Denied
You don't have the proper permissions to view this page. Please contact the owner of this project to request permission.
Any ideas why this is happening or how to fix it?
try to open cmd as administrator and then:
idle pythonPath.py
or if you are using linux
sudo idle pythonPath.py

Mongoengine.django not found

Python ver=3.4
Django ver=1.9.2
In my project I am trying to integrate mongodb with above django version I have installed the mongoengine in my virtual environment and have made the necessary in settings.py file.
I am able to start the server but when I try to run the project in the browser it notifies me
A server error occurred. Please contact the administrator.
and in the terminal shows up.
Please tell me the correct way to integrate the mongodb if I am doing something wrong.
Okay so your issue lies in the version of mongoengine you are using. I am using the version 0.8.7 and it has mongoengine.django but the latest version on Github (0.10.6) has this deprecated.
Django support has been split from the main MongoEngine repository.
The legacy Django extension may be found bundled with the 0.9 release
of MongoEngine.
source -> http://mongoengine-odm.readthedocs.org/django.html

Download and setup a Angular/Django site from server to localhost?

Hi I am new to Django and have been googling for a whole day without any success.
Basically there is a live/working website built with AngularJS, Django and PostgreSQL (Ubuntu 14.04) and I am trying to download all the files and clone the site into my localhost (Ubuntu 14.04).
After I downloaded the folder and finished install the required packages on my localhost, I run:
python manage.py makemigrations
python manage.py migrate
python manage.py runserver
The server runs without reporting any errors.
However, some of the links are directed to a 404 page, such as this:
http://127.0.0.1:8000/city/chicago
Whereas in the live site, it would direct to the correct working page.
Can someone tell me what may have gone wrong in the process?
Thanks.
Try editing the settings.py file set the DEBUG value to True. Instead of a 404 you should get a full debug of the actual request and see what exactly is missing (I suspect missing data as #NightShadeQueen pointed).
Also you might have a look at django debug toolbar which prints the executed sql queries as well and run them against your local database to see what exactly they return.

Deployment issues of Django CMS Project on Ubuntu Server

I'm a rookie to Django and Django CMS but definitely enjoying the framework thus far.
I have a question regarding deploying a Django CMS project on Ubuntu Server. When we deploy it on the Ubuntu desktop version, the project works just fine without any issues, but on the server, we run into trouble with the CMS admin interface. Although the content of the sidebar is functional, it does not collapse anymore and once we select an option from the CMS toolbar, the modal window that pops up is unresponsive.
Initially i thought there was an issue with my project, but then we just installed a basic django CMS project on the server itself, without any other apps, and the issue still persisted. I am using Django 1.7.3, Django CMS 3.0.9, and Ubuntu Server 14.04. I am unable to determine what the issue is and no errors are thrown. Tried searching the web for this issue, but we couldn't find any similar issues.
UPDATE:
So i was able to narrow down the problem here to some extent. Found out that the problem was with the browser. A few versions of chrome were giving me these issues. IE and Firefox were working just fine.
UPDATE 2:
As #mkoistinen suggested, this problem had been occuring on devices with touch-screens and mouse capabilities. Please look at this issue.
I run Django and CMS, etc. on Ubuntu servers all day long, so there is not an issue with the OS for sure.
Having said this, running Django locally can be very different than running it in a production environment. Locally, runserver takes care of a lot of things you have to address yourself on a server under the WSGI implementation of your choice.
It sounds like you have WSGI configured well enough to get Django to respond, but you may be having trouble with your STATIC and MEDIA paths. Definitely check the settings for these items.
Another thing to look at is, did you run python manage.py collectstatic on the server? If not, the static files from your packages will not have been copied into your STATIC_ROOT, which could easily lead to the condition you describe above.
If your client is both touch- and mouse-capable, please note that this is an issue that is fixed in 3.0.10.

Categories

Resources