dev.exs 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. use Mix.Config
  2. # For development, we disable any cache and enable
  3. # debugging and code reloading.
  4. #
  5. # The watchers configuration can be used to run external
  6. # watchers to your application. For example, we use it
  7. # with brunch.io to recompile .js and .css sources.
  8. config :web, WebWeb.Endpoint,
  9. http: [port: 4000],
  10. debug_errors: true,
  11. code_reloader: true,
  12. check_origin: false,
  13. watchers: [node: ["node_modules/brunch/bin/brunch", "watch", "--stdin",
  14. cd: Path.expand("../assets", __DIR__)]]
  15. # ## SSL Support
  16. #
  17. # In order to use HTTPS in development, a self-signed
  18. # certificate can be generated by running the following
  19. # command from your terminal:
  20. #
  21. # openssl req -new -newkey rsa:4096 -days 365 -nodes -x509 -subj "/C=US/ST=Denial/L=Springfield/O=Dis/CN=www.example.com" -keyout priv/server.key -out priv/server.pem
  22. #
  23. # The `http:` config above can be replaced with:
  24. #
  25. # https: [port: 4000, keyfile: "priv/server.key", certfile: "priv/server.pem"],
  26. #
  27. # If desired, both `http:` and `https:` keys can be
  28. # configured to run both http and https servers on
  29. # different ports.
  30. # Watch static and templates for browser reloading.
  31. config :web, WebWeb.Endpoint,
  32. live_reload: [
  33. patterns: [
  34. ~r{priv/static/.*(js|css|png|jpeg|jpg|gif|svg)$},
  35. ~r{priv/gettext/.*(po)$},
  36. ~r{lib/web_web/views/.*(ex)$},
  37. ~r{lib/web_web/templates/.*(eex)$}
  38. ]
  39. ]
  40. # Do not include metadata nor timestamps in development logs
  41. config :logger, :console, format: "[$level] $message\n"
  42. # Set a higher stacktrace during development. Avoid configuring such
  43. # in production as building large stacktraces may be expensive.
  44. config :phoenix, :stacktrace_depth, 20