Files
ruby-sea-battle/main-server/config/initializers/cors.rb
T
Slavasil e52178c929
CI / main-server (RSpec + audits) (push) Failing after 1m12s
CI / game-server (go vet + go test -race) (push) Successful in 1m1s
CI / frontend (build + tests) (push) Successful in 9s
add an all-in-one script for running tests; format and fix some code; add ci.yml
2026-11-29 16:46:27 +03:00

10 lines
287 B
Ruby

Rails.application.config.middleware.insert_before 0, Rack::Cors do
allow do
origins ENV.fetch("CORS_ORIGINS", "*").split(",")
resource "*",
headers: :any,
methods: [ :get, :post, :put, :patch, :delete, :options, :head ],
expose: [ "Authorization" ]
end
end