SupaSaya
I am still doing something similar to this:
https://medium.com/@zek/deploy-early-and-often-deploying-phoenix-with-edeliver-and-distillery-part-one-5e91cac8d4bd
https://medium.com/@zek/deploy-early-and-often-deploying-phoenix-with-edeliver-and-distillery-part-two-f361ef36aa10
I deployed 10+ apps to production and it still always takes me at least 1-2h. Most of the time goes to installing different dependencies for different distros(and versions of these) + solving cryptic erlang errors(once I spent 4h on single db migration error).
Building/deploying further releases/upgrades on small VPS’s is also very very slow(think DO’s $5 droplet).
This is the biggest reason I started using node and go for simple/medium complex projects.
A while ago I also had ansible scripts to set-up everything but these got outdated and created enough additional complexity that made me stop using them. Using hosting services like heroku just for this is also no-go for me or my clients.
Trending in Questions
Other Trending Topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #ai
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #blog-post
- #elixirconf-us
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #elixirconf-eu
- #api
- #forms
- #security
- #hex











Showing Posts 1 to 10- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
tty
I usually make sure my build machine and target server are the same: same OS, same versions of libs.
Then make a Release Package. From there its a straight scp+untar and its up and running.
ryanswapp
Same boat. It takes a bit to deploy an elixir app. That said, once everything is setup it only takes a minute or so after running the edeliver command. It would be nice if there were more options for deploying. I’m aware of Gigalixir and Heroku as the only two quick/easier options (although Gigalixir didn’t feel quick - was a bit of a headache trying to get it to work whereas Heroku was just an add your buildpacks and go experience. Perhaps Gigalixir is easier now). Supposedly there is an easy deployment tool in the works that will be a part of the core framework. Not sure where things are at with that though.
pedromvieira
I used this Guide to start our current deployment Docker / Kubernetes on GCP.
It is really easy and fast to deploy a new build.
zkessin
Yes, once you build a release it is pretty easy. I have an email course you can get (its free) on how to do it
https://elixirtraining.org/release_email_course.html
sfusato
This is my current strategy as well: same build and target machine + Distillery releases and hot-upgrades.
Tried Edeliver at some point, but had some issues along the way. I also felt it added extra complexity to my setup.
Look over the Distillery documentation: Home - Distillery Documentation. It’s just as good as you would expect in the Elixir ecosystem
. Has multiple guides for different scenarios.
thenrio
Similar path:
elixir:1.8.1-slimfor a stretch host.Hot upgrade is not implemented (I do not need it).
egze
Woah. Never heard about the debian package approach before.
Are you using GitHub - johnhamelink/exrm_deb: Create a deb for your elixir release with ease · GitHub? What happens after you install the .deb package? What do you start, how?
thenrio
I used
dh_makeas suggested in 15.2. Building your First Package.I did not know about exrm_deb…
I found
dh_makeupsetting at first approach and I did ran away a couple of times from it in the past but it now fits my bill and I can use it for other contexts.Going into files details, I have
The approach I choose is a long running process owned by a dedicated user, environment in a dedicated env file
/etc/lift/lift.envservice: systemd, excerpt:
That is, I start the release much like it would in a docker container, and this what
systemdis expecting for a simple type.package is built with a makefile (33 lines, 982 bytes).
egze
This is nice. How does updating work? Simply reinstall the package and tell systemd to restart?
thenrio
Just install new package.