The rails app shows as running in the logs:
2023-01-13T11:41:31Z app[9f803b33] mia [info]Puma starting in single mode...
2023-01-13T11:41:31Z app[9f803b33] mia [info]* Puma version: 5.4.0 (ruby 3.0.1-p64) ("Super Flight")
2023-01-13T11:41:31Z app[9f803b33] mia [info]* Min threads: 5
2023-01-13T11:41:31Z app[9f803b33] mia [info]* Max threads: 5
2023-01-13T11:41:31Z app[9f803b33] mia [info]* Environment: production
2023-01-13T11:41:31Z app[9f803b33] mia [info]* PID: 531
2023-01-13T11:41:31Z app[9f803b33] mia [info]* Listening on http://0.0.0.0:8080
2023-01-13T11:41:31Z app[9f803b33] mia [info]Use Ctrl-C to stop
2023-01-13T11:42:01Z runner[c935ea46] mia [info]Shutting down virtual machine
2023-01-13T11:42:01Z runner[c0640a89] mia [info]Shutting down virtual machine
2023-01-13T11:42:01Z app[c935ea46] mia [info]Sending signal SIGINT to main child process w/ PID 520
2023-01-13T11:42:01Z app[c935ea46] mia [info]2023-01-13T11:42:01.734Z pid=520 tid=32o INFO: Shutting down
2023-01-13T11:42:01Z app[c935ea46] mia [info]2023-01-13T11:42:01.734Z pid=520 tid=32o INFO: Terminating quiet workers
2023-01-13T11:42:01Z app[c935ea46] mia [info]2023-01-13T11:42:01.734Z pid=520 tid=gq8 INFO: Scheduler exiting...
2023-01-13T11:42:01Z app[c0640a89] mia [info]Sending signal SIGINT to main child process w/ PID 520
and I can ssh to the app and run rails console, I’ve confirmed I can interact with redis via Rails.cache.set
or Rails.cache.read
successfully as well as interact with the database to create and destroy records
However, I am unable to access my app using fly open
on the subdomain or fly proxy 8080
via localhost:8080
here is my fly.toml, I followed the quick start guide to setup for existing rails apps and then added the sidekiq worker, I’ve also added the recommended patch for action_cable that is listed in the quick start guide:
# fly.toml file generated for market-landing on 2023-01-12T12:25:23-05:00
app = "market-landing"
kill_signal = "SIGINT"
kill_timeout = 5
[processes]
web = "bin/rails fly:server"
worker = "bundle exec sidekiq"
[build]
[build.args]
BUILD_COMMAND = "bin/rails fly:build"
SERVER_COMMAND = "bin/rails fly:server"
[deploy]
release_command = "bin/rails fly:release"
[env]
PORT = "8080"
RACK_ENV="production"
RAILS_ENV="production"
[experimental]
allowed_public_ports = []
auto_rollback = true
[[services]]
http_checks = []
internal_port = 8080
processes = ["web"]
protocol = "tcp"
script_checks = []
[services.concurrency]
hard_limit = 25
soft_limit = 20
type = "connections"
[[services.ports]]
force_https = false
handlers = ["http"]
port = 80
[[services.ports]]
handlers = ["tls", "http"]
port = 443
[[services.tcp_checks]]
grace_period = "1s"
interval = "15s"
restart_limit = 0
timeout = "2s"
[[statics]]
guest_path = "/app/public"
url_prefix = "/"
Any help would be greatly appreciated
healthcheck:
fly checks list
Update available 0.0.446 -> v0.0.447.
Run "flyctl version update" to upgrade.
Health Checks for market-landing
NAME | STATUS | ALLOCATION | REGION | TYPE | LAST UPDATED | OUTPUT
-----------------------------------*---------*------------*--------*------*--------------*--------------------------------------------
3df2415693844068640885b45074b954 | passing | 9f803b33 | mia | TCP | 47m23s ago | TCP connect 172.19.6.138:8080: Success[✓]
| | | | | |
| | | | | |
(base) ➜ market-landing git:(master) ✗
fly status =>
fly status
Update available 0.0.446 -> v0.0.447.
Run "flyctl version update" to upgrade.
App
Name = market-landing
Owner = personal
Version = 4
Status = running
Hostname = market-landing.fly.dev
Platform = nomad
Deployment Status
ID = 672eb3c8-0262-61b9-721e-7e4e9c2f67fd
Version = v4
Status = successful
Description = Deployment completed successfully
Instances = 2 desired, 2 placed, 2 healthy, 0 unhealthy
Instances
ID PROCESS VERSION REGION DESIRED STATUS HEALTH CHECKS RESTARTS CREATED
9f803b33 web 4 mia run running 1 total, 1 passing 0 48m16s ago
5bb876e7 worker 4 mia run running 0 48m16s ago