distillery

How to get elixir nodes to connect automatically on startup?

廉价感情. 提交于 2019-12-22 18:43:29
问题 Background I'm trying to setup clustering between a few elixir nodes. My understanding is that I can set this up by modifying the release vm.args. I'm using Distillery to build releases and am following the documentation here: https://hexdocs.pm/distillery/config/runtime.html. My rel/vm.args file is as follows: -name <%= release_name %>@${HOSTNAME} -setcookie <%= release.profile.cookie %> -smp auto -kernel inet_dist_listen_min 9100 inet_dist_listen_max 9155 -kernel sync_nodes_mandatory '[$

Read files in Phoenix in production mode

本秂侑毒 提交于 2019-12-11 06:03:46
问题 I've Phoenix app (I created it with --api flag) that has some additional data required to process requests that I store in priv/data/filters.csv . So it works fine in dev mode, I can read this file like: File.stream!("priv/data/filters.csv") , but once app is delivered using mix edeliver update this file is not accessible anymore. I can see this folder in build directory, but after app is delivered there is no such folder priv . I'm not sure why it's not copied to deliver folder. What I'm