alcapon 0.4.19 → 0.4.20
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 +4 -4
- data/lib/capez.rb +5 -2
- data/lib/db.rb +9 -2
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b92a43fae39dbb8b326cc9b3a7439a31e1b79cb2
|
|
4
|
+
data.tar.gz: 2db80db8094c078064dd68321c8f5a4f3ac0edb5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1885270dbe52835133985669434b1014a737f787d20e81779b6c2840cf6dceab98aa0ef430d842dc77309f7debfcd12e38ebca49e17ecb94585962e8956c7055
|
|
7
|
+
data.tar.gz: 74f35aa287347fd224a9e9c733b33b9aee9247790324af223e9c18a2d6c131fddece72bcbe47e8a45f3317a5ba7cd62f3fe54e7dd608b8e30531667adc47356d
|
data/lib/capez.rb
CHANGED
|
@@ -337,7 +337,9 @@ namespace :ezpublish do
|
|
|
337
337
|
DESC
|
|
338
338
|
task :sync_to_local, :roles => :web, :only => { :primary => true } do
|
|
339
339
|
puts "Cluster mode : " + (fetch( :ezdfs_mount_path, nil ) == nil ? "no".red : "yes".green )
|
|
340
|
-
|
|
340
|
+
puts "You're about to sync your local storage directory FROM a remote one"
|
|
341
|
+
puts "Selected stage : " + "#{stage}".green
|
|
342
|
+
confirmation = Capistrano::CLI.ui.ask "Are you sure (y/N) ?"
|
|
341
343
|
abort "Aborted" unless confirmation.downcase == 'y'
|
|
342
344
|
|
|
343
345
|
shared_host = fetch( :shared_host, nil )
|
|
@@ -352,7 +354,8 @@ namespace :ezpublish do
|
|
|
352
354
|
}
|
|
353
355
|
run_locally( "rsync -az #{exclude_string} #{user}@#{shared_host}:#{shared_path}/var/* " + ezp_legacy_path( "var/" ) )
|
|
354
356
|
else
|
|
355
|
-
puts "Syncing remote mount path
|
|
357
|
+
puts "Syncing remote mount path"
|
|
358
|
+
puts "Path (on both side) : " + ezdfs_mount_path.green
|
|
356
359
|
storage_directories.each{ |sd|
|
|
357
360
|
print_dotted( "var/#{sd}/storage" )
|
|
358
361
|
fullpath = "#{ezdfs_mount_path}/var/#{sd}/storage"
|
data/lib/db.rb
CHANGED
|
@@ -3,7 +3,9 @@ namespace :db do
|
|
|
3
3
|
Loads one of the backup made with the db:export:remote task
|
|
4
4
|
DESC
|
|
5
5
|
task :import_to_local do
|
|
6
|
-
|
|
6
|
+
puts "You are about to replace your local database by a remote backup"
|
|
7
|
+
puts "Selected stage : " + "#{stage}".green
|
|
8
|
+
confirmation = Capistrano::CLI.ui.ask "Are you sure ? y/n (n)"
|
|
7
9
|
if confirmation == "n" or confirmation == ""
|
|
8
10
|
abort "Aborted"
|
|
9
11
|
end
|
|
@@ -13,7 +15,11 @@ namespace :db do
|
|
|
13
15
|
files = Hash.new
|
|
14
16
|
i = 1
|
|
15
17
|
backup_files.each { |value|
|
|
16
|
-
|
|
18
|
+
if fetch( :ezdfs_database_name, nil ) != nil && value =~ /#{ezdfs_database_name}/i
|
|
19
|
+
puts "#{i}: #{value} " + "[ezdfs database]".blue
|
|
20
|
+
else
|
|
21
|
+
puts "#{i}: #{value} " + "[content database]".green
|
|
22
|
+
end
|
|
17
23
|
files[i] = value
|
|
18
24
|
i += 1
|
|
19
25
|
}
|
|
@@ -75,6 +81,7 @@ namespace :db do
|
|
|
75
81
|
|
|
76
82
|
def do_and_retrieve_backup( thisdbserver, thisdbname, thisdbuser, thisdbpass )
|
|
77
83
|
filename = generate_backup_name( thisdbname )
|
|
84
|
+
puts "Backing up database ["+thisdbname.green+"] to " + filename.green
|
|
78
85
|
file = File.join( "/tmp", filename )
|
|
79
86
|
backup_dir_for_this_stage = File.join( get_backup_dir, "#{stage}" )
|
|
80
87
|
on_rollback do
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: alcapon
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.4.
|
|
4
|
+
version: 0.4.20
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Arnaud Lafon
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2014-07-
|
|
11
|
+
date: 2014-07-10 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: capistrano
|