Python is a dynamically and strongly typed programming language that encourages readability.

learn more… | top users | synonyms

-1
votes
0answers
6 views

Create queryset object manually or Retrieve queryset object using custom query? [on hold]

How to create query set object when work with custom query. i want to join 5 table. but there is no foreign key defined in all table (its integer field instead of Foreign key) Example : PersonID is ...
0
votes
1answer
26 views

couldn't to install mod_wsgi on centos

i tried so many times to install mod_wsgi on my centos6 server but unfortunately i couldn't do that. my steps to install it : yum -y install mod_wsgi Error: Package: mod_wsgi-3.2-7.el6.x86_64 ...
0
votes
0answers
30 views

How do I correct the path for pip? [migrated]

I'm trying to get pip to point to a different install rather than the default. It is currently pointing to /usr/bin/pip, but I want it to point to /usr/local/bin/pip. I believe I have the path set ...
0
votes
0answers
12 views

Running python to unlock luks full disk encryption

I wish to make use of full disk encryption using Luks on ubuntu 14.04. However, i wish to make use of my own python script to carry out the functionality of generating the decryption key during device ...
1
vote
1answer
31 views

How to serve static files with apache on openshift official python cartridge?

I have scalable openshift online app with official python-2.7 cartridge. By default everything is served with mod_wsgi handler. How do I configure my app and/or Apache to serve some static files in my ...
0
votes
0answers
34 views

HAProxy tcp load balancing with an https check fails

I'm trying to load balance a posgres tcp connection, with a node check done via a python script residing on an https connection. conf file looks like so: global log 127.0.0.1 local2 ...
0
votes
0answers
20 views

Apache2 will not run python script [closed]

I am very new to webservers and I am learning everything from scratch. My webpage is simple: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" ...
0
votes
0answers
15 views

how to serve a single page application with openshift

I'm tryng to deploy a single page app on openshift. On openshift all the static contents have to be in wsgi/static dir, but I obviously want to serve my static index.html from the root. Every attempts ...
0
votes
2answers
131 views

How can I upgrade Python to 2.7.9 on Ubuntu 14.4?

Ubuntu 14.4 comes with Python 2.7.6 built-in, but I'd like to upgrade it to 2.7.9 (it has security features that I want). Is that even possible? If so, how can this be achieved?
0
votes
1answer
16 views

AWS EB deployment errors - No module named cfnbootstrap

I am trying to deploy my application on AWS Elastic Beanstalk, it states some errors when the process is completed and reading the logs this is what I've found: File "/opt/aws/bin/cfn-get-metadata", ...
0
votes
0answers
19 views

uWSGI backtrace error [migrated]

I'm getting the following backtrace in my uWSGI logs, I don't know where to begin looking to figure this out: Thu Feb 12 17:08:18 2015 - mapping worker 1 to CPUs: 0 Thu Feb 12 17:09:40 2015 - WSGI ...
0
votes
1answer
34 views

restarting apache using python causes port change

i'm using python bottle web framework to create a service manager so i've created endpoints for services re/starting / stopping the wired thing that happens when i'm using os.system('service apache2 ...
0
votes
1answer
93 views

Unsupported version control system “svn”: No module named svn

I'm using The Trac Project with TracModWSGI – The Trac Project on RHEL7: # cat /etc/redhat-release Red Hat Enterprise Linux Server release 7.0 (Maipo) # rpm -q httpd mod_wsgi subversion swig ...
0
votes
0answers
10 views

python SimpleHTTPServer launched as a thread: does not daemonize [migrated]

I would like to launch a SimpleHTTPServer in a separate thread, while doing something else (here, time.sleep(100)) in the main one. Here is a simplified sample of my code: from SimpleHTTPServer ...
0
votes
0answers
4 views

nginx + gunicorn + pyramid: Get actual domain name from headers [migrated]

I'm asking this question here instead of SO because it seems more like an admin question, hopefully someone can help. I just setup nginx + gunicorn to serve up a Pyramid web application. My ...
0
votes
1answer
23 views

Static Analyzer for Configuration files

I'm currently planning to analyze csv-reports from our ActiveDirectory and configuration files from our switches with Python. I'm thinking of having seperate modules for each type of data (csv, txt). ...
0
votes
0answers
2 views

