Hi there all! First time here :). There is a way to use the param --name option from mix release usingdistillery with an edeliver command? (Like mix edeliver build release ... <release name somewhere>.... I’m actually building an umbrella app, with a main app release, and a sub app release. I could only achieve this by building the main (default) app through edeliver build command, and the sub app through a direct release command on the build server… but, I think that this is not and optimal/correct approach :/. Any ideas or different approaches around there?
For releases you don’t specify command line arguments like that, they are handled via the release building script (and baked in) that is handled by distillery and its configuration files, so you will want to look in it’s configuration documentation.
I had already checked documentation, but, I’m not able to generate, or don’t know how to generate a release different than :default (Or the first one written on my rel/config.exs file) from my local machine through edeliver. The main release it´s triggered by mix edeliver build... from my local machine, using the build machine, but, my idea is to generate another release from my local machine, different than defaults.
It’s easy to do this inside the build machine (ssh login) and just exec a mix release --name ... or a similar command to generate a release inside build machine, that uses the rel/config.exs distillery file, I think you are talking about this config file right? I was trying to achieve a behaviour similar to Ruby’s Capistrano, when you are able to build or deploy everything starting from your local machine.
I don´t know if this is not possible due to edeliver design or if it’s actually possible to do using edeliver hooks, executing some arbitrary bash script to propagate exactly the release i want to build. I hope my idea is a little clearer now
You can see how via mix help release, it’s documented there.
That… is entirely the point of Distillery though? I’m no sure what edeliver does actually other than copy things around, I don’t use it, I just copy the release myself as it’s a single directory rsync over… ^.^;
I’ve not used ruby either so no clue what that references. But yes, you can build and deploy from your local machine. What I do is just run my ./release.sh file, but internally it just builds, digests, releases, rsync’s a directory over, then ssh’s a command to the systemd service on the server to restart the server, it’s pretty dead-simple.
No clue about edeliver, I’m honestly not actually that certain of what it is for or how it would simplify what I already do (I think it would just replace my last two lines of my release file with a single one maybe, but I don’t know if it can restarts services too or whatever it does? So I havn’t really see the point of it…).
Thanks again OvermindDL1! I think your approach is very nice. I would make some modifications to adjust it to my desired workflow and drop edeliver :). Edeliver just perform some remote ssh commands for you, sync repo on build machine, download builds, push again to staging or production servers… with a few commands
@kiel-cristian Have you gotten the Umbrella/Distillery/eDeliver trio to work? I am working on a project right now, and you have written the only post on Elixir-Forum that is tagged for all three. If so, would you mind messaging me, I don’t want to clutter up this post more than I am with this request.
Hi there Isaac, nope, sadly nope. After hours trying to generate specific releases through edeliver + distillery + Umbrella project I realized that edeliver does not handle that kind of usage. I am generating releases directly on my build server, and being careful with setup for environment variables, runtime variables, and moving builded releases on another folder after compiling. (Like distillery docs suggests to avoid directory mutations issues).