~onlineservices-charmers/charms/precise/gunicorn/trunk

« back to all changes in this revision

Viewing changes to hooks/wsgi-file-relation-joined

  • Committer: Robert Ayres
  • Date: 2013-01-24 23:02:38 UTC
  • mfrom: (25.1.1 gunicorn)
  • Revision ID: robert.ayres@canonical.com-20130124230238-plvp2rpsobxtn5eb
Merge in Patrick's changes

Show diffs side-by-side

added added

removed removed

Lines of Context:
43
43
fi
44
44
 
45
45
# If running in wsgi mode then set a default wsgi file
46
 
if [[ $mode -eq "wsgi" ]] && [[ $(relation-get $wsgi_wsgi_file) -eq "" ]] ; then
47
 
    ${VAR[wsgi_wsgi_file]}="wsgi"
 
46
if [[ $mode -eq "wsgi" ]] && [[ $(relation-get wsgi_wsgi_file) -eq "" ]] ; then
 
47
    VAR[wsgi_wsgi_file]="wsgi"
48
48
fi
49
49
 
50
50
if [[ -n ${VAR[wsgi_wsgi_file]} ]] ; then
54
54
if [[ -z ${VAR[python_path]} ]] ; then
55
55
    python_path=${working_dir}
56
56
else
57
 
    python_path=${VAR[python_path]}
 
57
    python_path="${VAR[python_path]}"
58
58
fi
59
59
 
60
60
juju-log "Writing config file: /etc/gunicorn.d/${unit_name}.conf"
99
99
service gunicorn restart
100
100
 
101
101
juju-log "Opening port: ${VAR[port]}"
102
 
open-port ${VAR[port]}/tcp
 
102
open-port "${VAR[port]}/tcp"