Skip to content

Commit 635ce73

Browse files
author
Phil Sturgeon
committed
Fix deprecation warnings in template
1 parent b23f0e6 commit 635ce73

1 file changed

Lines changed: 14 additions & 14 deletions

File tree

templates/gunicorn.erb

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,36 @@
11
CONFIG = {
2-
<% if mode == 'django' -%>
2+
<% if @mode == 'django' -%>
33
'mode': 'django',
44
<% else -%>
55
'mode': 'wsgi',
66
<% end -%>
7-
<% if virtualenv -%>
7+
<% if @virtualenv -%>
88
'environment': {
9-
<% if environment -%>
10-
'ENVIRONMENT': '<%= environment %>',
9+
<% if @environment -%>
10+
'ENVIRONMENT': '<%= @environment %>',
1111
<% end -%>
12-
'PYTHONPATH': '<%= virtualenv %>'
12+
'PYTHONPATH': '<%= @virtualenv %>'
1313
},
1414
<% end -%>
15-
'working_dir': '<%= dir %>',
15+
'working_dir': '<%= @dir %>',
1616
'user': 'www-data',
1717
'group': 'www-data',
18-
<% if virtualenv -%>
19-
'python': '<%= virtualenv %>/bin/python',
18+
<% if @virtualenv -%>
19+
'python': '<%= @virtualenv %>/bin/python',
2020
<% else -%>
2121
'python': '/usr/bin/python',
2222
<% end -%>
2323
'args': (
24-
<% if !virtualenv and !bind -%>
25-
'--bind=unix:/tmp/gunicorn-<%= name %>.socket',
26-
<% elsif virtualenv and !bind -%>
27-
'--bind=unix:<%= virtualenv %>/<%= name %>.socket',
24+
<% if !@virtualenv and !@bind -%>
25+
'--bind=unix:/tmp/gunicorn-<%= @name %>.socket',
26+
<% elsif @virtualenv and !@bind -%>
27+
'--bind=unix:<%= @virtualenv %>/<%= @name %>.socket',
2828
<% else -%>
29-
'--bind=<%= bind %>',
29+
'--bind=<%= @bind %>',
3030
<% end -%>
3131
'--workers=<%= @processorcount.to_i*2 %>',
3232
'--timeout=30',
33-
<% if mode != 'django' -%>
33+
<% if @mode != 'django' -%>
3434
'app:app',
3535
<% end -%>
3636
),

0 commit comments

Comments
 (0)