backup2sndacs 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile.lock +6 -6
- data/NEWS.md +7 -0
- data/backup2sndacs.gemspec +1 -1
- data/lib/backup/storage/sndacs.rb +3 -3
- data/lib/backup2sndacs/version.rb +1 -1
- metadata +10 -15
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: c9134b24d385da01aca8037368ff0fe2a2d46a65
|
4
|
+
data.tar.gz: 5e8471edc12b653b21bba8772513a585286cabf9
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: e70184defca8e9eecfa732afa7d796c83846ae6e297c0c173d170e7cb7b30b8e70702ceca79ad47817ac7e1ea11a15cd9acba071ed2031f75d2934666a0b435a
|
7
|
+
data.tar.gz: 83532ddd5bc113a235b4a9ad7791840cd68792f351da5e0f74cad6cdc7e8adbbacb3437a19e73c2b55d895368886ae8a9d6b72aa2932eff7d6888c9b4a5386e6
|
data/Gemfile.lock
CHANGED
@@ -1,23 +1,23 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
backup2sndacs (0.
|
5
|
-
backup (~> 3.0)
|
4
|
+
backup2sndacs (0.2.0)
|
5
|
+
backup (~> 3.1.0)
|
6
6
|
sndacs (~> 0.2.0)
|
7
7
|
|
8
8
|
GEM
|
9
9
|
remote: https://rubygems.org/
|
10
10
|
specs:
|
11
|
-
backup (3.
|
11
|
+
backup (3.1.3)
|
12
12
|
open4 (~> 1.3.0)
|
13
|
-
thor (
|
14
|
-
mime-types (1.
|
13
|
+
thor (>= 0.15.4, < 2)
|
14
|
+
mime-types (1.21)
|
15
15
|
open4 (1.3.0)
|
16
16
|
proxies (0.2.1)
|
17
17
|
sndacs (0.2.4)
|
18
18
|
mime-types
|
19
19
|
proxies (~> 0.2.0)
|
20
|
-
thor (0.
|
20
|
+
thor (0.17.0)
|
21
21
|
|
22
22
|
PLATFORMS
|
23
23
|
ruby
|
data/NEWS.md
ADDED
data/backup2sndacs.gemspec
CHANGED
@@ -16,6 +16,6 @@ Gem::Specification.new do |gem|
|
|
16
16
|
gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
|
17
17
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
18
18
|
gem.require_paths = ["lib"]
|
19
|
-
gem.add_dependency 'backup', '~> 3.0'
|
19
|
+
gem.add_dependency 'backup', '~> 3.1.0'
|
20
20
|
gem.add_dependency 'sndacs', '~> 0.2.0'
|
21
21
|
end
|
@@ -23,7 +23,7 @@ module Backup
|
|
23
23
|
def remove!(pkg)
|
24
24
|
remote_path = remote_path_for(pkg)
|
25
25
|
transferred_files_for(pkg) do |local_file, remote_file|
|
26
|
-
Logger.
|
26
|
+
Logger.info "#{storage_name} started removing " +
|
27
27
|
"'#{ local_file }' from bucket '#{ bucket }'."
|
28
28
|
key = File.join(remote_path, remote_file)
|
29
29
|
res = bucket_service.objects.find(key).destroy
|
@@ -36,14 +36,14 @@ module Backup
|
|
36
36
|
def transfer!
|
37
37
|
remote_path = remote_path_for(@package)
|
38
38
|
files_to_transfer_for(@package) do |local_file, remote_file|
|
39
|
-
Logger.
|
39
|
+
Logger.info "#{storage_name} started transferring " +
|
40
40
|
"'#{ local_file }'."
|
41
41
|
key = File.join(remote_path, remote_file)
|
42
42
|
o = bucket_service.objects.build(key)
|
43
43
|
o.content = open(File.join(local_path, local_file))
|
44
44
|
res = o.save
|
45
45
|
raise "upload '#{local_file}' failed" unless res == true
|
46
|
-
Logger.
|
46
|
+
Logger.info "file uploaded to bucket:#{bucket}, key:#{key}"
|
47
47
|
end
|
48
48
|
end
|
49
49
|
|
metadata
CHANGED
@@ -1,36 +1,32 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: backup2sndacs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
5
|
-
prerelease:
|
4
|
+
version: 0.2.0
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- LI Daobing
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2013-03-26 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: backup
|
16
15
|
requirement: !ruby/object:Gem::Requirement
|
17
|
-
none: false
|
18
16
|
requirements:
|
19
17
|
- - ~>
|
20
18
|
- !ruby/object:Gem::Version
|
21
|
-
version:
|
19
|
+
version: 3.1.0
|
22
20
|
type: :runtime
|
23
21
|
prerelease: false
|
24
22
|
version_requirements: !ruby/object:Gem::Requirement
|
25
|
-
none: false
|
26
23
|
requirements:
|
27
24
|
- - ~>
|
28
25
|
- !ruby/object:Gem::Version
|
29
|
-
version:
|
26
|
+
version: 3.1.0
|
30
27
|
- !ruby/object:Gem::Dependency
|
31
28
|
name: sndacs
|
32
29
|
requirement: !ruby/object:Gem::Requirement
|
33
|
-
none: false
|
34
30
|
requirements:
|
35
31
|
- - ~>
|
36
32
|
- !ruby/object:Gem::Version
|
@@ -38,7 +34,6 @@ dependencies:
|
|
38
34
|
type: :runtime
|
39
35
|
prerelease: false
|
40
36
|
version_requirements: !ruby/object:Gem::Requirement
|
41
|
-
none: false
|
42
37
|
requirements:
|
43
38
|
- - ~>
|
44
39
|
- !ruby/object:Gem::Version
|
@@ -54,6 +49,7 @@ files:
|
|
54
49
|
- Gemfile
|
55
50
|
- Gemfile.lock
|
56
51
|
- LICENSE.txt
|
52
|
+
- NEWS.md
|
57
53
|
- README.md
|
58
54
|
- Rakefile
|
59
55
|
- backup2sndacs.gemspec
|
@@ -63,27 +59,26 @@ files:
|
|
63
59
|
- lib/backup2sndacs/version.rb
|
64
60
|
homepage: https://github.com/lidaobing/backup2sndacs
|
65
61
|
licenses: []
|
62
|
+
metadata: {}
|
66
63
|
post_install_message:
|
67
64
|
rdoc_options: []
|
68
65
|
require_paths:
|
69
66
|
- lib
|
70
67
|
required_ruby_version: !ruby/object:Gem::Requirement
|
71
|
-
none: false
|
72
68
|
requirements:
|
73
|
-
- -
|
69
|
+
- - '>='
|
74
70
|
- !ruby/object:Gem::Version
|
75
71
|
version: '0'
|
76
72
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
77
|
-
none: false
|
78
73
|
requirements:
|
79
|
-
- -
|
74
|
+
- - '>='
|
80
75
|
- !ruby/object:Gem::Version
|
81
76
|
version: '0'
|
82
77
|
requirements: []
|
83
78
|
rubyforge_project:
|
84
|
-
rubygems_version:
|
79
|
+
rubygems_version: 2.0.2
|
85
80
|
signing_key:
|
86
|
-
specification_version:
|
81
|
+
specification_version: 4
|
87
82
|
summary: backup to http://www.grandcloud.cn/product/ecs
|
88
83
|
test_files: []
|
89
84
|
has_rdoc:
|