ok_health_check 0.1.1 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +19 -2
- data/lib/ok_health_check/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f3298d5dd865859726cc004ed62dc48ad9d27102
|
4
|
+
data.tar.gz: 5ed13ed4853580a9beb410a65666f6d14f5c7849
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d6c20b5111182e0183b225f71ae706ae844ba82a14e091cc04fe7a12826b4fd7cd4ea2b6277a50a0e505132daa5932fef0de549a4023fe258edbcbb8011eacc3
|
7
|
+
data.tar.gz: dcfda6d4fcd4c4867fe28ca6dc73f684f74b0f6ded1ff5f7e2a3fb412fb8d86a152e9cef89177048d20fe2d75583f0ddc007e574bd179e0121c082de15434b11
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# OkHealthCheck
|
2
2
|
|
3
|
-
|
3
|
+
This gem provides a Rack app that responds to any request with a 200 status code and the text "OK". We suggest you mount it so it responds to requests from "/healthcheck" - in fact, if you use Rails, we do that for you.
|
4
4
|
|
5
5
|
## Installation
|
6
6
|
|
@@ -20,7 +20,24 @@ Or install it yourself as:
|
|
20
20
|
|
21
21
|
## Usage
|
22
22
|
|
23
|
-
|
23
|
+
### Rails
|
24
|
+
Nothing to do here. Rails will automatically include a route `/healthcheck` that will return `OK` when requested.
|
25
|
+
|
26
|
+
If you want it to listen on some other endpoint, just add the following to your `config/routes.rb` file:
|
27
|
+
|
28
|
+
```ruby
|
29
|
+
mount OkHealthCheck.new, at: "/<desired endpoint>"
|
30
|
+
```
|
31
|
+
|
32
|
+
### Other Rack Apps (Sinatra, etc.)
|
33
|
+
|
34
|
+
```ruby
|
35
|
+
require 'ok_health_check'
|
36
|
+
|
37
|
+
run Rack::URLMap.new \
|
38
|
+
"/" => <Your app class>,
|
39
|
+
"/healthcheck" => OkHealthCheck.new
|
40
|
+
```
|
24
41
|
|
25
42
|
## Contributing
|
26
43
|
|