Skip to content

Commit

Permalink
uwsgi test file added
Browse files Browse the repository at this point in the history
  • Loading branch information
mattfield11 committed Mar 14, 2017
1 parent 2792396 commit 274d06b
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 9 deletions.
12 changes: 6 additions & 6 deletions bin/backup_scripts/ldap_backup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ BACKUP_DIR=/home/zibawabackup/ldap
SLAPCAT=/usr/sbin/slapcat

FINAL_BACKUP_DIR=$BACKUP_DIR"`date +\%Y-\%m-\%d`-daily/"

echo "Making backup directory in $FINAL_BACKUP_DIR"

if ! mkdir -p $FINAL_BACKUP_DIR; then
echo "Cannot create backup directory in $FINAL_BACKUP_DIR. Go and fix it!" 1>&2
exit 1;
fi;
echo "Making backup directory in $FINAL_BACKUP_DIR"

if ! mkdir -p $FINAL_BACKUP_DIR; then
echo "Cannot create backup directory in $FINAL_BACKUP_DIR. Go and fix it!" 1>&2
exit 1;
fi;


nice ${SLAPCAT} -n 0 > ${FINAL_BACKUP_DIR}/config.ldif
Expand Down
12 changes: 12 additions & 0 deletions test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
'''
Created on Nov 30, 2016
@author: julimatt
'''
#this is a test file to check uwsgi and can be deleted without affecting zibawa


def application(env, start_response):
start_response('200 OK', [('Content-Type','text/html')])
return [b"Hello World"] # python3
#return ["Hello World"] # python2
6 changes: 3 additions & 3 deletions zibawa_uwsgi.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@

# Django-related settings
# the base directory (full path) to the directory where manage.py is
chdir = /home/django/iotadmin/iotadmin
chdir = /home/zibawa/zibawa/zibawa
# Django's wsgi file !!! not sure about what this should be try iotadmin.wsgi
#module = project.wsgi
module = iotadmin.wsgi
module = zibawa.wsgi
# the virtualenv (full path) I commented out because not using...
#home = /path/to/virtualenv

Expand All @@ -18,7 +18,7 @@ master = true
# maximum number of worker processes
processes = 10
# the socket (use the full path to be safe
socket = /tmp/iotadmin.sock
socket = /tmp/zibawa.sock
# ... with appropriate permissions - may be needed
chmod-socket = 660
# clear environment on exit
Expand Down

0 comments on commit 274d06b

Please sign in to comment.