Skip to content

Commit

Permalink
add /up route and fly health check
Browse files Browse the repository at this point in the history
  • Loading branch information
indirect committed Oct 5, 2024
1 parent 8e8558a commit 7dc34ef
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
2 changes: 2 additions & 0 deletions config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,7 @@
end
resources :stats, only: [:index]

get "up" => "rails/health#show"

root "feeds#new"
end
14 changes: 14 additions & 0 deletions fly.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,20 @@ console_command = "/rails/bin/rails console"
cpus = 2
memory_mb = 1024

[checks]
[checks.rails]
processes = ["app"]
grace_period = "30s"
interval = "15s"
method = "get"
path = "/up"
port = 3000
timeout = "10s"
type = "http"
[checks.rails.headers]
Host = "feedyour.email"
X-Forwarded-Proto = "https"

[[statics]]
guest_path = "/rails/public"
url_prefix = "/"
Expand Down

0 comments on commit 7dc34ef

Please sign in to comment.