config.exs 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  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. # General application configuration
  7. import Config
  8. config :toy,
  9. ecto_repos: [Toy.Repo]
  10. # Configures the endpoint
  11. config :toy, ToyWeb.Endpoint,
  12. url: [host: "localhost"],
  13. render_errors: [view: ToyWeb.ErrorView, accepts: ~w(html json), layout: false],
  14. pubsub_server: Toy.PubSub,
  15. live_view: [signing_salt: "iCT0Z9EZ"]
  16. # Configures the mailer
  17. #
  18. # By default it uses the "Local" adapter which stores the emails
  19. # locally. You can see the emails in your browser, at "/dev/mailbox".
  20. #
  21. # For production it's recommended to configure a different adapter
  22. # at the `config/runtime.exs`.
  23. config :toy, Toy.Mailer, adapter: Swoosh.Adapters.Local
  24. # Swoosh API client is needed for adapters other than SMTP.
  25. config :swoosh, :api_client, false
  26. # Configure esbuild (the version is required)
  27. config :esbuild,
  28. version: "0.12.18",
  29. default: [
  30. args:
  31. ~w(js/app.js --bundle --target=es2016 --outdir=../priv/static/assets --external:/fonts/* --external:/images/*),
  32. cd: Path.expand("../assets", __DIR__),
  33. env: %{"NODE_PATH" => Path.expand("../deps", __DIR__)}
  34. ]
  35. # Configures Elixir's Logger
  36. config :logger, :console,
  37. format: "$time $metadata[$level] $message\n",
  38. metadata: [:request_id]
  39. # Use Jason for JSON parsing in Phoenix
  40. config :phoenix, :json_library, Jason
  41. # Import environment specific config. This must remain at the bottom
  42. # of this file so it overrides the configuration defined above.
  43. import_config "#{config_env()}.exs"