From caf2db97bdafd55b4cc5df7621e643926265f2f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ton=C4=87i=20Gali=C4=87?= Date: Thu, 10 Mar 2022 17:33:01 +0100 Subject: [PATCH 1/2] Also include priv/static/assets for live reload Tailwind compiles the assets/CSS to priv/static/assets folder which wasn't included in the list of folders to watch for live_reload. This change (together with installing inotify-tools) seems to trigger live reloading when CSS gets changed --- app/server/beam/tau/config/dev.exs | 1 + 1 file changed, 1 insertion(+) diff --git a/app/server/beam/tau/config/dev.exs b/app/server/beam/tau/config/dev.exs index 2eedbbcd38..e0adcabd06 100644 --- a/app/server/beam/tau/config/dev.exs +++ b/app/server/beam/tau/config/dev.exs @@ -49,6 +49,7 @@ config :tau, TauWeb.Endpoint, live_reload: [ patterns: [ ~r"priv/static/.*(js|css|png|jpeg|jpg|gif|svg)$", + ~r"priv/static/assets/.*(js|css)$", ~r"priv/gettext/.*(po)$", ~r"lib/tau_web/(live|views)/.*(ex)$", ~r"lib/tau_web/templates/.*(eex)$", From 91d828cf84bf71afca1708655cd0005b13e543b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ton=C4=87i=20Gali=C4=87?= Date: Thu, 10 Mar 2022 17:36:57 +0100 Subject: [PATCH 2/2] Make default secret_key_base meet minimum length Plug will complain the secret_key_base doesn't meet the minimum length of 64 bytes if someone forgets to supply one via ENV variables --- app/server/beam/tau/config/runtime.exs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/server/beam/tau/config/runtime.exs b/app/server/beam/tau/config/runtime.exs index 99598b5a7f..bb445de4d9 100644 --- a/app/server/beam/tau/config/runtime.exs +++ b/app/server/beam/tau/config/runtime.exs @@ -54,7 +54,7 @@ config :tau, TauWeb.Endpoint, if config_env() == :dev do secret_key_base = System.get_env("SECRET_KEY_BASE") || - "pDakDMi+9PfJKYIHcdf7MGIog4NRPiuws5eUT6M6Kcg3Wad69hT+tVwOccyjfYJ" + "ppDakDMi+9PfJKYIHcdf7MGIog4NRPiuws5eUT6M6Kcg3Wad69hT+tVwOccyjfYJ" config :tau, TauWeb.Endpoint, secret_key_base: secret_key_base