Elixir Deployment Options

Anyone has experience with VPSDime? The benchmark results look nice, and you get 6gb with 4 (virtual cores) for 7 dollar.

Currently I have one production projected hosted on Heroku, mostly because I don’t want to be bothered with database settings, backups etc. However, given that it’s fairly easy to deploy Elixir apps with exrm/distillery, and Heroku is pricey (25$ for a simple dyno + 50$ for database) I think that you get better ‘bang for bucks’ with:

The big caveat here is of course that it’s hard to say anything meaningful about the performance of each of the database offerings compared to the monthly price.

I have had a VPSDime account for a while. I have had no down time (other then the time bellow). It has been surprisingly fast. I may have gotten lucky so far. The only reason I do not use it more is due to the TOS and https://vpsdime.com/aup.html. I know a lot of people and including me who have had their servers suspended due to too much load or usage. And it took a few days to prove that the TOS was not breached.

Would not use for production just quick test. I have been a fan of Openshift I have used this cartridge once before. https://github.com/wozniakjan/erlcart

Looks like they have rebranded (or merged) - some really cheap dedis here!

https://www.nocix.net/dedicated/

FWIW, I’ve written a few articles for Codeship about AWS/Heroku Postgres as well as Heroku’s backup process.

https://blog.codeship.com/use-heroku-pgbackups/

https://blog.codeship.com/heroku-data-links-postgres-redis/

https://blog.codeship.com/heroku-postgresql-versus-amazon-rds-postgresql/

And here’s a pretty detailed overview of what you’re getting with Heroku. The flip side of this is that with Elixir you don’t get the ability to cluster from Heroku, so that’s something to keep in mind.

https://blog.codeship.com/exploring-microservices-architecture-on-heroku/

2 Likes

Keep in mind that for a simple dyno, the $7 Hobby plan is more than adequate, especially with Elixir, for any small app.

Should work well on Joyent for note.

Remember, exrm author is telling people to use Distillery instead (which he also wrote).

http://bitwalker.org/posts/2016-07-21-distillery-vs-exrm-vs-relx/

2 Likes

I’m really curious how Packet.net’s Type 2A machine performs with Elixir. It’s a monster with 96-core ARMv8 with 128 gigs of ECC memory and 20 Gbps network throughput for ~ $370 / mo.

Linode had some pretty major issues with DDOS not sure why are they a constant target but it’s a concern

It’s about the speed of dual e5-2670 v1
you can buy dual e5-2670 box for +/- $600 and pay $100 for hosting

1 Like

What kind of amount of RAM may a simple, low-traffic Phoenix web app/website, released with releases, using PostgreSQL require?

I’m going to need to put the start of my first client Phoenix project online soon, and I’m currently looking at running OpenBSD or FreeBSD on one of these bare metal/dedicated providers in Amsterdam:

Scaleway and Online.net (same company I believe) seem ridiculously cheap? FreeBSD/OpenBSD installation may be somewhat involved/non-automated with Scaleway and Online.net, whereas Packet.net offers FreeBSD as an automated install.

Before I came across those, I was looking at these cloud options and going for starter/small options with less RAM, such as 1GB or 2GB:

I like these two cloud options because they’re in Switzerland (hot on data privacy, though to be honest that’s not the highest priority in this case as my projects aren’t sensitive in nature), but perhaps it would be better for me to pay a little more for a dedicated/bare metal server and have more headroom for running multiple apps. Also, I understand BSD developers recommend avoiding running virtualised.

Thanks.

3 Likes

The dedicated server would be my choice - and what a great price that is!! :023:

2 Likes

Dokku looks amazing, unfortunaly i did not make it work with Phoenix app. Hope next time i try i could, actually im doing deploy in my server manually :tired_face:.

Anyway, coming from Heroku i am using Digital Ocean now in $20/month plan and are doing ok with my application that have around 100 requests per minute, in the moment it uses around 27% of memory ram. Im using heroku database yet so is just Phoenix app running there.

Another $20 is for Cloudflare that saves a lot of bandwidth(75+%).

2 Likes

So the 2GB of RAM is plenty for your app - cool. Are you running via releases or running the app using system-installed Erlang and Elixir, and do you know if this makes any difference to RAM usage and performance?

1 Like

I run manually using system-installed Erlang and Elixir. Can`t say if performs better with releases or not, need to found a decent tutorial to implement a deploy process, do this process of stop server, update things, start server is boring.

1 Like

Ok, ta. When I’ve managed to start using environment variables I plan to write some step-by-step notes on using edeliver with Phoenix.

1 Like

I have made a buildpack for Bluemix. You can grab it at https://github.com/nrrso/bluemix-buildpack-elixir

Tell Bluemix to use this buildpack, by adding a manifest.yml to your project with the following contents:

---
applications:
- name: myApp
  memory: 512M
  buildpack: https://github.com/nrrso/bluemix-buildpack-elixir
  host: myApp
  domain: mybluemix.net
  command: MIX_ENV=prod mix phoenix.server --no-deps-check
  timeout: 60
  env:
    env_type: production
    db_pool_size: 5
    db_timeout: 60_000
    db_pool_timout: 60_000

If you want to change the version of erlang / elixir that the buildpack shall fetch you can create an elixir_buildpack.config inside your project:

erlang_version=18.2.1
elixir_version=1.2.1
always_rebuild=false
with_seed=false
3 Likes

Bumping this for the new year. Has anyone changed their opinions? Any thoughts on Gigalixir?

4 Likes

Hey @markdev, founder of gigalixir.com here in case you have any questions.

2 Likes

Hey @jesse, is there any documentation about setting up front-end services as subdomains?

Use case: I’d like to use Phoenix 1.3 on the back end at api.myapp.com, and have an elm client hosted on the same server, at frontend.myapp.com.