jeramyRR

jeramyRR

Zero To Deployment in Elixir (Book Proposal)

Hi all,

I’ve been working on some small one-off Elixir projects at work, hoping to get more people at Microsoft hooked on Elixir. After a while I have realized that I’m not confident in my Elixir code nor my deployment models, at least not for the scale the applications would eventually serve. I’ve also felt that while the community has some really amazing books on Elixir, most of them focus on the basics rather than production level code, and few if any hit on CI/CD. We have books like Elixir In Action that are a wonderful source of quality information, but I think the community could use another type of book.

I’m proposing a book that takes a developer and walks them through building a production quality Elixir application from start to finish; by finish I mean deploying to the cloud with best practices like security in mind.

Below is what I’ve brainstormed for a project so far:

Project: An Incident Management System (IMS).

  • It will have two paths.
    • One for internal use
    • One for external use.
  • Will integrate with at least one external telemetry application like:
    • Prometheus
    • Azure / AWS Observability services like Application Insights
    • AppSignal
  • Emails notifications when new IMSs are created
    • Notifications can go to a mailing list, or on-call.
  • Auto creation of IMSs when telemetry signals are triggered
  • Suggest and provide links to TSGs when similar incidents are created
  • Keep track of how often the same incident is triggered when an IMS is open, essentially combining incidents into one ticket.
  • Provides discussion area in the ticket.
  • Provides link to a “bridge” between people working on the incident. Bridge can be done in Zoom, Teams, Slack, etc.
  • On-Call management
    • On-Call Scheduling
    • On-Call receives incident texts and emails

The books project will provide lots of opportunities to handle things like:

  • Failures (supervision or otherwise)
  • Integration with external apis:
    • External Telemetry services
    • Text services like Twillo
    • Chat services like Teams or Slack
    • Email providers
  • Application configuration
  • Application Security
    • Secure deployment practices
    • API security
    • Configuration security (with things like Azure Key Vault or HashiCorp Vault)
    • Authentication and Authorization

Along with the project the book will focus on the following:

  • Dev Environment

    • Setting up VS Code with a Docker Dev environment to match production resources. This includes the host OS container, dependencies such as a database and telemetry observability applications, basic VS Code plugins
  • Elixir toolchain

    • mix
    • releases
    • iex
    • etc.
  • Continuous Integration

    • Tests
    • Builds in Github or Azure DevOps
    • Automated Deployments
      • Infrastructure as Code
  • Application configuration

    • Application starting with different configurations depending on deployment environment.
    • Using third party or cloud provided tools like Azure Key Vault, AWS’s Key Management System, or something like Hashicorp’s Vault
  • Error handling

    • When to use Supervisors to handle errors and/or try/rescue
      • Let it crash is sometimes an option, but not always.
  • Telemetry

    • Logging
    • What type of Telemetry to collect (depending on the example application)
    • How and where to push
    • Setting up alerts for incident management and on-call (depending on the Telemetry Observability application provider) using our own application
  • Sending email as part of confirming pertinent user changes and information

  • Api Security

  • Unit tests and Integration tests

    • Also part of CI/CD
  • Data Persistence

    • Choosing the correct database type for our application
    • Using Ecto
    • Database Migrations
      • Including production

I’ve gotten permission from Luca (zero2prod.com) to create the domain zero2deploy.com. I probably didn’t need permission but felt that the name is so similar that it would be shameful not to run it by him first.

So, what makes me qualified to write this book?
Absolutely nothing when it comes to Elixir. Almost all of my experience is with deploying Java, C#, and Rust applications.

I’ve gotten a little off track. After all, the purpose of this post is to determine whether this is something the community wants, and to drum up some engagement. If you’re interested please join the mailing list at zero2deploy.com. I promise not to spam; I will only send out emails notifying about updates and releases to the book. If you see a “Not Secure” notification on the website it’s because I’m waiting on DNS to fully propagate at Netlify so I can get my LetsEncrypt cert, which should be within the next 24 hours.

Thanks for your time,
Jeramy

First Post!

stevensonmt

stevensonmt

I would LOVE a book on deployment, whether it’s elixir-specific or not.

Most Liked

DevotionGeo

DevotionGeo

There are two books on deployment by Miguel Coba. I have read none of these books, so I don’t know how detailed they are.

I joined the mailing list at zero2deploy .com and will still read Zero to Deployment in Elixir even if it releases after I have read Miguel Coba’s books.

luckywatcher

luckywatcher

I’d check out https://deploymentfromscratch.com/. It’s an awesome resource.

jeramyRR

jeramyRR

Thanks for linking those two, I didn’t even know they existed. We definitely need more on advanced topics like this in the Elixir community.

Last Post!

DevotionGeo

DevotionGeo

You’re welcome and thank you for planning this book!

Where Next?

Popular in Discussions Top

scouten
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 ...
New
Crowdhailer
I’ve been hearing much about the new formatter and it’s something I have been keen to try. I find examples buy far the most illuminating...
248 19814 150
New
PragTob
Hey everyone, this has been brewing in my head some time and it came up again while reading Adopting Elixir. GenServers, supervisors et...
New
Fl4m3Ph03n1x
Background A few days ago I was listening to The future of Elixir from Elixir Talks, with Dave Thomas (@pragdave ) and Brian Mitchell. I...
New
owaisqayum
I have a sample string sentence = "Hello, world ... 123 *** ^%&*())^% %%:>" From this string, I want to only keep the integers, ...
New
RudManusachi
What configs will make sense to put to runtime.exs? – A bit of how I configure apps: I have generic configs in config/config.exs, dev...
New
crispinb
On reading dhh’s latest The One Person Framework it strikes me that Phoenix with LiveView is already pretty much this. However, never hav...
New

Other popular topics Top

KronicDeth
Elixir plugin for JetBrain’s IntelliJ Platform (including Rubymine) This is a plugin that adds support for Elixir to JetBrains IntelliJ...
289 36820 110
New
vertexbuffer
Hello, can anybody help here..? I have a list of players and I what to delete an element, but every for loop the list is reverting to ori...
New
nsuchy
Hi. I’ve noticed that Windows Powershell has it’s own IEX command and you cannot access Elixir’s IEX due to the conflict. This isn’t a cr...
New
greenz1
I have a phoenix application from which a user can download multiple(5-6) files of size 1MB. I couldn’t find anything related to sending ...
New
Patoshizzle
After calling mix ecto.create I get this error: 17:00:32.162 [error] GenServer #PID<0.412.0> terminating ** (Postgrex.Error) FATAL...
New
jason.o
In the code below, if the create action is not set to accept “extra_key” as an input, it errors out with a message shown above. Is there ...
New

We're in Beta

About us Mission Statement