le1t0-deprec 2.1.6.022 → 2.1.6.023
Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG
CHANGED
@@ -1,5 +1,12 @@
|
|
1
1
|
# deprec changelog
|
2
2
|
|
3
|
+
= 2.1.6.023 (Jul 14, 2010)
|
4
|
+
|
5
|
+
* added db seed and db redo tasks to rails recipe
|
6
|
+
* added server_aliases setting to passenger recipe
|
7
|
+
* add setting RackEnv in passenger
|
8
|
+
* add to known hosts for IP addresses as well as hostnames for SSH recipe
|
9
|
+
|
3
10
|
= 2.1.6.022 (Jul 7, 2010)
|
4
11
|
|
5
12
|
* add to known hosts for IP addresses as well as hostnames for nagios recipe
|
@@ -25,6 +25,7 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
25
25
|
set :passenger_rails_autodetect, 'on'
|
26
26
|
set :passenger_rails_spawn_method, 'smart' # smart | conservative
|
27
27
|
set :passenger_version, '2.2.11'
|
28
|
+
set :passenger_server_aliases, [ ]
|
28
29
|
|
29
30
|
desc "Install passenger"
|
30
31
|
task :install, :roles => :app do
|
data/lib/deprec/recipes/rails.rb
CHANGED
@@ -306,6 +306,16 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
306
306
|
run "cd #{deploy_to}/current && rake db:create RAILS_ENV=#{rails_env}"
|
307
307
|
end
|
308
308
|
|
309
|
+
desc "Seed database"
|
310
|
+
task :seed, :roles => :app do
|
311
|
+
run "cd #{deploy_to}/current && rake db:seed RAILS_ENV=#{rails_env}"
|
312
|
+
end
|
313
|
+
|
314
|
+
desc "Redo database, only available if defined in your app"
|
315
|
+
task :redo, :roles => :app do
|
316
|
+
run "cd #{deploy_to}/current && rake db:redo RAILS_ENV=#{rails_env}"
|
317
|
+
end
|
318
|
+
|
309
319
|
desc "Run database migrations"
|
310
320
|
task :migrate, :roles => :app do
|
311
321
|
run "cd #{deploy_to}/current && rake db:migrate RAILS_ENV=#{rails_env}"
|
data/lib/deprec/recipes/ssh.rb
CHANGED
@@ -68,9 +68,12 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
68
68
|
run "mv ~/.ssh/authorized_keys.new ~/.ssh/authorized_keys"
|
69
69
|
end
|
70
70
|
|
71
|
+
require 'socket'
|
71
72
|
if ssh_known_hosts.size > 0
|
72
|
-
|
73
|
-
|
73
|
+
hosts_and_ips = (ssh_known_hosts + ssh_known_hosts.collect { |h| Socket.getaddrinfo(h, 0, Socket::AF_INET, Socket::SOCK_STREAM, Socket::IPPROTO_TCP, Socket::INADDR_ANY).first[3] })
|
74
|
+
put (hosts_and_ips + [""]).join("\n"), tmp_file = "/tmp/ssh_keyscan_#{Time.now.strftime("%Y%m%d%H%M%S")}.txt", :mode => 0644
|
75
|
+
run "ssh-keyscan -f #{tmp_file} -t rsa > ~/.ssh/known_hosts"
|
76
|
+
run "rm -f #{tmp_file}"
|
74
77
|
end
|
75
78
|
end
|
76
79
|
|
@@ -2,14 +2,15 @@
|
|
2
2
|
<IfModule passenger_module>
|
3
3
|
<VirtualHost *:80>
|
4
4
|
ServerName <%= domain %>
|
5
|
-
<%-
|
6
|
-
ServerAlias <%=
|
5
|
+
<%- passenger_server_aliases.each do |server_alias| -%>
|
6
|
+
ServerAlias <%= server_alias %>
|
7
7
|
<%- end %>
|
8
8
|
DocumentRoot "<%= passenger_document_root %>"
|
9
9
|
CustomLog <%= apache_log_dir %>/<%= application %>-access.log combined
|
10
10
|
ErrorLog <%= apache_log_dir %>/<%= application %>-error.log
|
11
11
|
|
12
12
|
RailsEnv <%= rails_env %>
|
13
|
+
RackEnv <%= rails_env %>
|
13
14
|
# RailsAllowModRewrite <%= passenger_rails_allow_mod_rewrite %>
|
14
15
|
#
|
15
16
|
# Check for maintenance file and redirect all requests
|
metadata
CHANGED
@@ -6,8 +6,8 @@ version: !ruby/object:Gem::Version
|
|
6
6
|
- 2
|
7
7
|
- 1
|
8
8
|
- 6
|
9
|
-
-
|
10
|
-
version: 2.1.6.
|
9
|
+
- 23
|
10
|
+
version: 2.1.6.023
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Le1t0
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-07-
|
18
|
+
date: 2010-07-14 00:00:00 +02:00
|
19
19
|
default_executable: depify
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|