rest-ftp-daemon 0.246.1 → 0.247.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +23 -22
- data/lib/rest-ftp-daemon/api/jobs.rb +10 -2
- data/lib/rest-ftp-daemon/constants.rb +1 -1
- data/lib/rest-ftp-daemon/job.rb +3 -0
- data/lib/rest-ftp-daemon/paginate.rb +2 -2
- data/lib/rest-ftp-daemon/static/css/main.css +17 -1
- data/lib/rest-ftp-daemon/views/dashboard_jobs.haml +14 -15
- data/rest-ftp-daemon.gemspec +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dfea42c67617035fca1a3f0abcab1b09c427ef99
|
4
|
+
data.tar.gz: 8b722e96c9971953698baafbb68b6e008e36672d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f2b49246644f04c9bb5ded2ffc17e059b249ceaf561be6c558f7192454d9d79deb5014b2f8af0be8b73956b169de4b8b08a62efdde7b0bb28a690ea6e8330340
|
7
|
+
data.tar.gz: 2b3026c4ee0d5a8a31136b52eca6f9a1a4a1f919967f74881a5e221e7dc8c27ace0596831878b5097f5c919e3640d4a485967d520edd73f52b1848ffcad55159
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
rest-ftp-daemon (0.
|
4
|
+
rest-ftp-daemon (0.247.0)
|
5
5
|
double-bag-ftps
|
6
6
|
facter
|
7
7
|
get_process_mem
|
@@ -19,7 +19,7 @@ GEM
|
|
19
19
|
remote: http://rubygems.org/
|
20
20
|
specs:
|
21
21
|
CFPropertyList (2.2.8)
|
22
|
-
activesupport (4.2.
|
22
|
+
activesupport (4.2.6)
|
23
23
|
i18n (~> 0.7)
|
24
24
|
json (~> 1.7, >= 1.7.7)
|
25
25
|
minitest (~> 5.1)
|
@@ -34,39 +34,40 @@ GEM
|
|
34
34
|
ice_nine (~> 0.11.0)
|
35
35
|
thread_safe (~> 0.3, >= 0.3.1)
|
36
36
|
builder (3.2.2)
|
37
|
-
coderay (1.1.
|
37
|
+
coderay (1.1.1)
|
38
38
|
coercible (1.0.0)
|
39
39
|
descendants_tracker (~> 0.0.1)
|
40
40
|
daemons (1.2.3)
|
41
41
|
descendants_tracker (0.0.4)
|
42
42
|
thread_safe (~> 0.3, >= 0.3.1)
|
43
43
|
diff-lcs (1.2.5)
|
44
|
-
domain_name (0.5.
|
44
|
+
domain_name (0.5.20160310)
|
45
45
|
unf (>= 0.0.5, < 1.0.0)
|
46
46
|
double-bag-ftps (0.1.2)
|
47
|
+
enumerable-lazy (0.0.1)
|
47
48
|
equalizer (0.0.11)
|
48
|
-
eventmachine (1.0.
|
49
|
+
eventmachine (1.2.0.1)
|
49
50
|
facter (2.4.6)
|
50
51
|
CFPropertyList (~> 2.2.6)
|
51
52
|
ffi (1.9.10)
|
52
53
|
get_process_mem (0.2.0)
|
53
|
-
grape (0.
|
54
|
+
grape (0.16.2)
|
54
55
|
activesupport
|
55
56
|
builder
|
56
57
|
hashie (>= 2.1.0)
|
57
58
|
multi_json (>= 1.3.2)
|
58
59
|
multi_xml (>= 0.5.2)
|
60
|
+
mustermann19 (~> 0.4.3)
|
59
61
|
rack (>= 1.3.0)
|
60
62
|
rack-accept
|
61
|
-
rack-mount
|
62
63
|
virtus (>= 1.0.0)
|
63
|
-
grape-entity (0.5.
|
64
|
+
grape-entity (0.5.1)
|
64
65
|
activesupport
|
65
66
|
multi_json (>= 1.3.2)
|
66
67
|
haml (4.0.7)
|
67
68
|
tilt
|
68
|
-
hashie (3.4.
|
69
|
-
http (0.9.
|
69
|
+
hashie (3.4.4)
|
70
|
+
http (0.9.9)
|
70
71
|
addressable (~> 2.3)
|
71
72
|
http-cookie (~> 1.0)
|
72
73
|
http-form_data (~> 1.0.1)
|
@@ -76,17 +77,19 @@ GEM
|
|
76
77
|
http-form_data (1.0.1)
|
77
78
|
http_parser.rb (0.6.0)
|
78
79
|
i18n (0.7.0)
|
79
|
-
ice_nine (0.11.
|
80
|
+
ice_nine (0.11.2)
|
80
81
|
json (1.8.3)
|
81
82
|
method_source (0.8.2)
|
82
83
|
minitest (5.8.4)
|
83
|
-
multi_json (1.
|
84
|
+
multi_json (1.12.0)
|
84
85
|
multi_xml (0.5.5)
|
86
|
+
mustermann19 (0.4.3)
|
87
|
+
enumerable-lazy
|
85
88
|
net-sftp (2.1.2)
|
86
89
|
net-ssh (>= 2.6.5)
|
87
|
-
net-ssh (3.
|
88
|
-
newrelic_rpm (3.
|
89
|
-
parser (2.3.0
|
90
|
+
net-ssh (3.1.1)
|
91
|
+
newrelic_rpm (3.15.2.317)
|
92
|
+
parser (2.3.1.0)
|
90
93
|
ast (~> 2.2)
|
91
94
|
powerpack (0.1.1)
|
92
95
|
pry (0.10.3)
|
@@ -96,15 +99,13 @@ GEM
|
|
96
99
|
rack (1.6.4)
|
97
100
|
rack-accept (0.4.5)
|
98
101
|
rack (>= 0.4)
|
99
|
-
rack-mount (0.8.3)
|
100
|
-
rack (>= 1.0.0)
|
101
102
|
rainbow (2.1.0)
|
102
|
-
rake (
|
103
|
+
rake (11.1.2)
|
103
104
|
rspec (3.4.0)
|
104
105
|
rspec-core (~> 3.4.0)
|
105
106
|
rspec-expectations (~> 3.4.0)
|
106
107
|
rspec-mocks (~> 3.4.0)
|
107
|
-
rspec-core (3.4.
|
108
|
+
rspec-core (3.4.4)
|
108
109
|
rspec-support (~> 3.4.0)
|
109
110
|
rspec-expectations (3.4.0)
|
110
111
|
diff-lcs (>= 1.2.0, < 2.0)
|
@@ -119,7 +120,7 @@ GEM
|
|
119
120
|
powerpack (~> 0.1)
|
120
121
|
rainbow (>= 1.99.1, < 3.0)
|
121
122
|
ruby-progressbar (~> 1.4)
|
122
|
-
ruby-progressbar (1.
|
123
|
+
ruby-progressbar (1.8.0)
|
123
124
|
settingslogic (2.0.9)
|
124
125
|
slop (3.6.0)
|
125
126
|
sys-cpu (0.7.2)
|
@@ -134,7 +135,7 @@ GEM
|
|
134
135
|
thread_safe (~> 0.1)
|
135
136
|
unf (0.1.4)
|
136
137
|
unf_ext
|
137
|
-
unf_ext (0.0.7.
|
138
|
+
unf_ext (0.0.7.2)
|
138
139
|
virtus (1.0.5)
|
139
140
|
axiom-types (~> 0.1)
|
140
141
|
coercible (~> 1.0)
|
@@ -150,7 +151,7 @@ DEPENDENCIES
|
|
150
151
|
pry
|
151
152
|
rake
|
152
153
|
rest-ftp-daemon!
|
153
|
-
rspec
|
154
|
+
rspec
|
154
155
|
rubocop (~> 0.32.0)
|
155
156
|
|
156
157
|
BUNDLED WITH
|
@@ -23,13 +23,21 @@ module RestFtpDaemon
|
|
23
23
|
|
24
24
|
desc "Read job with ID"
|
25
25
|
params do
|
26
|
-
requires :id, type: String, desc: "ID of the Job to read"
|
26
|
+
requires :id, type: String, desc: "ID of the Job to read"#, regexp: /[^\/]+$//
|
27
27
|
end
|
28
28
|
get "/*id" do
|
29
29
|
begin
|
30
30
|
# Get job to display
|
31
31
|
raise RestFtpDaemon::JobNotFound if params[:id].nil?
|
32
|
-
|
32
|
+
|
33
|
+
# Find using matched parts
|
34
|
+
if params[:format]
|
35
|
+
job = $queue.find_by_id("#{params[:id]}.#{params[:format]}", false)
|
36
|
+
else
|
37
|
+
job = $queue.find_by_id(params[:id], true)
|
38
|
+
end
|
39
|
+
|
40
|
+
# Fail if none found
|
33
41
|
raise RestFtpDaemon::JobNotFound if job.nil?
|
34
42
|
|
35
43
|
rescue RestFtpDaemon::JobNotFound => exception
|
data/lib/rest-ftp-daemon/job.rb
CHANGED
@@ -142,6 +142,9 @@ module RestFtpDaemon
|
|
142
142
|
rescue Errno::EHOSTDOWN => exception
|
143
143
|
return oops :ended, exception, "conn_host_is_down"
|
144
144
|
|
145
|
+
rescue Errno::EPIPE=> exception
|
146
|
+
return oops :ended, exception, "conn_broken_pipe"
|
147
|
+
|
145
148
|
rescue Errno::ENETUNREACH => exception
|
146
149
|
return oops :ended, exception, "conn_unreachable"
|
147
150
|
|
@@ -51,11 +51,11 @@ module RestFtpDaemon
|
|
51
51
|
private
|
52
52
|
|
53
53
|
def link p
|
54
|
-
klass = (p == @page)? "
|
54
|
+
klass = (p == @page)? "primary" : "default"
|
55
55
|
|
56
56
|
url = Helpers.dashboard_filter_url(@filter)
|
57
57
|
|
58
|
-
"<a class='
|
58
|
+
"<a class='btn btn-%s' href='%s?page=%d'>%p</a>" % [
|
59
59
|
klass,
|
60
60
|
@filter,
|
61
61
|
p,
|
@@ -81,13 +81,29 @@ a.class {
|
|
81
81
|
margin-bottom: 4px;
|
82
82
|
}
|
83
83
|
|
84
|
+
.paginator, .filters {
|
85
|
+
padding-bottom: 5px;
|
86
|
+
}
|
87
|
+
|
88
|
+
.paginator .btn, .filters .btn {
|
89
|
+
margin-bottom: 2px !important;
|
90
|
+
}
|
91
|
+
|
92
|
+
.filters {
|
93
|
+
padding-right: 5px;
|
94
|
+
}
|
95
|
+
|
96
|
+
.paginator {
|
97
|
+
padding-left: 20px;
|
98
|
+
}
|
84
99
|
|
85
|
-
.
|
100
|
+
.paginator .btn {
|
86
101
|
padding-left: 7px !important;
|
87
102
|
padding-right: 7px !important;
|
88
103
|
}
|
89
104
|
|
90
105
|
|
106
|
+
|
91
107
|
/* Footer styles
|
92
108
|
-------------------------------------------------- */
|
93
109
|
html {
|
@@ -3,24 +3,23 @@
|
|
3
3
|
- counts_all = $queue.jobs_count
|
4
4
|
- jobs = @paginate.subset
|
5
5
|
|
6
|
+
.btn-group.btn-group-xs.filters
|
7
|
+
- klass = @filter.empty? ? "btn-info" : ""
|
8
|
+
%a.btn.btn-default{href: Helpers.dashboard_filter_url(), class: klass}
|
9
|
+
ALL (#{counts_all})
|
10
|
+
|
11
|
+
.btn-group.btn-group-xs.filters
|
12
|
+
- counts_by_status.each do |status, count|
|
13
|
+
- klass = (status.to_s == @filter) ? "btn-info" : ""
|
14
|
+
%a.btn.btn-default{href: Helpers.dashboard_filter_url(status), class: klass}
|
15
|
+
#{status} (#{count})
|
6
16
|
|
7
|
-
.row
|
8
17
|
|
9
|
-
.col-md-4
|
10
|
-
.btn-group.btn-group-sm
|
11
|
-
- klass = @filter.empty? ? "btn-info" : ""
|
12
|
-
%a.btn.btn-default{href: Helpers.dashboard_filter_url(), class: klass}
|
13
|
-
ALL (#{counts_all})
|
14
|
-
.btn-group.btn-group-sm
|
15
|
-
- counts_by_status.each do |status, count|
|
16
|
-
- klass = (status.to_s == @filter) ? "btn-info" : ""
|
17
|
-
%a.btn.btn-default{href: Helpers.dashboard_filter_url(status), class: klass}
|
18
|
-
#{status} (#{count})
|
19
|
-
|
20
|
-
.col-md-8
|
21
|
-
.btn-group.btn-group-sm
|
22
|
-
= @paginate.browser
|
23
18
|
|
19
|
+
.btn-group.btn-group-xs.paginator
|
20
|
+
= @paginate.browser
|
21
|
+
|
22
|
+
%br
|
24
23
|
%br
|
25
24
|
|
26
25
|
.row
|
data/rest-ftp-daemon.gemspec
CHANGED
@@ -26,7 +26,7 @@ Gem::Specification.new do |spec|
|
|
26
26
|
|
27
27
|
spec.add_development_dependency "bundler", "~> 1.6"
|
28
28
|
spec.add_development_dependency "rake"
|
29
|
-
spec.add_development_dependency "rspec"
|
29
|
+
spec.add_development_dependency "rspec"
|
30
30
|
spec.add_development_dependency "http", "~> 0.8"
|
31
31
|
spec.add_development_dependency "rubocop", "~> 0.32.0"
|
32
32
|
spec.add_development_dependency "pry"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rest-ftp-daemon
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.247.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bruno MEDICI
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-05-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -42,16 +42,16 @@ dependencies:
|
|
42
42
|
name: rspec
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: '
|
47
|
+
version: '0'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - "
|
52
|
+
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: '
|
54
|
+
version: '0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: http
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|