capistrano 2.0.0 → 2.15.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitignore +10 -0
- data/.travis.yml +7 -0
- data/CHANGELOG +737 -18
- data/Gemfile +13 -0
- data/README.md +94 -0
- data/Rakefile +11 -0
- data/bin/cap +0 -0
- data/bin/capify +37 -22
- data/capistrano.gemspec +40 -0
- data/lib/capistrano/callback.rb +5 -1
- data/lib/capistrano/cli/execute.rb +10 -7
- data/lib/capistrano/cli/help.rb +39 -16
- data/lib/capistrano/cli/help.txt +44 -16
- data/lib/capistrano/cli/options.rb +71 -11
- data/lib/capistrano/cli/ui.rb +13 -1
- data/lib/capistrano/cli.rb +5 -5
- data/lib/capistrano/command.rb +215 -58
- data/lib/capistrano/configuration/actions/file_transfer.rb +29 -14
- data/lib/capistrano/configuration/actions/inspect.rb +3 -3
- data/lib/capistrano/configuration/actions/invocation.rb +224 -22
- data/lib/capistrano/configuration/alias_task.rb +26 -0
- data/lib/capistrano/configuration/callbacks.rb +26 -27
- data/lib/capistrano/configuration/connections.rb +130 -52
- data/lib/capistrano/configuration/execution.rb +34 -18
- data/lib/capistrano/configuration/loading.rb +99 -6
- data/lib/capistrano/configuration/log_formatters.rb +75 -0
- data/lib/capistrano/configuration/namespaces.rb +45 -12
- data/lib/capistrano/configuration/roles.rb +28 -2
- data/lib/capistrano/configuration/servers.rb +51 -10
- data/lib/capistrano/configuration/variables.rb +3 -3
- data/lib/capistrano/configuration.rb +20 -4
- data/lib/capistrano/errors.rb +12 -8
- data/lib/capistrano/ext/multistage.rb +67 -0
- data/lib/capistrano/ext/string.rb +5 -0
- data/lib/capistrano/extensions.rb +1 -1
- data/lib/capistrano/fix_rake_deprecated_dsl.rb +8 -0
- data/lib/capistrano/logger.rb +112 -5
- data/lib/capistrano/processable.rb +55 -0
- data/lib/capistrano/recipes/compat.rb +2 -2
- data/lib/capistrano/recipes/deploy/assets.rb +201 -0
- data/lib/capistrano/recipes/deploy/dependencies.rb +2 -2
- data/lib/capistrano/recipes/deploy/local_dependency.rb +10 -2
- data/lib/capistrano/recipes/deploy/remote_dependency.rb +54 -2
- data/lib/capistrano/recipes/deploy/scm/accurev.rb +169 -0
- data/lib/capistrano/recipes/deploy/scm/base.rb +31 -11
- data/lib/capistrano/recipes/deploy/scm/bzr.rb +14 -14
- data/lib/capistrano/recipes/deploy/scm/cvs.rb +11 -9
- data/lib/capistrano/recipes/deploy/scm/darcs.rb +12 -1
- data/lib/capistrano/recipes/deploy/scm/git.rb +293 -0
- data/lib/capistrano/recipes/deploy/scm/mercurial.rb +23 -15
- data/lib/capistrano/recipes/deploy/scm/none.rb +55 -0
- data/lib/capistrano/recipes/deploy/scm/perforce.rb +54 -28
- data/lib/capistrano/recipes/deploy/scm/subversion.rb +36 -18
- data/lib/capistrano/recipes/deploy/scm.rb +1 -1
- data/lib/capistrano/recipes/deploy/strategy/base.rb +32 -4
- data/lib/capistrano/recipes/deploy/strategy/copy.rb +238 -43
- data/lib/capistrano/recipes/deploy/strategy/remote.rb +1 -1
- data/lib/capistrano/recipes/deploy/strategy/remote_cache.rb +11 -1
- data/lib/capistrano/recipes/deploy/strategy/unshared_remote_cache.rb +21 -0
- data/lib/capistrano/recipes/deploy/strategy.rb +1 -1
- data/lib/capistrano/recipes/deploy.rb +265 -123
- data/lib/capistrano/recipes/standard.rb +1 -1
- data/lib/capistrano/role.rb +102 -0
- data/lib/capistrano/server_definition.rb +6 -1
- data/lib/capistrano/shell.rb +30 -33
- data/lib/capistrano/ssh.rb +46 -60
- data/lib/capistrano/task_definition.rb +16 -8
- data/lib/capistrano/transfer.rb +218 -0
- data/lib/capistrano/version.rb +6 -17
- data/lib/capistrano.rb +4 -1
- data/test/cli/execute_test.rb +3 -3
- data/test/cli/help_test.rb +33 -7
- data/test/cli/options_test.rb +109 -6
- data/test/cli/ui_test.rb +2 -2
- data/test/cli_test.rb +3 -3
- data/test/command_test.rb +144 -124
- data/test/configuration/actions/file_transfer_test.rb +41 -20
- data/test/configuration/actions/inspect_test.rb +21 -7
- data/test/configuration/actions/invocation_test.rb +123 -30
- data/test/configuration/alias_task_test.rb +118 -0
- data/test/configuration/callbacks_test.rb +41 -46
- data/test/configuration/connections_test.rb +187 -36
- data/test/configuration/execution_test.rb +18 -2
- data/test/configuration/loading_test.rb +33 -4
- data/test/configuration/namespace_dsl_test.rb +54 -5
- data/test/configuration/roles_test.rb +114 -4
- data/test/configuration/servers_test.rb +97 -4
- data/test/configuration/variables_test.rb +12 -2
- data/test/configuration_test.rb +9 -13
- data/test/deploy/local_dependency_test.rb +76 -0
- data/test/deploy/remote_dependency_test.rb +146 -0
- data/test/deploy/scm/accurev_test.rb +23 -0
- data/test/deploy/scm/base_test.rb +1 -1
- data/test/deploy/scm/bzr_test.rb +51 -0
- data/test/deploy/scm/darcs_test.rb +37 -0
- data/test/deploy/scm/git_test.rb +274 -0
- data/test/deploy/scm/mercurial_test.rb +134 -0
- data/test/deploy/scm/none_test.rb +35 -0
- data/test/deploy/scm/perforce_test.rb +23 -0
- data/test/deploy/scm/subversion_test.rb +68 -0
- data/test/deploy/strategy/copy_test.rb +240 -26
- data/test/extensions_test.rb +2 -2
- data/test/logger_formatting_test.rb +149 -0
- data/test/logger_test.rb +13 -2
- data/test/recipes_test.rb +25 -0
- data/test/role_test.rb +11 -0
- data/test/server_definition_test.rb +15 -2
- data/test/shell_test.rb +33 -1
- data/test/ssh_test.rb +40 -24
- data/test/task_definition_test.rb +18 -2
- data/test/transfer_test.rb +168 -0
- data/test/utils.rb +28 -33
- metadata +215 -101
- data/MIT-LICENSE +0 -20
- data/README +0 -43
- data/examples/sample.rb +0 -14
- data/lib/capistrano/gateway.rb +0 -131
- data/lib/capistrano/recipes/deploy/templates/maintenance.rhtml +0 -53
- data/lib/capistrano/recipes/upgrade.rb +0 -33
- data/lib/capistrano/upload.rb +0 -146
- data/test/gateway_test.rb +0 -167
- data/test/upload_test.rb +0 -131
- data/test/version_test.rb +0 -24
metadata
CHANGED
|
@@ -1,114 +1,195 @@
|
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
|
2
|
-
rubygems_version: 0.9.4
|
|
3
|
-
specification_version: 1
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
4
2
|
name: capistrano
|
|
5
|
-
version: !ruby/object:Gem::Version
|
|
6
|
-
version: 2.
|
|
7
|
-
date: 2007-07-21 00:00:00 -06:00
|
|
8
|
-
summary: Capistrano is a utility and framework for executing commands in parallel on multiple remote machines, via SSH.
|
|
9
|
-
require_paths:
|
|
10
|
-
- lib
|
|
11
|
-
email: jamis@37signals.com
|
|
12
|
-
homepage: http://www.capify.org
|
|
13
|
-
rubyforge_project:
|
|
14
|
-
description:
|
|
15
|
-
autorequire: capistrano
|
|
16
|
-
default_executable:
|
|
17
|
-
bindir: bin
|
|
18
|
-
has_rdoc: false
|
|
19
|
-
required_ruby_version: !ruby/object:Gem::Version::Requirement
|
|
20
|
-
requirements:
|
|
21
|
-
- - ">"
|
|
22
|
-
- !ruby/object:Gem::Version
|
|
23
|
-
version: 0.0.0
|
|
24
|
-
version:
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 2.15.5
|
|
25
5
|
platform: ruby
|
|
26
|
-
|
|
27
|
-
cert_chain:
|
|
28
|
-
post_install_message:
|
|
29
|
-
authors:
|
|
6
|
+
authors:
|
|
30
7
|
- Jamis Buck
|
|
31
|
-
|
|
8
|
+
- Lee Hambley
|
|
9
|
+
autorequire:
|
|
10
|
+
bindir: bin
|
|
11
|
+
cert_chain: []
|
|
12
|
+
date: 2013-07-04 00:00:00.000000000 Z
|
|
13
|
+
dependencies:
|
|
14
|
+
- !ruby/object:Gem::Dependency
|
|
15
|
+
name: highline
|
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
|
17
|
+
requirements:
|
|
18
|
+
- - '>='
|
|
19
|
+
- !ruby/object:Gem::Version
|
|
20
|
+
version: '0'
|
|
21
|
+
type: :runtime
|
|
22
|
+
prerelease: false
|
|
23
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
24
|
+
requirements:
|
|
25
|
+
- - '>='
|
|
26
|
+
- !ruby/object:Gem::Version
|
|
27
|
+
version: '0'
|
|
28
|
+
- !ruby/object:Gem::Dependency
|
|
29
|
+
name: net-ssh
|
|
30
|
+
requirement: !ruby/object:Gem::Requirement
|
|
31
|
+
requirements:
|
|
32
|
+
- - '>='
|
|
33
|
+
- !ruby/object:Gem::Version
|
|
34
|
+
version: 2.0.14
|
|
35
|
+
type: :runtime
|
|
36
|
+
prerelease: false
|
|
37
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
38
|
+
requirements:
|
|
39
|
+
- - '>='
|
|
40
|
+
- !ruby/object:Gem::Version
|
|
41
|
+
version: 2.0.14
|
|
42
|
+
- !ruby/object:Gem::Dependency
|
|
43
|
+
name: net-sftp
|
|
44
|
+
requirement: !ruby/object:Gem::Requirement
|
|
45
|
+
requirements:
|
|
46
|
+
- - '>='
|
|
47
|
+
- !ruby/object:Gem::Version
|
|
48
|
+
version: 2.0.0
|
|
49
|
+
type: :runtime
|
|
50
|
+
prerelease: false
|
|
51
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
52
|
+
requirements:
|
|
53
|
+
- - '>='
|
|
54
|
+
- !ruby/object:Gem::Version
|
|
55
|
+
version: 2.0.0
|
|
56
|
+
- !ruby/object:Gem::Dependency
|
|
57
|
+
name: net-scp
|
|
58
|
+
requirement: !ruby/object:Gem::Requirement
|
|
59
|
+
requirements:
|
|
60
|
+
- - '>='
|
|
61
|
+
- !ruby/object:Gem::Version
|
|
62
|
+
version: 1.0.0
|
|
63
|
+
type: :runtime
|
|
64
|
+
prerelease: false
|
|
65
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
66
|
+
requirements:
|
|
67
|
+
- - '>='
|
|
68
|
+
- !ruby/object:Gem::Version
|
|
69
|
+
version: 1.0.0
|
|
70
|
+
- !ruby/object:Gem::Dependency
|
|
71
|
+
name: net-ssh-gateway
|
|
72
|
+
requirement: !ruby/object:Gem::Requirement
|
|
73
|
+
requirements:
|
|
74
|
+
- - '>='
|
|
75
|
+
- !ruby/object:Gem::Version
|
|
76
|
+
version: 1.1.0
|
|
77
|
+
type: :runtime
|
|
78
|
+
prerelease: false
|
|
79
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
80
|
+
requirements:
|
|
81
|
+
- - '>='
|
|
82
|
+
- !ruby/object:Gem::Version
|
|
83
|
+
version: 1.1.0
|
|
84
|
+
- !ruby/object:Gem::Dependency
|
|
85
|
+
name: mocha
|
|
86
|
+
requirement: !ruby/object:Gem::Requirement
|
|
87
|
+
requirements:
|
|
88
|
+
- - '='
|
|
89
|
+
- !ruby/object:Gem::Version
|
|
90
|
+
version: 0.9.12
|
|
91
|
+
type: :development
|
|
92
|
+
prerelease: false
|
|
93
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
94
|
+
requirements:
|
|
95
|
+
- - '='
|
|
96
|
+
- !ruby/object:Gem::Version
|
|
97
|
+
version: 0.9.12
|
|
98
|
+
description: Capistrano is a utility and framework for executing commands in parallel
|
|
99
|
+
on multiple remote machines, via SSH.
|
|
100
|
+
email:
|
|
101
|
+
- jamis@jamisbuck.org
|
|
102
|
+
- lee.hambley@gmail.com
|
|
103
|
+
executables:
|
|
104
|
+
- cap
|
|
105
|
+
- capify
|
|
106
|
+
extensions: []
|
|
107
|
+
extra_rdoc_files:
|
|
108
|
+
- README.md
|
|
109
|
+
files:
|
|
110
|
+
- .gitignore
|
|
111
|
+
- .travis.yml
|
|
112
|
+
- CHANGELOG
|
|
113
|
+
- Gemfile
|
|
114
|
+
- README.md
|
|
115
|
+
- Rakefile
|
|
32
116
|
- bin/cap
|
|
33
117
|
- bin/capify
|
|
34
|
-
-
|
|
118
|
+
- capistrano.gemspec
|
|
119
|
+
- lib/capistrano.rb
|
|
35
120
|
- lib/capistrano/callback.rb
|
|
36
|
-
- lib/capistrano/cli
|
|
121
|
+
- lib/capistrano/cli.rb
|
|
37
122
|
- lib/capistrano/cli/execute.rb
|
|
38
123
|
- lib/capistrano/cli/help.rb
|
|
39
124
|
- lib/capistrano/cli/help.txt
|
|
40
125
|
- lib/capistrano/cli/options.rb
|
|
41
126
|
- lib/capistrano/cli/ui.rb
|
|
42
|
-
- lib/capistrano/cli.rb
|
|
43
127
|
- lib/capistrano/command.rb
|
|
44
|
-
- lib/capistrano/configuration
|
|
45
|
-
- lib/capistrano/configuration/actions
|
|
128
|
+
- lib/capistrano/configuration.rb
|
|
46
129
|
- lib/capistrano/configuration/actions/file_transfer.rb
|
|
47
130
|
- lib/capistrano/configuration/actions/inspect.rb
|
|
48
131
|
- lib/capistrano/configuration/actions/invocation.rb
|
|
132
|
+
- lib/capistrano/configuration/alias_task.rb
|
|
49
133
|
- lib/capistrano/configuration/callbacks.rb
|
|
50
134
|
- lib/capistrano/configuration/connections.rb
|
|
51
135
|
- lib/capistrano/configuration/execution.rb
|
|
52
136
|
- lib/capistrano/configuration/loading.rb
|
|
137
|
+
- lib/capistrano/configuration/log_formatters.rb
|
|
53
138
|
- lib/capistrano/configuration/namespaces.rb
|
|
54
139
|
- lib/capistrano/configuration/roles.rb
|
|
55
140
|
- lib/capistrano/configuration/servers.rb
|
|
56
141
|
- lib/capistrano/configuration/variables.rb
|
|
57
|
-
- lib/capistrano/configuration.rb
|
|
58
142
|
- lib/capistrano/errors.rb
|
|
143
|
+
- lib/capistrano/ext/multistage.rb
|
|
144
|
+
- lib/capistrano/ext/string.rb
|
|
59
145
|
- lib/capistrano/extensions.rb
|
|
60
|
-
- lib/capistrano/
|
|
146
|
+
- lib/capistrano/fix_rake_deprecated_dsl.rb
|
|
61
147
|
- lib/capistrano/logger.rb
|
|
62
|
-
- lib/capistrano/
|
|
148
|
+
- lib/capistrano/processable.rb
|
|
63
149
|
- lib/capistrano/recipes/compat.rb
|
|
64
|
-
- lib/capistrano/recipes/deploy
|
|
150
|
+
- lib/capistrano/recipes/deploy.rb
|
|
151
|
+
- lib/capistrano/recipes/deploy/assets.rb
|
|
65
152
|
- lib/capistrano/recipes/deploy/dependencies.rb
|
|
66
153
|
- lib/capistrano/recipes/deploy/local_dependency.rb
|
|
67
154
|
- lib/capistrano/recipes/deploy/remote_dependency.rb
|
|
68
|
-
- lib/capistrano/recipes/deploy/scm
|
|
155
|
+
- lib/capistrano/recipes/deploy/scm.rb
|
|
156
|
+
- lib/capistrano/recipes/deploy/scm/accurev.rb
|
|
69
157
|
- lib/capistrano/recipes/deploy/scm/base.rb
|
|
70
158
|
- lib/capistrano/recipes/deploy/scm/bzr.rb
|
|
71
159
|
- lib/capistrano/recipes/deploy/scm/cvs.rb
|
|
72
160
|
- lib/capistrano/recipes/deploy/scm/darcs.rb
|
|
161
|
+
- lib/capistrano/recipes/deploy/scm/git.rb
|
|
73
162
|
- lib/capistrano/recipes/deploy/scm/mercurial.rb
|
|
163
|
+
- lib/capistrano/recipes/deploy/scm/none.rb
|
|
74
164
|
- lib/capistrano/recipes/deploy/scm/perforce.rb
|
|
75
165
|
- lib/capistrano/recipes/deploy/scm/subversion.rb
|
|
76
|
-
- lib/capistrano/recipes/deploy/
|
|
77
|
-
- lib/capistrano/recipes/deploy/strategy
|
|
166
|
+
- lib/capistrano/recipes/deploy/strategy.rb
|
|
78
167
|
- lib/capistrano/recipes/deploy/strategy/base.rb
|
|
79
168
|
- lib/capistrano/recipes/deploy/strategy/checkout.rb
|
|
80
169
|
- lib/capistrano/recipes/deploy/strategy/copy.rb
|
|
81
170
|
- lib/capistrano/recipes/deploy/strategy/export.rb
|
|
82
171
|
- lib/capistrano/recipes/deploy/strategy/remote.rb
|
|
83
172
|
- lib/capistrano/recipes/deploy/strategy/remote_cache.rb
|
|
84
|
-
- lib/capistrano/recipes/deploy/strategy.rb
|
|
85
|
-
- lib/capistrano/recipes/deploy/templates
|
|
86
|
-
- lib/capistrano/recipes/deploy/templates/maintenance.rhtml
|
|
87
|
-
- lib/capistrano/recipes/deploy.rb
|
|
173
|
+
- lib/capistrano/recipes/deploy/strategy/unshared_remote_cache.rb
|
|
88
174
|
- lib/capistrano/recipes/standard.rb
|
|
89
|
-
- lib/capistrano/recipes/templates
|
|
90
175
|
- lib/capistrano/recipes/templates/maintenance.rhtml
|
|
91
|
-
- lib/capistrano/
|
|
176
|
+
- lib/capistrano/role.rb
|
|
92
177
|
- lib/capistrano/server_definition.rb
|
|
93
178
|
- lib/capistrano/shell.rb
|
|
94
179
|
- lib/capistrano/ssh.rb
|
|
95
180
|
- lib/capistrano/task_definition.rb
|
|
96
|
-
- lib/capistrano/
|
|
181
|
+
- lib/capistrano/transfer.rb
|
|
97
182
|
- lib/capistrano/version.rb
|
|
98
|
-
- lib/capistrano.rb
|
|
99
|
-
- examples/sample.rb
|
|
100
|
-
- test/cli
|
|
101
183
|
- test/cli/execute_test.rb
|
|
102
184
|
- test/cli/help_test.rb
|
|
103
185
|
- test/cli/options_test.rb
|
|
104
186
|
- test/cli/ui_test.rb
|
|
105
187
|
- test/cli_test.rb
|
|
106
188
|
- test/command_test.rb
|
|
107
|
-
- test/configuration
|
|
108
|
-
- test/configuration/actions
|
|
109
189
|
- test/configuration/actions/file_transfer_test.rb
|
|
110
190
|
- test/configuration/actions/inspect_test.rb
|
|
111
191
|
- test/configuration/actions/invocation_test.rb
|
|
192
|
+
- test/configuration/alias_task_test.rb
|
|
112
193
|
- test/configuration/callbacks_test.rb
|
|
113
194
|
- test/configuration/connections_test.rb
|
|
114
195
|
- test/configuration/execution_test.rb
|
|
@@ -118,66 +199,99 @@ files:
|
|
|
118
199
|
- test/configuration/servers_test.rb
|
|
119
200
|
- test/configuration/variables_test.rb
|
|
120
201
|
- test/configuration_test.rb
|
|
121
|
-
- test/deploy
|
|
122
|
-
- test/deploy/
|
|
202
|
+
- test/deploy/local_dependency_test.rb
|
|
203
|
+
- test/deploy/remote_dependency_test.rb
|
|
204
|
+
- test/deploy/scm/accurev_test.rb
|
|
123
205
|
- test/deploy/scm/base_test.rb
|
|
124
|
-
- test/deploy/
|
|
206
|
+
- test/deploy/scm/bzr_test.rb
|
|
207
|
+
- test/deploy/scm/darcs_test.rb
|
|
208
|
+
- test/deploy/scm/git_test.rb
|
|
209
|
+
- test/deploy/scm/mercurial_test.rb
|
|
210
|
+
- test/deploy/scm/none_test.rb
|
|
211
|
+
- test/deploy/scm/perforce_test.rb
|
|
212
|
+
- test/deploy/scm/subversion_test.rb
|
|
125
213
|
- test/deploy/strategy/copy_test.rb
|
|
126
214
|
- test/extensions_test.rb
|
|
127
|
-
- test/fixtures
|
|
128
215
|
- test/fixtures/cli_integration.rb
|
|
129
216
|
- test/fixtures/config.rb
|
|
130
217
|
- test/fixtures/custom.rb
|
|
131
|
-
- test/
|
|
218
|
+
- test/logger_formatting_test.rb
|
|
132
219
|
- test/logger_test.rb
|
|
220
|
+
- test/recipes_test.rb
|
|
221
|
+
- test/role_test.rb
|
|
133
222
|
- test/server_definition_test.rb
|
|
134
223
|
- test/shell_test.rb
|
|
135
224
|
- test/ssh_test.rb
|
|
136
225
|
- test/task_definition_test.rb
|
|
137
|
-
- test/
|
|
226
|
+
- test/transfer_test.rb
|
|
138
227
|
- test/utils.rb
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
test_files: []
|
|
144
|
-
|
|
228
|
+
homepage: http://github.com/capistrano/capistrano
|
|
229
|
+
licenses: []
|
|
230
|
+
metadata: {}
|
|
231
|
+
post_install_message:
|
|
145
232
|
rdoc_options: []
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
-
|
|
151
|
-
-
|
|
152
|
-
|
|
153
|
-
|
|
233
|
+
require_paths:
|
|
234
|
+
- lib
|
|
235
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
236
|
+
requirements:
|
|
237
|
+
- - '>='
|
|
238
|
+
- !ruby/object:Gem::Version
|
|
239
|
+
version: '0'
|
|
240
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
241
|
+
requirements:
|
|
242
|
+
- - '>='
|
|
243
|
+
- !ruby/object:Gem::Version
|
|
244
|
+
version: '0'
|
|
154
245
|
requirements: []
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
246
|
+
rubyforge_project:
|
|
247
|
+
rubygems_version: 2.0.3
|
|
248
|
+
signing_key:
|
|
249
|
+
specification_version: 3
|
|
250
|
+
summary: Capistrano - Welcome to easy deployment with Ruby over SSH
|
|
251
|
+
test_files:
|
|
252
|
+
- test/cli/execute_test.rb
|
|
253
|
+
- test/cli/help_test.rb
|
|
254
|
+
- test/cli/options_test.rb
|
|
255
|
+
- test/cli/ui_test.rb
|
|
256
|
+
- test/cli_test.rb
|
|
257
|
+
- test/command_test.rb
|
|
258
|
+
- test/configuration/actions/file_transfer_test.rb
|
|
259
|
+
- test/configuration/actions/inspect_test.rb
|
|
260
|
+
- test/configuration/actions/invocation_test.rb
|
|
261
|
+
- test/configuration/alias_task_test.rb
|
|
262
|
+
- test/configuration/callbacks_test.rb
|
|
263
|
+
- test/configuration/connections_test.rb
|
|
264
|
+
- test/configuration/execution_test.rb
|
|
265
|
+
- test/configuration/loading_test.rb
|
|
266
|
+
- test/configuration/namespace_dsl_test.rb
|
|
267
|
+
- test/configuration/roles_test.rb
|
|
268
|
+
- test/configuration/servers_test.rb
|
|
269
|
+
- test/configuration/variables_test.rb
|
|
270
|
+
- test/configuration_test.rb
|
|
271
|
+
- test/deploy/local_dependency_test.rb
|
|
272
|
+
- test/deploy/remote_dependency_test.rb
|
|
273
|
+
- test/deploy/scm/accurev_test.rb
|
|
274
|
+
- test/deploy/scm/base_test.rb
|
|
275
|
+
- test/deploy/scm/bzr_test.rb
|
|
276
|
+
- test/deploy/scm/darcs_test.rb
|
|
277
|
+
- test/deploy/scm/git_test.rb
|
|
278
|
+
- test/deploy/scm/mercurial_test.rb
|
|
279
|
+
- test/deploy/scm/none_test.rb
|
|
280
|
+
- test/deploy/scm/perforce_test.rb
|
|
281
|
+
- test/deploy/scm/subversion_test.rb
|
|
282
|
+
- test/deploy/strategy/copy_test.rb
|
|
283
|
+
- test/extensions_test.rb
|
|
284
|
+
- test/fixtures/cli_integration.rb
|
|
285
|
+
- test/fixtures/config.rb
|
|
286
|
+
- test/fixtures/custom.rb
|
|
287
|
+
- test/logger_formatting_test.rb
|
|
288
|
+
- test/logger_test.rb
|
|
289
|
+
- test/recipes_test.rb
|
|
290
|
+
- test/role_test.rb
|
|
291
|
+
- test/server_definition_test.rb
|
|
292
|
+
- test/shell_test.rb
|
|
293
|
+
- test/ssh_test.rb
|
|
294
|
+
- test/task_definition_test.rb
|
|
295
|
+
- test/transfer_test.rb
|
|
296
|
+
- test/utils.rb
|
|
297
|
+
has_rdoc:
|
data/MIT-LICENSE
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
Copyright (c) 2005-2007 Jamis Buck <jamis@37signals.com>
|
|
2
|
-
|
|
3
|
-
Permission is hereby granted, free of charge, to any person obtaining
|
|
4
|
-
a copy of this software and associated documentation files (the
|
|
5
|
-
"Software"), to deal in the Software without restriction, including
|
|
6
|
-
without limitation the rights to use, copy, modify, merge, publish,
|
|
7
|
-
distribute, sublicense, and/or sell copies of the Software, and to
|
|
8
|
-
permit persons to whom the Software is furnished to do so, subject to
|
|
9
|
-
the following conditions:
|
|
10
|
-
|
|
11
|
-
The above copyright notice and this permission notice shall be
|
|
12
|
-
included in all copies or substantial portions of the Software.
|
|
13
|
-
|
|
14
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
15
|
-
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
16
|
-
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
17
|
-
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
|
18
|
-
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
|
19
|
-
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
|
20
|
-
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README
DELETED
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
= Capistrano
|
|
2
|
-
|
|
3
|
-
Capistrano is a utility and framework for executing commands in parallel on multiple remote machines, via SSH. It uses a simple DSL (borrowed in part from Rake, http://rake.rubyforge.org/) that allows you to define _tasks_, which may be applied to machines in certain roles. It also supports tunneling connections via some gateway machine to allow operations to be performed behind VPN's and firewalls.
|
|
4
|
-
|
|
5
|
-
Capistrano was originally designed to simplify and automate deployment of web applications to distributed environments, and originally came bundled with a set of tasks designed for deploying Rails applications. The deployment tasks are now (as of Capistrano 2.0) opt-in and require clients to explicitly put
|
|
6
|
-
"load 'deploy'" in their recipes.
|
|
7
|
-
|
|
8
|
-
== Dependencies
|
|
9
|
-
|
|
10
|
-
* Net::SSH and Net::SFTP (http://net-ssh.rubyforge.org)
|
|
11
|
-
* Needle (via Net::SSH)
|
|
12
|
-
* HighLine (http://highline.rubyforge.org)
|
|
13
|
-
|
|
14
|
-
If you want to run the tests, you'll also need to have the following dependencies installed:
|
|
15
|
-
|
|
16
|
-
* Mocha (http://mocha.rubyforge.org)
|
|
17
|
-
|
|
18
|
-
== Assumptions
|
|
19
|
-
|
|
20
|
-
Capistrano is "opinionated software", which means it has very firm ideas about how things ought to be done, and tries to force those ideas on you. Some of the assumptions behind these opinions are:
|
|
21
|
-
|
|
22
|
-
* You are using SSH to access the remote servers.
|
|
23
|
-
* You either have the same password to all target machines, or you have public keys in place to allow passwordless access to them.
|
|
24
|
-
|
|
25
|
-
Do not expect these assumptions to change.
|
|
26
|
-
|
|
27
|
-
== Usage
|
|
28
|
-
|
|
29
|
-
In general, you'll use Capistrano as follows:
|
|
30
|
-
|
|
31
|
-
* Create a recipe file ("capfile" or "Capfile").
|
|
32
|
-
* Use the +cap+ script to execute your recipe.
|
|
33
|
-
|
|
34
|
-
Use the +cap+ script as follows:
|
|
35
|
-
|
|
36
|
-
cap sometask
|
|
37
|
-
|
|
38
|
-
By default, the script will look for a file called one of +capfile+ or +Capfile+. The +someaction+ text indicates which task to execute. You can do "cap -h" to see all the available options and "cap -T" to see all the available tasks.
|
|
39
|
-
|
|
40
|
-
== KNOWN ISSUES
|
|
41
|
-
|
|
42
|
-
* Using "put" to upload a file to two or more hosts when a gateway is in effect has a good chance of crashing with a "corrupt mac detected" error. This is due to a bug in Net::SSH.
|
|
43
|
-
* Running commands may rarely hang inexplicably. This appears to be specific only to certain platforms. Most people will never see this behavior.
|
data/examples/sample.rb
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
# set :user, "flippy"
|
|
2
|
-
# set :password, "hello-flippy"
|
|
3
|
-
# set :gateway, "gateway.example.com"
|
|
4
|
-
|
|
5
|
-
role :web, "web1.example.com"
|
|
6
|
-
role :app, "app1.example.com", "app2.example.com"
|
|
7
|
-
|
|
8
|
-
desc <<-DESC
|
|
9
|
-
This is a sample task. It is only intended to be used as a demonstration of \
|
|
10
|
-
how you can define your own tasks.
|
|
11
|
-
DESC
|
|
12
|
-
task :sample_task, :roles => :app do
|
|
13
|
-
run "ls -l"
|
|
14
|
-
end
|
data/lib/capistrano/gateway.rb
DELETED
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
if RUBY_VERSION == "1.8.6"
|
|
2
|
-
begin
|
|
3
|
-
require 'fastthread'
|
|
4
|
-
rescue LoadError
|
|
5
|
-
warn "You are running Ruby 1.8.6, which has a bug in its threading implementation."
|
|
6
|
-
warn "You are liable to encounter deadlocks running Capistrano, unless you install"
|
|
7
|
-
warn "the fastthread library, which is available as a gem:"
|
|
8
|
-
warn " gem install fastthread"
|
|
9
|
-
end
|
|
10
|
-
end
|
|
11
|
-
|
|
12
|
-
require 'thread'
|
|
13
|
-
require 'capistrano/errors'
|
|
14
|
-
require 'capistrano/ssh'
|
|
15
|
-
require 'capistrano/server_definition'
|
|
16
|
-
|
|
17
|
-
Thread.abort_on_exception = true
|
|
18
|
-
|
|
19
|
-
module Capistrano
|
|
20
|
-
|
|
21
|
-
# Black magic. It uses threads and Net::SSH to set up a connection to a
|
|
22
|
-
# gateway server, through which connections to other servers may be
|
|
23
|
-
# tunnelled.
|
|
24
|
-
#
|
|
25
|
-
# It is used internally by Capistrano, but may be useful on its own, as well.
|
|
26
|
-
#
|
|
27
|
-
# Usage:
|
|
28
|
-
#
|
|
29
|
-
# gateway = Capistrano::Gateway.new(Capistrano::ServerDefinition.new('gateway.example.com'))
|
|
30
|
-
#
|
|
31
|
-
# sess1 = gateway.connect_to(Capistrano::ServerDefinition.new('hidden.example.com'))
|
|
32
|
-
# sess2 = gateway.connect_to(Capistrano::ServerDefinition.new('other.example.com'))
|
|
33
|
-
class Gateway
|
|
34
|
-
# The Thread instance driving the gateway connection.
|
|
35
|
-
attr_reader :thread
|
|
36
|
-
|
|
37
|
-
# The Net::SSH session representing the gateway connection.
|
|
38
|
-
attr_reader :session
|
|
39
|
-
|
|
40
|
-
MAX_PORT = 65535
|
|
41
|
-
MIN_PORT = 1024
|
|
42
|
-
|
|
43
|
-
def initialize(server, options={}) #:nodoc:
|
|
44
|
-
@options = options
|
|
45
|
-
@next_port = MAX_PORT
|
|
46
|
-
@terminate_thread = false
|
|
47
|
-
@port_guard = Mutex.new
|
|
48
|
-
|
|
49
|
-
mutex = Mutex.new
|
|
50
|
-
waiter = ConditionVariable.new
|
|
51
|
-
|
|
52
|
-
mutex.synchronize do
|
|
53
|
-
@thread = Thread.new do
|
|
54
|
-
logger.trace "starting connection to gateway `#{server}'" if logger
|
|
55
|
-
SSH.connect(server, @options) do |@session|
|
|
56
|
-
logger.trace "gateway connection established" if logger
|
|
57
|
-
mutex.synchronize { waiter.signal }
|
|
58
|
-
@session.loop do
|
|
59
|
-
!@terminate_thread
|
|
60
|
-
end
|
|
61
|
-
end
|
|
62
|
-
end
|
|
63
|
-
|
|
64
|
-
waiter.wait(mutex)
|
|
65
|
-
end
|
|
66
|
-
end
|
|
67
|
-
|
|
68
|
-
# Shuts down all forwarded connections and terminates the gateway.
|
|
69
|
-
def shutdown!
|
|
70
|
-
# cancel all active forward channels
|
|
71
|
-
session.forward.active_locals.each do |lport, host, port|
|
|
72
|
-
session.forward.cancel_local(lport)
|
|
73
|
-
end
|
|
74
|
-
|
|
75
|
-
# terminate the gateway thread
|
|
76
|
-
@terminate_thread = true
|
|
77
|
-
|
|
78
|
-
# wait for the gateway thread to stop
|
|
79
|
-
thread.join
|
|
80
|
-
end
|
|
81
|
-
|
|
82
|
-
# Connects to the given server by opening a forwarded port from the local
|
|
83
|
-
# host to the server, via the gateway, and then opens and returns a new
|
|
84
|
-
# Net::SSH connection via that port.
|
|
85
|
-
def connect_to(server)
|
|
86
|
-
connection = nil
|
|
87
|
-
logger.debug "establishing connection to `#{server}' via gateway" if logger
|
|
88
|
-
local_port = next_port
|
|
89
|
-
|
|
90
|
-
thread = Thread.new do
|
|
91
|
-
begin
|
|
92
|
-
local_host = ServerDefinition.new("127.0.0.1", :user => server.user, :port => local_port)
|
|
93
|
-
session.forward.local(local_port, server.host, server.port || 22)
|
|
94
|
-
connection = SSH.connect(local_host, @options)
|
|
95
|
-
connection.xserver = server
|
|
96
|
-
logger.trace "connected: `#{server}' (via gateway)" if logger
|
|
97
|
-
rescue Errno::EADDRINUSE
|
|
98
|
-
local_port = next_port
|
|
99
|
-
retry
|
|
100
|
-
rescue Exception => e
|
|
101
|
-
warn "#{e.class}: #{e.message}"
|
|
102
|
-
warn e.backtrace.join("\n")
|
|
103
|
-
end
|
|
104
|
-
end
|
|
105
|
-
|
|
106
|
-
thread.join
|
|
107
|
-
if connection.nil?
|
|
108
|
-
error = ConnectionError.new("could not establish connection to `#{server}'")
|
|
109
|
-
error.hosts = [server]
|
|
110
|
-
raise error
|
|
111
|
-
end
|
|
112
|
-
|
|
113
|
-
connection
|
|
114
|
-
end
|
|
115
|
-
|
|
116
|
-
private
|
|
117
|
-
|
|
118
|
-
def logger
|
|
119
|
-
@options[:logger]
|
|
120
|
-
end
|
|
121
|
-
|
|
122
|
-
def next_port
|
|
123
|
-
@port_guard.synchronize do
|
|
124
|
-
port = @next_port
|
|
125
|
-
@next_port -= 1
|
|
126
|
-
@next_port = MAX_PORT if @next_port < MIN_PORT
|
|
127
|
-
port
|
|
128
|
-
end
|
|
129
|
-
end
|
|
130
|
-
end
|
|
131
|
-
end
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
3
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
4
|
-
|
|
5
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
6
|
-
|
|
7
|
-
<head>
|
|
8
|
-
<meta http-equiv="content-type" content="text/html;charset=UTF-8" />
|
|
9
|
-
<title>System down for maintenance</title>
|
|
10
|
-
|
|
11
|
-
<style type="text/css">
|
|
12
|
-
div.outer {
|
|
13
|
-
position: absolute;
|
|
14
|
-
left: 50%;
|
|
15
|
-
top: 50%;
|
|
16
|
-
width: 500px;
|
|
17
|
-
height: 300px;
|
|
18
|
-
margin-left: -260px;
|
|
19
|
-
margin-top: -150px;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
.DialogBody {
|
|
23
|
-
margin: 0;
|
|
24
|
-
padding: 10px;
|
|
25
|
-
text-align: left;
|
|
26
|
-
border: 1px solid #ccc;
|
|
27
|
-
border-right: 1px solid #999;
|
|
28
|
-
border-bottom: 1px solid #999;
|
|
29
|
-
background-color: #fff;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
body { background-color: #fff; }
|
|
33
|
-
</style>
|
|
34
|
-
</head>
|
|
35
|
-
|
|
36
|
-
<body>
|
|
37
|
-
|
|
38
|
-
<div class="outer">
|
|
39
|
-
<div class="DialogBody" style="text-align: center;">
|
|
40
|
-
<div style="text-align: center; width: 200px; margin: 0 auto;">
|
|
41
|
-
<p style="color: red; font-size: 16px; line-height: 20px;">
|
|
42
|
-
The system is down for <%= reason ? reason : "maintenance" %>
|
|
43
|
-
as of <%= Time.now.strftime("%H:%M %Z") %>.
|
|
44
|
-
</p>
|
|
45
|
-
<p style="color: #666;">
|
|
46
|
-
It'll be back <%= deadline ? deadline : "shortly" %>.
|
|
47
|
-
</p>
|
|
48
|
-
</div>
|
|
49
|
-
</div>
|
|
50
|
-
</div>
|
|
51
|
-
|
|
52
|
-
</body>
|
|
53
|
-
</html>
|