Skip to content

Commit

Permalink
Try standalone app again
Browse files Browse the repository at this point in the history
  • Loading branch information
jahseng-lee committed Apr 28, 2024
1 parent d616f94 commit cb66a2b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
1 change: 1 addition & 0 deletions Procfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
web: bundle exec puma -C config/puma.rb
cable: bundle exec puma -p 28080 cable/config.ru
release: ./bin/rails db:migrate

6 changes: 6 additions & 0 deletions config/cable.ru
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# cable/config.ru
require_relative "../config/environment"
Rails.application.eager_load!

run ActionCable.server

9 changes: 2 additions & 7 deletions config/environments/production.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,8 @@
config.active_storage.service = :local

# Mount Action Cable outside main process or domain.
config.action_cable.mount_path = "/cable"
config.action_cable.url = ENV["HEROKU_ENV"] == "staging" ?
(
"wss://socket.staging.nomadstation.io/"
) : (
"wss://socket.nomadstation.io/"
)
config.action_cable.mount_path = nil
config.action_cable.url = ENV.fetch("REDIS_URL")
# config.action_cable.allowed_request_origins = [ "http://example.com", /http:\/\/example.*/ ]

# Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
Expand Down

0 comments on commit cb66a2b

Please sign in to comment.