Compare commits
1 Commits
fe91d8de6d
...
41b9d87278
Author | SHA1 | Date | |
---|---|---|---|
41b9d87278 |
@ -1,4 +1,4 @@
|
||||
FROM elixir:1.14.1-alpine AS build
|
||||
FROM elixir:1.14-alpine AS build
|
||||
|
||||
# install build dependencies
|
||||
RUN apk add --no-cache build-base npm git python3
|
||||
@ -37,7 +37,7 @@ RUN mix do compile, release
|
||||
FROM alpine:latest AS app
|
||||
|
||||
RUN apk upgrade --no-cache && \
|
||||
apk add --no-cache bash openssl libssl1.1 libcrypto1.1 libgcc libstdc++ ncurses-libs
|
||||
apk add --no-cache bash openssl libgcc libstdc++ ncurses-libs
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
|
@ -62,7 +62,7 @@ if config_env() == :prod do
|
||||
System.get_env("SECRET_KEY_BASE") ||
|
||||
raise """
|
||||
environment variable SECRET_KEY_BASE is missing.
|
||||
You can generate one by running: mix phx.gen.secret
|
||||
You can generate one by calling: mix phx.gen.secret
|
||||
"""
|
||||
|
||||
config :memex, MemexWeb.Endpoint, secret_key_base: secret_key_base
|
||||
@ -79,7 +79,7 @@ if config_env() == :prod do
|
||||
password: System.get_env("SMTP_PASSWORD") || raise("No SMTP_PASSWORD set!"),
|
||||
ssl: System.get_env("SMTP_SSL") == "true",
|
||||
email_from: System.get_env("EMAIL_FROM") || "no-reply@#{System.get_env("HOST")}",
|
||||
email_name: System.get_env("EMAIL_NAME") || "memEx"
|
||||
email_name: System.get_env("EMAIL_NAME") || "Memex"
|
||||
|
||||
# ## Using releases
|
||||
#
|
||||
|
@ -19,8 +19,8 @@ defmodule Memex.Email do
|
||||
|
||||
@spec base_email(User.t(), String.t()) :: t()
|
||||
defp base_email(%User{email: email}, subject) do
|
||||
from = Application.get_env(:memex, Memex.Mailer)[:email_from] || "noreply@localhost"
|
||||
name = Application.get_env(:memex, Memex.Mailer)[:email_name]
|
||||
from = Application.get_env(:Memex, Memex.Mailer)[:email_from] || "noreply@localhost"
|
||||
name = Application.get_env(:Memex, Memex.Mailer)[:email_name]
|
||||
new() |> to(email) |> from({name, from}) |> subject(subject)
|
||||
end
|
||||
|
||||
|
@ -4,15 +4,15 @@
|
||||
<%= @email.subject %>
|
||||
</title>
|
||||
</head>
|
||||
<body style="padding: 2em; color: rgb(161, 161, 170); background-color: rgb(39, 39, 42); font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif; text-align: center;">
|
||||
<body style="padding: 2em; color: rgb(31, 31, 31); background-color: rgb(220, 220, 228); font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif; text-align: center;">
|
||||
<%= @inner_content %>
|
||||
|
||||
<hr style="margin: 2em auto; border-width: 1px; border-color: rgb(161, 161, 170); width: 100%; max-width: 42rem;" />
|
||||
<hr style="margin: 2em auto; border-width: 1px; border-color: rgb(212, 212, 216); width: 100%; max-width: 42rem;" />
|
||||
|
||||
<a style="color: rgb(161, 161, 170);" href={Routes.live_url(Endpoint, HomeLive)}>
|
||||
<a style="color: rgb(31, 31, 31);" href={Routes.live_url(Endpoint, HomeLive)}>
|
||||
<%= dgettext(
|
||||
"emails",
|
||||
"This email was sent from memEx"
|
||||
"This email was sent from Memex, the self-hosted firearm tracker website."
|
||||
) %>
|
||||
</a>
|
||||
</body>
|
||||
|
@ -7,5 +7,5 @@
|
||||
=====================
|
||||
|
||||
<%= dgettext("emails",
|
||||
"This email was sent from memEx at %{url}",
|
||||
"This email was sent from Memex at %{url}, the self-hosted firearm tracker website.",
|
||||
url: Routes.live_url(Endpoint, HomeLive)) %>
|
||||
|
@ -52,6 +52,16 @@ msgstr ""
|
||||
msgid "Reset your Memex password"
|
||||
msgstr ""
|
||||
|
||||
#: lib/memex_web/templates/layout/email.txt.eex:9
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "This email was sent from Memex at %{url}, the self-hosted firearm tracker website."
|
||||
msgstr ""
|
||||
|
||||
#: lib/memex_web/templates/layout/email.html.heex:13
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "This email was sent from Memex, the self-hosted firearm tracker website."
|
||||
msgstr ""
|
||||
|
||||
#: lib/memex/accounts/email.ex:44
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "Update your Memex email"
|
||||
@ -80,13 +90,3 @@ msgstr ""
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "You can reset your password by visiting the URL below:"
|
||||
msgstr ""
|
||||
|
||||
#: lib/memex_web/templates/layout/email.html.heex:13
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "This email was sent from memEx"
|
||||
msgstr ""
|
||||
|
||||
#: lib/memex_web/templates/layout/email.txt.eex:9
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "This email was sent from memEx at %{url}"
|
||||
msgstr ""
|
||||
|
Loading…
Reference in New Issue
Block a user