66 lines
1.9 kB
1
# This file is responsible for configuring your application
2
# and its dependencies with the aid of the Config module.
3
#
4
# This configuration file is loaded before any dependency and
5
# is restricted to this project.
6
7
# General application configuration
8
import Config
9
10
config :blog,
11
ecto_repos: [Blog.Repo],
12
generators: [timestamp_type: :utc_datetime]
13
14
# Configures the endpoint
15
config :blog, BlogWeb.Endpoint,
16
url: [host: "localhost"],
17
adapter: Bandit.PhoenixAdapter,
18
render_errors: [
19
formats: [html: BlogWeb.ErrorHTML, json: BlogWeb.ErrorJSON],
20
layout: false
21
],
22
pubsub_server: Blog.PubSub,
23
live_view: [signing_salt: "aLPIOUxY"]
24
25
# Configures the mailer
26
#
27
# By default it uses the "Local" adapter which stores the emails
28
# locally. You can see the emails in your browser, at "/dev/mailbox".
29
#
30
# For production it's recommended to configure a different adapter
31
# at the `config/runtime.exs`.
32
config :blog, Blog.Mailer, adapter: Swoosh.Adapters.Local
33
34
# Configure esbuild (the version is required)
35
config :esbuild,
36
version: "0.17.11",
37
blog: [
38
args:
39
~w(js/app.js --bundle --target=es2017 --outdir=../priv/static/assets --external:/fonts/* --external:/images/*),
40
cd: Path.expand("../assets", __DIR__),
41
env: %{"NODE_PATH" => Path.expand("../deps", __DIR__)}
42
]
43
44
# Configure tailwind (the version is required)
45
config :tailwind,
46
version: "3.4.3",
47
blog: [
48
args: ~w(
49
--config=tailwind.config.js
50
--input=css/app.css
51
--output=../priv/static/assets/app.css
52
),
53
cd: Path.expand("../assets", __DIR__)
54
]
55
56
# Configures Elixir's Logger
57
config :logger, :console,
58
format: "$time $metadata[$level] $message\n",
59
metadata: [:request_id]
60
61
# Use Jason for JSON parsing in Phoenix
62
config :phoenix, :json_library, Jason
63
64
# Import environment specific config. This must remain at the bottom
65
# of this file so it overrides the configuration defined above.
66
import_config "#{config_env()}.exs"
67