python selenium not able to open Firefox browser [migrated]

I am using Python with selenium. I am getting following error when I am trying to open Firefox using python selenium >>> driver = webdriver.Firefox() Traceback (most recent call last): ...
1
vote
2answers
43 views

Trac/Apache Displays Script Contents (WSGI)

I am struggling with a new Trac 1.0.3 install (from source after having same issue installing via easy_install). Debian 7.8 Apache 2.2.22 Python 2.7.3 Genshi 0.6 Sqlite 3.7.13 WSGI 3.3 I created ...
0
votes
0answers
43 views

Running Python and PHP on the same server

I've got Django, Gunicorn, and Nginx set up and working nicely together. I'm only going to have a few pages on this Django website, so I'm trying to I'm trying to set up the server such that files ...
0
votes
1answer
73 views

How to point Ubuntu 14.10 Apache2 (mod-wsgi) server to a specific virtual environment (Python 3.4 / Flask)?

I am running apache2 (mod-wsgi) on Ubuntu 14.10. I am getting 500 Internal Server Error when serving my web-site. I am also using Flask and Python 3.4, and virtual environment. It appears that Ubuntu ...
0
votes
0answers
13 views

Can I distribute my python objects without having admin rights?

Playing at home, I learned to build my objects in python and use them in VBA with pythoncom tools. Now I want to do the same at work so colleagues (in the intranet) can load and use the same objects. ...
0
votes
0answers
26 views

cx_Oracle suddenly slow to connect

Have a test machine set up with oracle 11g installed: I'm trying to connect with python and cx_Oracle. Yesterday, my code worked perfectly: import cx_Oracle print "connecting..." with ...
0
votes
1answer
46 views

Seeking advice on performance metrics based on NewRelic dashboard

