elastic_beans 0.12.0.alpha1 → 0.12.0.alpha2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/lib/elastic_beans/rack/exec.rb +2 -3
- data/lib/elastic_beans/version.rb +1 -1
- 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: 7ae6aa35f652ca0e53486f211218fedea2419d62
|
4
|
+
data.tar.gz: 55e52f1bb58c11f5fa40934621ecca13e63b2408
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: abd30c1b53faac2caf2f0c38261d999d3a9d5863253ede34375a812b9e1617a9ed96e017cbd579bdeede82e012dcf5b9a31f95b54236526f3266c564a3435649
|
7
|
+
data.tar.gz: f34694b8c6601115f442eee12a90195cf50af471ec90a52ea94d5d332a58d31b70c7c00e8aa923c9eea871a2051594f9438bab2a2f64319e6df914401631a611
|
data/README.md
CHANGED
@@ -115,10 +115,10 @@ In `config/initializers/elastic_beans.rb`, add the middleware into your stack, b
|
|
115
115
|
)
|
116
116
|
end
|
117
117
|
|
118
|
-
In `cron.yaml`,
|
118
|
+
In `cron.yaml`, name the full command to be run and use `/exec` as the `url`:
|
119
119
|
|
120
120
|
- name: rake myapp:mytask[arg1,arg2]
|
121
|
-
url: "/exec
|
121
|
+
url: "/exec"
|
122
122
|
|
123
123
|
Then create a periodic scheduler environment using `cron.yaml`:
|
124
124
|
|
@@ -1,5 +1,4 @@
|
|
1
1
|
require "logger"
|
2
|
-
require "uri"
|
3
2
|
require "action_dispatch"
|
4
3
|
|
5
4
|
module ElasticBeans
|
@@ -51,12 +50,12 @@ module ElasticBeans
|
|
51
50
|
end
|
52
51
|
|
53
52
|
def command_from_request(request)
|
54
|
-
command_string =
|
53
|
+
command_string = request.headers['X-Aws-Sqsd-Taskname']
|
55
54
|
::ElasticBeans::Exec::Command.new(command_string: command_string)
|
56
55
|
end
|
57
56
|
|
58
57
|
def cron_request?(request)
|
59
|
-
request.local? && aws_sqsd?(request) && request.method == 'POST' && request.path
|
58
|
+
request.local? && aws_sqsd?(request) && request.method == 'POST' && request.path == '/exec'
|
60
59
|
end
|
61
60
|
|
62
61
|
def enabled?
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: elastic_beans
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.12.0.
|
4
|
+
version: 0.12.0.alpha2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Stegman
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-07-
|
11
|
+
date: 2017-07-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk
|