capistrano-exts 1.1.4 → 1.1.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.
- data/examples/php_fpm/deploy/development.rb +1 -2
- data/examples/php_fpm/deploy/production.rb +1 -2
- data/examples/php_fpm/deploy/staging.rb +1 -2
- data/examples/rails_passenger/deploy/development.rb +1 -2
- data/examples/rails_passenger/deploy/production.rb +1 -2
- data/examples/rails_passenger/deploy/staging.rb +1 -2
- data/examples/rails_reverse_proxy/deploy/development.rb +1 -2
- data/examples/rails_reverse_proxy/deploy/production.rb +1 -2
- data/examples/rails_reverse_proxy/deploy/staging.rb +2 -2
- data/lib/capistrano-exts/receipts/contao.rb +5 -0
- data/lib/capistrano-exts/receipts/servers/web_server.rb +13 -3
- data/lib/capistrano-exts/templates/multistage.rb +1 -2
- data/lib/capistrano-exts/version.rb +1 -1
- metadata +15 -15
@@ -23,10 +23,9 @@ set :branch, "master"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
30
29
|
|
31
30
|
# How should we deploy?
|
32
31
|
# Valid options:
|
@@ -23,10 +23,9 @@ set :branch, "production"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
30
29
|
|
31
30
|
# How should we deploy?
|
32
31
|
# Valid options:
|
@@ -23,10 +23,9 @@ set :branch, "staging"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
30
29
|
|
31
30
|
# How should we deploy?
|
32
31
|
# Valid options:
|
@@ -23,10 +23,9 @@ set :branch, "master"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
30
29
|
|
31
30
|
# How should we deploy?
|
32
31
|
# Valid options:
|
@@ -23,10 +23,9 @@ set :branch, "production"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
30
29
|
|
31
30
|
# How should we deploy?
|
32
31
|
# Valid options:
|
@@ -23,10 +23,9 @@ set :branch, "staging"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
30
29
|
|
31
30
|
# How should we deploy?
|
32
31
|
# Valid options:
|
@@ -23,10 +23,9 @@ set :branch, "master"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
30
29
|
|
31
30
|
# How should we deploy?
|
32
31
|
# Valid options:
|
@@ -23,10 +23,9 @@ set :branch, "production"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
30
29
|
|
31
30
|
# How should we deploy?
|
32
31
|
# Valid options:
|
@@ -23,10 +23,10 @@ set :branch, "staging"
|
|
23
23
|
set :use_sudo, false
|
24
24
|
|
25
25
|
# Define deployments options
|
26
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
27
26
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
28
27
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
29
|
-
set :public_path, -> { "#{fetch :
|
28
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
29
|
+
|
30
30
|
# How should we deploy?
|
31
31
|
# Valid options:
|
32
32
|
# => checkout: this deployment strategy does an SCM checkout on each target
|
@@ -74,6 +74,11 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
74
74
|
task :fix_links, :roles => :app, :except => { :no_release => true } do
|
75
75
|
contents_path = fetch :contents_path, "#{fetch :public_path}/tl_files/contents"
|
76
76
|
|
77
|
+
# At this point, the current_path does not exists and by running an mkdir
|
78
|
+
# later, we're actually breaking stuff.
|
79
|
+
# So replace current_path with latest_release in the contents_path string
|
80
|
+
contents_path.gsub!(%r{#{current_path}}, fetch(:latest_release))
|
81
|
+
|
77
82
|
# Remove files
|
78
83
|
run <<-CMD
|
79
84
|
#{try_sudo} rm -f #{contents_path} &&
|
@@ -46,17 +46,21 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
46
46
|
if exists?(:web_server_auth_credentials)
|
47
47
|
web_server_auth_credentials = fetch :web_server_auth_credentials
|
48
48
|
contents = Array.new
|
49
|
+
unencrypted_contents = Array.new
|
49
50
|
|
50
51
|
web_server_auth_credentials.each do |credentials|
|
51
52
|
if credentials[:password].is_a?(Proc)
|
52
|
-
password = credentials[:password].call
|
53
|
+
password = credentials[:password].call
|
53
54
|
else
|
54
|
-
password = credentials[:password]
|
55
|
+
password = credentials[:password]
|
55
56
|
end
|
56
|
-
|
57
|
+
|
58
|
+
unencrypted_contents << "#{credentials[:user]}:#{password}"
|
59
|
+
contents << "#{credentials[:user]}:#{password.crypt(gen_pass(8))}"
|
57
60
|
end
|
58
61
|
|
59
62
|
set :web_server_auth_file_contents, contents.join("\n")
|
63
|
+
set :web_server_auth_file_unencrypted_contents, unencrypted_contents.join("\n")
|
60
64
|
end
|
61
65
|
end
|
62
66
|
|
@@ -70,6 +74,7 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
70
74
|
if exists?(:web_server_auth_file)
|
71
75
|
web_server_auth_file = fetch :web_server_auth_file
|
72
76
|
web_server_auth_file_contents = fetch :web_server_auth_file_contents
|
77
|
+
web_server_auth_file_unencrypted_contents = fetch :web_server_auth_file_unencrypted_contents
|
73
78
|
random_file = random_tmp_file web_server_auth_file_contents
|
74
79
|
|
75
80
|
run <<-CMD
|
@@ -81,6 +86,11 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
81
86
|
run <<-CMD
|
82
87
|
#{try_sudo} mv #{random_file} #{web_server_auth_file}
|
83
88
|
CMD
|
89
|
+
|
90
|
+
# Store the unencrypted version of the contents
|
91
|
+
put web_server_auth_file_unencrypted_contents, "#{fetch :deploy_to}/.http_basic_auth"
|
92
|
+
puts "This site uses http basic auth, the credentials are:"
|
93
|
+
puts web_server_auth_file_unencrypted_contents
|
84
94
|
end
|
85
95
|
end
|
86
96
|
|
@@ -20,10 +20,9 @@ set :branch, "master"
|
|
20
20
|
set :use_sudo, false
|
21
21
|
|
22
22
|
# Define deployments options
|
23
|
-
# NOTE: Do not use current_path here but use latest_release instead.
|
24
23
|
set :deploy_to, -> { "/home/vhosts/#{fetch :stage}/#{fetch :application}" }
|
25
24
|
set :logs_path, -> { "#{fetch :deploy_to}/logs" }
|
26
|
-
set :public_path, -> { "#{fetch :
|
25
|
+
set :public_path, -> { "#{fetch :current_path}/public" }
|
27
26
|
|
28
27
|
# How should we deploy?
|
29
28
|
# Valid options:
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capistrano-exts
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.5
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -13,7 +13,7 @@ date: 2011-09-03 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: capistrano
|
16
|
-
requirement: &
|
16
|
+
requirement: &2157484500 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: 2.8.0
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *2157484500
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: i18n
|
27
|
-
requirement: &
|
27
|
+
requirement: &2157484000 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: 0.6.0
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *2157484000
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: activesupport
|
38
|
-
requirement: &
|
38
|
+
requirement: &2157483540 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ! '>='
|
@@ -43,10 +43,10 @@ dependencies:
|
|
43
43
|
version: 3.1.0
|
44
44
|
type: :runtime
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *2157483540
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: guard
|
49
|
-
requirement: &
|
49
|
+
requirement: &2157483080 !ruby/object:Gem::Requirement
|
50
50
|
none: false
|
51
51
|
requirements:
|
52
52
|
- - ! '>='
|
@@ -54,10 +54,10 @@ dependencies:
|
|
54
54
|
version: 0.6.2
|
55
55
|
type: :development
|
56
56
|
prerelease: false
|
57
|
-
version_requirements: *
|
57
|
+
version_requirements: *2157483080
|
58
58
|
- !ruby/object:Gem::Dependency
|
59
59
|
name: guard-bundler
|
60
|
-
requirement: &
|
60
|
+
requirement: &2157482620 !ruby/object:Gem::Requirement
|
61
61
|
none: false
|
62
62
|
requirements:
|
63
63
|
- - ! '>='
|
@@ -65,10 +65,10 @@ dependencies:
|
|
65
65
|
version: 0.1.3
|
66
66
|
type: :development
|
67
67
|
prerelease: false
|
68
|
-
version_requirements: *
|
68
|
+
version_requirements: *2157482620
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: guard-rspec
|
71
|
-
requirement: &
|
71
|
+
requirement: &2157482160 !ruby/object:Gem::Requirement
|
72
72
|
none: false
|
73
73
|
requirements:
|
74
74
|
- - ! '>='
|
@@ -76,10 +76,10 @@ dependencies:
|
|
76
76
|
version: 0.4.3
|
77
77
|
type: :development
|
78
78
|
prerelease: false
|
79
|
-
version_requirements: *
|
79
|
+
version_requirements: *2157482160
|
80
80
|
- !ruby/object:Gem::Dependency
|
81
81
|
name: rspec
|
82
|
-
requirement: &
|
82
|
+
requirement: &2157481700 !ruby/object:Gem::Requirement
|
83
83
|
none: false
|
84
84
|
requirements:
|
85
85
|
- - ! '>='
|
@@ -87,7 +87,7 @@ dependencies:
|
|
87
87
|
version: 2.6.0
|
88
88
|
type: :development
|
89
89
|
prerelease: false
|
90
|
-
version_requirements: *
|
90
|
+
version_requirements: *2157481700
|
91
91
|
description: Handy extensions for Capistrano
|
92
92
|
email:
|
93
93
|
- wael.nasreddine@gmail.com
|