Some background: I have been given access to our newrelic dashboard for the production servers running a django app on an AWS account, and tasked to come up with some gatling.io (performance testing ...
0
votes
1answer
49 views

Postfix catch-all email, save to combined file

We're running a spam trap / honeypot, and by using the amazing guidance of the members here, I've been able to configure our Ubuntu server running Postfix 2.11.0 to catch all inbound email, regardless ...
0
votes
1answer
29 views

Unbound DNS: How to get source IP address from python mod

I use Unbound DNS with a custom python module. Based on who sends a query, I want to return different results. How do I get the Source IP from the Python module?
0
votes
1answer
47 views

strange strace output of httpd process of apache running django with mod_wsgi

I have about 12 httpd processes running for an RHEL aws box that no one is hitting in the browser (shared team dev box). These processes together are consuming over 1.8 GB on the dev box, and I have ...
1
vote
0answers
11 views

Is there an automated installer/manager for mod_wsgi 3.4?

# yum --showduplicates list mod_wsgi | expand Loaded plugins: fastestmirror Determining fastest mirrors * base: mirror.cov.ukservers.com * epel: mirrors.coreix.net * extras: ...
0
votes
0answers
20 views

Python in the debian-installer context

My broader question is about using Ansible to perform the late_command in a preseeded Debian/Ubuntu install. The specific question is, is there some straightforward or documented way to get a working ...
1
vote
0answers
920 views

AttributeError: 'module' object has no attribute * python

I am struggling with compiling python 2.7.9 from source and have been advised to ask this question here. While installing python 2.7.9 following the steps described here the following errors ...
1
vote
1answer
80 views

Installing mod_wsgi error - config.status: error: cannot find input file: Makefile.in [closed]

Below, I'm trying to install mod_wsgi. [root@server]# ./configure --with-python=/usr/local/bin/python2.7 checking for apxs2... no checking for apxs... no checking Apache version... ./configure: line ...
1
vote
1answer
27 views

Environment variable not available in python

I have a pretty interesting problem regarding environment variables, and googling around didn't show me any meaningful results: $ echo $BUCKET && python -c "import os; print ...
0
votes
0answers
36 views

Cannot add dynos on Heroku app after seemingly successful app push

I recently launched an app on Heroku using git push heroku master and got a couple of errors: remote: raise ValueError("Missing distribution spec", line) remote: ValueError: ...
0
votes
0answers
54 views

Python logger stops logging

On an application server (CentOs 6.4), python's native logger will stop writing to a log file after about 48 hours of continuous operation. This started occurring when we added fluentd (td-agent) to ...
0
votes
0answers
39 views

Python libraries slow to load from NFS mount point

Several of our computers are diskless, and they load their Python libraries from an NFS mount point across the network. This means it can take up to three minutes to start up a Python process that ...
-1
votes
1answer
67 views

Running multiple workers using Celery

I need to read from Rabbitmq and execute task in parallel using Celery in a single system. [2014-12-30 15:54:22,374: INFO/Worker-1] ... [2014-12-30 15:54:23,401: INFO/Worker-1] ... [2014-12-30 ...
1
vote
1answer
85 views

Python background task thread lock error with mod_wsgi

I have a small python web application built on the Flask framework and deployed with mod_wsgi to apache. The application is scheduling a background task with apscheduler that runs every couple of ...
0
votes
0answers
29 views

UnicodeDecodeError starting Radicale server during boot process

I set up the Radicale CalDAV server on Debian Wheezy (raspbian). I can launch it manually as expected. However, when I try to start it during boot process it fails with the following error: ...
0
votes
0answers
95 views

OpenVPN Python plugin

I have a task about authentication OpenVPN users using database which is located on remote server (not a host with OpenVPN server instance). And we use Python as main language for all our tools. ...
1
vote
1answer
35 views

apache fails to load mod_wsgi: complains of 'missing symbol'

When I run apachectl configtest after installing mod_wsgi I get the following error message: httpd: Syntax error on line 117 of /private/etc/apache2/httpd.conf: Cannot load ...
0
votes
1answer
36 views

NodeJs running in command line shows “Aborted”

I am using an Amazon EC2 instance using CentOs 5.4. I installed nodejs in different servers that follow the same architecture. In the current server I installed nodejs by following the below steps. ...
2
votes
1answer
79 views

SPF issue with SpamAssassin

I have an internal management app for a small company, written in Python and running on a Linode VPS, with which users can send occasional emails to their customers. The emails are quite ...
-3
votes
1answer
87 views

Mailman 404 page not found

I have configured mailman following these instructions. https://www.gnu.org/software/mailman/mailman-install/index.html I have run into this problem Problem: All Mailman web pages give a 404 File ...
-1
votes
1answer
152 views

Nginx Internal Server Error

I am new to NGINX and uwsgi and Im deploying my first python web application. Having tried numerous times, I get an internal server error. There may be something wrong with my configurations but i ...
0
votes
1answer
55 views

Adding python to /usr/bin/env python variable [closed]

The #!/usr/bin/env python hashbang isn't working on my Ubuntu install. I tried the following: root@x# python=/usr/bin/python root@x# PATH=$PATH:/usr/bin/python
1
vote
0answers
86 views

Is my site getting hacked (Bluehost)?

I'm running a simple website off of Bluehost, and I needed to use custom Python scripts so I created a cgi-bin folder in my site's directory and added my cgi python files there. Everytime I tried to ...
0
votes
0answers
23 views

Download log files from a server with Fabric

I'm using Fabric to download some log files from a server. So far so good, i'm having problems with the following scenario: env.roledefs = { 'dev': ['192.168.0.5'], 'hml': ['192.168.0.5'], ...
1
vote
1answer
51 views

Locust AWS python requirements fails

Folks, Trying to setup Locust in AWS using latest amazon linux. After installing locust, i get the following when starting in master mode: locust -f foo.py --master Traceback (most recent call ...
0
votes
1answer
103 views

Writing a fail2ban multiline regex

I've got some troublesome hosts trying it on with an SSH server I run, and I'm trying to ban them using fail2ban. Problem is, I haven't done much work with regexes, and even less with Python regexes. ...
0
votes
1answer
14 views

Minimizing Downtime With Upgrades For 3rd Party Products

I am currently maintaining a Review Board server (https://www.reviewboard.org/) and one of the big pain points is scheduling upgrades. Currently the process is: Take the server down and send all ...
1
vote
1answer
607 views

salt-stack : No Top file or external nodes data matches found

To test salt-stack I would like to copy a config file to another distant one (I am testing master and minion in localhost) /etc/salt/minion : master: 127.0.0.1 file_roots: base: - ...