Recent Posts
Periodic Tasks in Elixir, Conclusion
Following on from the last post, I needed a way to kick off the task of periodically checking for new entries in Redis and adding them to Postgres.
Scheduling tasks There are quite a few libraries to do this. There are also Tasks and Agents. None of these really seem to suit my problem definition.
I don’t need state other than the initial interval and the Redis key, so there’s no need for an Agent.
read more
Periodic Tasks in Elixir
Tonight, I’ll attempt to set up a Task that runs on some schedule and have it populate the Postgres database.
Quick background I built myself a link-saving site in Ruby, using Sinatra and fully backed by Redis. The site runs fine and I have a tonne of content saved. Amusingly for me, this content mirrors my career progression from the time I built the site until now. In spirit of learning Elixir, I’m rebuilding the site with it and backed by Postgres.
read more
Deploying Elixir to Digital Ocean
Deploying an Elixir/Phoenix app to Digital Ocean This is a quick post on some gotchas I ran into as I was trying to deploy to my DO droplet. At the bottom of the post are the Dockerfile and the build shell script I’m using, courtesy of Distillery’s documentation, with some modifications.
Releases and architectures To be fair, there are probably easier ways to get an Elixir app running. I could’ve pulled the code from Github and built on the same VM, much like any Ruby app.
read more