alcapon 0.4.1 → 0.4.2
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/bin/capezit +3 -0
- data/lib/capez.rb +0 -28
- data/lib/ezpublish4.rb +33 -1
- data/lib/ezpublish5.rb +46 -1
- metadata +2 -2
data/bin/capezit
CHANGED
@@ -139,6 +139,9 @@ files = {
|
|
139
139
|
# If not set, permissions remain unchanged
|
140
140
|
#set :shared_children_group, "#{webserver_group}"
|
141
141
|
|
142
|
+
# eZ Publish 5 only: assets configuration (default is 'web')
|
143
|
+
#set :ezp5_assets_path, 'web'
|
144
|
+
|
142
145
|
# Which autoloads to generate. By default, regenerates extensions and
|
143
146
|
# kernel-override autoloads
|
144
147
|
# Possible values : see bin/php/ezpgenerateautoloads.php --help
|
data/lib/capez.rb
CHANGED
@@ -62,17 +62,6 @@ before "deploy:finalize_update" do
|
|
62
62
|
run( "mkdir -p #{latest_release}/#{ezp_legacy_path('var')}" )
|
63
63
|
end
|
64
64
|
|
65
|
-
after "deploy:finalize_update" do
|
66
|
-
if fetch( :shared_children_group, false )
|
67
|
-
shared_children.map { |d| run( "chgrp -R #{shared_children_group} #{shared_path}/#{d.split('/').last}") }
|
68
|
-
end
|
69
|
-
capez.var.init_release
|
70
|
-
capez.var.link
|
71
|
-
capez.settings.deploy
|
72
|
-
capez.autoloads.generate
|
73
|
-
#capez.cache.clear
|
74
|
-
end
|
75
|
-
|
76
65
|
before "deploy", :roles => :web do
|
77
66
|
capez.dev.local_check
|
78
67
|
deploy.web.disable
|
@@ -233,23 +222,6 @@ namespace :capez do
|
|
233
222
|
|
234
223
|
end
|
235
224
|
|
236
|
-
namespace :cache do
|
237
|
-
desc <<-DESC
|
238
|
-
Clear caches the way it is configured in ezpublish.rb
|
239
|
-
DESC
|
240
|
-
# Caches are just cleared for the primary server
|
241
|
-
# Multiple server platform are supposed to use a cluster configuration (eZDFS/eZDBFS)
|
242
|
-
# and cache management is done via expiry.php which is managed by the cluster API
|
243
|
-
task :clear, :roles => :web, :only => { :primary => true } do
|
244
|
-
puts( "\n--> Clearing caches #{'with --purge'.red if cache_purge}" )
|
245
|
-
cache_list.each { |cache_tag|
|
246
|
-
print_dotted( "#{cache_tag}" )
|
247
|
-
capture "cd #{current_path}/#{ezpublish_legacy} && sudo -u #{webserver_user} php bin/php/ezcache.php --clear-tag=#{cache_tag}#{' --purge' if cache_purge}"
|
248
|
-
puts( " OK".green )
|
249
|
-
}
|
250
|
-
end
|
251
|
-
end
|
252
|
-
|
253
225
|
namespace :var do
|
254
226
|
desc <<-DESC
|
255
227
|
Creates the needed folder within your remote(s) var directories
|
data/lib/ezpublish4.rb
CHANGED
@@ -1,3 +1,35 @@
|
|
1
1
|
puts "Running AlCapON for eZ Publish 4"
|
2
2
|
|
3
|
-
set :ezp_legacy, ""
|
3
|
+
set :ezp_legacy, ""
|
4
|
+
|
5
|
+
after "deploy:finalize_update" do
|
6
|
+
if fetch( :shared_children_group, false )
|
7
|
+
shared_children.map { |d| run( "chgrp -R #{shared_children_group} #{shared_path}/#{d.split('/').last}") }
|
8
|
+
end
|
9
|
+
capez.var.init_release
|
10
|
+
capez.var.link
|
11
|
+
capez.settings.deploy
|
12
|
+
capez.autoloads.generate
|
13
|
+
#capez.cache.clear
|
14
|
+
end
|
15
|
+
|
16
|
+
namespace :capez do
|
17
|
+
|
18
|
+
namespace :cache do
|
19
|
+
desc <<-DESC
|
20
|
+
Clear caches the way it is configured in ezpublish.rb
|
21
|
+
DESC
|
22
|
+
# Caches are just cleared for the primary server
|
23
|
+
# Multiple server platform are supposed to use a cluster configuration (eZDFS/eZDBFS)
|
24
|
+
# and cache management is done via expiry.php which is managed by the cluster API
|
25
|
+
task :clear, :roles => :web, :only => { :primary => true } do
|
26
|
+
puts( "\n--> Clearing caches #{'with --purge'.red if cache_purge}" )
|
27
|
+
cache_list.each { |cache_tag|
|
28
|
+
print_dotted( "#{cache_tag}" )
|
29
|
+
capture "cd #{current_path}/#{ezp_legacy_path} && sudo -u #{webserver_user} php bin/php/ezcache.php --clear-tag=#{cache_tag}#{' --purge' if cache_purge}"
|
30
|
+
puts( " OK".green )
|
31
|
+
}
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
end
|
data/lib/ezpublish5.rb
CHANGED
@@ -1,4 +1,49 @@
|
|
1
1
|
puts "Running AlCapON for eZ Publish 5"
|
2
2
|
|
3
3
|
set :ezp_legacy, "ezpublish_legacy"
|
4
|
-
set :ezp_app, "ezpublish"
|
4
|
+
set :ezp_app, "ezpublish"
|
5
|
+
|
6
|
+
after "deploy:finalize_update" do
|
7
|
+
if fetch( :shared_children_group, false )
|
8
|
+
shared_children.map { |d| run( "chgrp -R #{shared_children_group} #{shared_path}/#{d.split('/').last}") }
|
9
|
+
end
|
10
|
+
capez.var.init_release
|
11
|
+
capez.var.link
|
12
|
+
capez.settings.deploy
|
13
|
+
capez.autoloads.generate
|
14
|
+
capez.assets.install
|
15
|
+
end
|
16
|
+
|
17
|
+
namespace :capez do
|
18
|
+
|
19
|
+
namespace :cache do
|
20
|
+
desc <<-DESC
|
21
|
+
Clear caches the way it is configured in ezpublish.rb
|
22
|
+
DESC
|
23
|
+
# Caches are just cleared for the primary server
|
24
|
+
# Multiple server platform are supposed to use a cluster configuration (eZDFS/eZDBFS)
|
25
|
+
# and cache management is done via expiry.php which is managed by the cluster API
|
26
|
+
# TODO : make it ezp5 aware
|
27
|
+
task :clear, :roles => :web, :only => { :primary => true } do
|
28
|
+
puts( "\n--> Clearing caches #{'with --purge'.red if cache_purge}" )
|
29
|
+
cache_list.each { |cache_tag|
|
30
|
+
print_dotted( "#{cache_tag}" )
|
31
|
+
capture "cd #{current_path}/#{ezp_legacy_path} && sudo -u #{webserver_user} php bin/php/ezcache.php --clear-tag=#{cache_tag}#{' --purge' if cache_purge}"
|
32
|
+
puts( " OK".green )
|
33
|
+
}
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
37
|
+
namespace :assets do
|
38
|
+
desc <<-DESC
|
39
|
+
Install assets (ezp5 only)
|
40
|
+
DESC
|
41
|
+
task :install do
|
42
|
+
|
43
|
+
run( "php ezpublish/console assets:install --symlink #{fetch('ezp5_assets_path','web')}", :as => webserver_user )
|
44
|
+
run( "php ezpublish/console ezpublish:legacy:assets_install --symlink #{fetch('ezp5_assets_path','web')}", :as => webserver_user )
|
45
|
+
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
end
|