Commit a3710686 authored by Piotr Baj's avatar Piotr Baj 🏡

Introduce the SMTP_FROM variable, force https for Endpoint url on prod

parent 5d7f4f6f
......@@ -11,7 +11,7 @@ use Mix.Config
# before starting your production server.
config :webapp, WebappWeb.Endpoint,
http: [:inet6, port: System.get_env("PORT") || 4000],
url: [host: System.get_env("WEBAPP_DOMAIN") || "demo.runhyve.app", port: 443],
url: [host: System.get_env("WEBAPP_DOMAIN") || "demo.runhyve.app", scheme: "https", port: 443],
cache_static_manifest: "priv/static/cache_manifest.json",
secret_key_base: Map.fetch!(System.get_env(), "SECRET_KEY_BASE"),
server: true
......
......@@ -97,7 +97,7 @@ defmodule WebappWeb.Emails.UserEmail do
defp prep_mail(address) do
new_email()
|> to(address)
|> from("noreply-runhyve@panic.pl")
|> from(System.get_env("SMTP_FROM") || "noreply@runhyve.app")
|> put_html_layout({WebappWeb.LayoutView, "email.html"})
end
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment