capistrano3-puma 0.7.0 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a2255db8f6e5e8f22eb484c40fe6c5848e436a35
|
4
|
+
data.tar.gz: 37a20cc815d7df734b26cdefe9a0dfbd500e6912
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4dcf652c3a5db23dfe7236a175220bc51174bd79a713bc04130fb273999aaea7a90ad2a50c0320be3b00b239758b700a9520f10448f7ca95cdd315c56c5b3467
|
7
|
+
data.tar.gz: ecd46e7275d169a1be620cbcebeb3327288f57bd8ff9d080ba994909ed1f71306446874dfc65565aab2f6b7c3a33482c8d1f4971d3ec61407ed71452b971721f
|
@@ -1,8 +1,8 @@
|
|
1
|
-
namespace :
|
1
|
+
namespace :puma do
|
2
2
|
desc "Setup nginx configuration"
|
3
|
-
task :
|
4
|
-
on roles(:puma_nginx) do
|
5
|
-
template_puma("nginx_conf", "/tmp/nginx_#{fetch(:nginx_config_name)}")
|
3
|
+
task :nginx_config do
|
4
|
+
on roles(:puma_nginx) do |role|
|
5
|
+
template_puma("nginx_conf", "/tmp/nginx_#{fetch(:nginx_config_name)}", role)
|
6
6
|
sudo :mv, "/tmp/nginx_#{fetch(:nginx_config_name)} #{fetch(:nginx_sites_available_path)}/#{fetch(:nginx_config_name)}"
|
7
7
|
sudo :ln, '-fs', "#{fetch(:nginx_sites_available_path)}/#{fetch(:nginx_config_name)} #{fetch(:nginx_sites_enabled_path)}/#{fetch(:nginx_config_name)}"
|
8
8
|
end
|
@@ -27,7 +27,9 @@ namespace :load do
|
|
27
27
|
set :nginx_sites_available_path, -> { '/etc/nginx/sites-available' }
|
28
28
|
set :nginx_sites_enabled_path, -> { '/etc/nginx/sites-enabled' }
|
29
29
|
set :nginx_server_name, -> { "localhost #{fetch(:application)}.local" }
|
30
|
-
|
30
|
+
set :nginx_flags, -> { 'fail_timeout=0' }
|
31
|
+
set :nginx_http_flags, -> { fetch(:nginx_flags) }
|
32
|
+
set :nginx_socket_flags, -> { fetch(:nginx_flags) }
|
31
33
|
end
|
32
34
|
end
|
33
35
|
|
@@ -1,5 +1,15 @@
|
|
1
|
-
upstream puma_<%= fetch(:nginx_config_name) %> {
|
2
|
-
|
1
|
+
upstream puma_<%= fetch(:nginx_config_name) %> { <%
|
2
|
+
flags = 'fail_timeout=0'
|
3
|
+
@backends = [fetch(:puma_bind)].flatten.map do |m|
|
4
|
+
etype, address = /(tcp|unix|ssl):\/\/(.+)/.match(m).captures
|
5
|
+
if etype =='unix'
|
6
|
+
"server #{etype}:#{address} #{fetch(:nginx_socket_flags)};"
|
7
|
+
else
|
8
|
+
"server #{address.gsub(/0\.0\.0\.0(.+)/, "127.0.0.1\\1")} #{fetch(:nginx_http_flags)};"
|
9
|
+
end
|
10
|
+
end
|
11
|
+
%><% @backends.each do |server| %>
|
12
|
+
<%= server %><% end %>
|
3
13
|
}
|
4
14
|
|
5
15
|
server {
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capistrano3-puma
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Abdelkader Boudih
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-09-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: capistrano
|
@@ -93,9 +93,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
93
93
|
version: '0'
|
94
94
|
requirements: []
|
95
95
|
rubyforge_project:
|
96
|
-
rubygems_version: 2.
|
96
|
+
rubygems_version: 2.2.2
|
97
97
|
signing_key:
|
98
98
|
specification_version: 4
|
99
99
|
summary: Puma integration for Capistrano
|
100
100
|
test_files: []
|
101
|
-
has_rdoc:
|