From 67d7f397d1ac3be4104beba2d2ac774cb4247436 Mon Sep 17 00:00:00 2001 From: Kieran Date: Sun, 10 Mar 2024 15:31:40 -0700 Subject: [PATCH] Updated check origin in release environment (#67) --- config/config.exs | 2 ++ config/dev.exs | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/config/config.exs b/config/config.exs index 4396f4b..fba9c7e 100644 --- a/config/config.exs +++ b/config/config.exs @@ -26,6 +26,8 @@ config :pinchflat, # Configures the endpoint config :pinchflat, PinchflatWeb.Endpoint, url: [host: "localhost", port: 8945], + # NOTE: this must be updated if ever deployed traditionally (ie: not self-hosted) + check_origin: false, adapter: Phoenix.Endpoint.Cowboy2Adapter, render_errors: [ formats: [html: PinchflatWeb.ErrorHTML, json: PinchflatWeb.ErrorJSON], diff --git a/config/dev.exs b/config/dev.exs index ee5413b..cedbe26 100644 --- a/config/dev.exs +++ b/config/dev.exs @@ -21,7 +21,6 @@ config :pinchflat, PinchflatWeb.Endpoint, # Binding to loopback ipv4 address prevents access from other machines. # Change to `ip: {0, 0, 0, 0}` to allow access from other machines. http: [port: 4008], - check_origin: false, code_reloader: true, debug_errors: true, secret_key_base: "QLKKs3ypkUgJ/fMnWZaIYqpMbnA4IlPVEm3tvezsblhFDv4b67rdp+AmTpAFFURK",