Low-cost, no-fuss Elixir app hosting?

I’m looking for a host for the server part of a small (personal) side project that I’m working on. It’s currently written in Node.js and hosted on Heroku. I’m now rewriting that server in Elixir and looking for a suitable host.

The “server” is a daemon that periodically reads some public API data (local transit schedules) and remixes them into a format that is more suitable for a mobile client application I’m writing and places that data into a database. (The database will be hosted by Cloudant and is not part of this server.) The process is pretty lightweight.

I might take an occasional HTTP request, but that is about it.

Can you recommend a good host for such a service?

4 Likes

I would always recommend a dedicated server if your budget can stretch to it - you just get so much more for your money.

Here are some other threads on the topic you might find interesting:

3 Likes

Dedicated hosting is serious overkill for the app I’m building. I’m surprised by the frequent references to Heroku; thought Elixir wasn’t supported there.

3 Likes

DO all the way, a simple app can be hosted on a 5usd droplet which is the price of a cheap shared host :slight_smile:

4 Likes

@scouten I don’t know how you got the opinion that Elixir wasn’t supported on Heroku. The Heroku platform is highly extensible through the use of buildpacks. The most common Elixir buildpack is the HashNuke distribution. Both at my previous company and my current company, we used this to deploy production-grade Elixir applications via the Heroku ecosystem.

Overall, there are reasons to not run a long-term production Elixir application on Heroku due to certain limitations of the infrastructure (like < 24 hour uptime guarantees, inviability of clustering, etc.), I recommend it for people who are looking to get off the ground with their first Elixir application. The limitations of Heroku need to be weighed against the requirements of the application. If you already have the NodeJS application running on the Heroku ecosystem, most likely it will meet the requirements of the Elixir version.

3 Likes

By periodically, do you mean that it is an option to stop/start the server on some kind of schedule? If so, then perhaps this page for starting/stopping ec2 instances might be good for you. That page uses the CloudWatch events to trigger the start/stop of the ec2 instance, and it mentions a data pipeline method which is described in detail here.

I’ve never done this personally with AWS. :smile: I do know, however, that if you need something that has a static IP address, then the reserved IP costs money even if the instance is not running (since it’s being reserved). It sounds like you’re only making an occasional outbound request, so that may not be relevant.

2 Likes

Heroku should do the job just fine for your use case. The big limitation is that you can’t use distributed Erlang on it (since the dynos can’t connect directly to each other), but for a small app running on a single dyno, it doesn’t matter.

2 Likes

This Phoenix guide might also help:

http://www.phoenixframework.org/docs/heroku

3 Likes