dev.exs 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. import Config
  2. # Configure your database
  3. config :toy, Toy.Repo,
  4. username: "toy",
  5. password: "toy",
  6. database: "toy_dev",
  7. hostname: "localhost",
  8. show_sensitive_data_on_connection_error: true,
  9. pool_size: 10
  10. # For development, we disable any cache and enable
  11. # debugging and code reloading.
  12. #
  13. # The watchers configuration can be used to run external
  14. # watchers to your application. For example, we use it
  15. # with esbuild to bundle .js and .css sources.
  16. config :toy, ToyWeb.Endpoint,
  17. # Binding to loopback ipv4 address prevents access from other machines.
  18. # Change to `ip: {0, 0, 0, 0}` to allow access from other machines.
  19. http: [ip: {127, 0, 0, 1}, port: 4000],
  20. check_origin: false,
  21. code_reloader: true,
  22. debug_errors: true,
  23. secret_key_base: "JckynKWcyIhf+lfqbDQGKrVyDLwhoLN3ccUerIWFDLU20PIj0Iv66q4C1n3dPat2",
  24. watchers: [
  25. # Start the esbuild watcher by calling Esbuild.install_and_run(:default, args)
  26. esbuild: {Esbuild, :install_and_run, [:default, ~w(--sourcemap=inline --watch)]}
  27. ]
  28. # ## SSL Support
  29. #
  30. # In order to use HTTPS in development, a self-signed
  31. # certificate can be generated by running the following
  32. # Mix task:
  33. #
  34. # mix phx.gen.cert
  35. #
  36. # Note that this task requires Erlang/OTP 20 or later.
  37. # Run `mix help phx.gen.cert` for more information.
  38. #
  39. # The `http:` config above can be replaced with:
  40. #
  41. # https: [
  42. # port: 4001,
  43. # cipher_suite: :strong,
  44. # keyfile: "priv/cert/selfsigned_key.pem",
  45. # certfile: "priv/cert/selfsigned.pem"
  46. # ],
  47. #
  48. # If desired, both `http:` and `https:` keys can be
  49. # configured to run both http and https servers on
  50. # different ports.
  51. # Watch static and templates for browser reloading.
  52. config :toy, ToyWeb.Endpoint,
  53. live_reload: [
  54. patterns: [
  55. ~r"priv/static/.*(js|css|png|jpeg|jpg|gif|svg)$",
  56. ~r"priv/gettext/.*(po)$",
  57. ~r"lib/toy_web/(live|views)/.*(ex)$",
  58. ~r"lib/toy_web/templates/.*(eex)$"
  59. ]
  60. ]
  61. # Do not include metadata nor timestamps in development logs
  62. config :logger, :console, format: "[$level] $message\n"
  63. # Set a higher stacktrace during development. Avoid configuring such
  64. # in production as building large stacktraces may be expensive.
  65. config :phoenix, :stacktrace_depth, 20
  66. # Initialize plugs at runtime for faster development compilation
  67. config :phoenix, :plug_init_mode, :runtime