

Running in Production
Nick Janetakis - Full stack developer
Hear about how folks are running their web apps in production. We'll cover tech choices, why they chose them, lessons learned and more.
Episodes
Mentioned books

Dec 12, 2019 • 59min
Discworld Disorganizer Is a Discworld Book Series Search Engine
In this episode of Running in Production, Jamie Taylor goes over how he
built Discworld Disorganizer which is a Discworld
book series search engine. It’s written in .NET Core and hosted for free on
Azure. It’s been running in production since 2017.
Jamie developed this app to scratch his own itch to help figure out which books
he already owns. The API portion of
the app is a separate app that is public and free to use. I learned a lot about
the .NET eco-system and even Discworld in this episode thanks to Jamie!
Topics Include
0:59 – .NET Core is open source and runs on Windows, MacOS and Linux
1:39 – The front-end is using Angular 2 and the back-end is using ASP .NET Core
2:33 – Differences between ASP .NET Core, .NET Core and picking a programming language
3:10 – .NET lets you write your program in multiple languages (C#, F# and VB.Net)
4:49 – Jamie picked C# primarily due to previous experience using it
6:35 – Jamie learns best by audio / video but also by building real projects
7:30 – Learning by example vs learning by theory
8:22 – Discworld is a series of comic fantasy books
9:52 – The world is a disc held up by 4 elephants standing on a turtle swimming in space
10:43 – Jame’s app lets you search for Discworld books, characters and locations
11:47 – He built the app to help him figure out which books he already has
12:34 – The search is handled by a free and open source RESTful API
13:58 – The API uses Swagger
that uses code as documentation to see example usages
14:43 – ASP .NET Core lets you pick server side templates or an API back-end
16:27 – Jamie wanted to learn a new front-end tool so he went API based with Angular 2
17:19 – The front-end and back-end take a few seconds to warm up due to Azure’s free tier
18:53 – That spin up time is similar to Heroku’s free tier and also how IIS works
20:00 – SQLite is being used to store the books and everything else on the back-end
21:18 – The API has a delete database endpoint but it’s protected by a strong password
21:55 – Entity Framework Core is used as an ORM (Object-relational mapper)
23:04 – Subtle differences between different databases like PostgreSQL and SQLite
23:48 – Maybe dropping EF Core for Dapper which is a light weight ORM
24:28 – Trade offs between using a high powered ORM and writing raw SQL
24:48 – The code itself uses the LINQ library from Microsoft to query the data
26:36 – The code base is 18 months old and it doesn’t use Docker, but it might soon
28:18 – Azure’s free tier (at the time) gave you free resources but you didn’t pick the specs
29:14 – Microsoft is very open about their platform, you can even visit their data centers
30:19 – Infrastructure as a Service (IaaS) vs Platform as a Service (PaaS)
32:51 – You get free SSL certificates with Azure’s PaaS offering on their domain
33:48 – You can use a custom domain name with Azure’s paid plans
35:09 – Walking through the deploy process from development to production
35:49 – After pushing to GitHub, AppVeyor (CI / CD) takes over and deploys it to Azure
37:44 – AppVeyor was used because Azure Pipelines wasn’t really around yet
38:14 – Using a third party CI / CD tool has less vendor lock-in too
39:49 – .NET Core rolls everything up into a single binary file that can be deployed
41:02 – Both the API back-end and Angular front-end have separate binary files
41:52 – Having single binary deployments makes it easier to manage deploys
42:29 – Most folks can run his project as long as you have the .NET Core run-time installed
45:05 – Jamie uses VSCode and JetBrains Rider instead of Visual Studio
47:23 – Dealing with Azure database backups using a real DB server and SQLite
48:35 – There is monitoring that keeps track of delete actions from the back-end API
49:52 – This delete action API endpoint wouldn’t be used for client work or a “real” project
50:25 – Jamie still uses his own app today to help keep track of which books he has
52:25 – Best tips? Focus on the data relationships before writing your code
53:22 – Switching the API from Discworld to Stephen King books, it works!
56:53 – You can find Jamie on GitHub and
@dotnetcoreshow
on Twitter where he posts updates about his .NET Core Podcast.
He also has an https://about.me/thejamietaylor page
Links
📄 References
https://docs.microsoft.com/en-us/aspnet/core/?view=aspnetcore-3.0
https://docs.microsoft.com/en-us/ef/core/
https://en.wikipedia.org/wiki/The_Art_of_Computer_Programming
https://en.wikipedia.org/wiki/Discworld
https://en.wikipedia.org/wiki/Open_API
https://en.wikipedia.org/wiki/HATEOAS
https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/concepts/linq/
https://en.wikipedia.org/wiki/Field-programmable_gate_array
https://en.wikipedia.org/wiki/PKCS_12
https://www.atlassian.com/git/tutorials/comparing-workflows/gitflow-workflow
⚙️ Tech Stack
dotnet-core →
angularjs →
appveyor →
azure →
c-sharp →
iis →
open-source →
sqlite →
Support the Show
This episode does not have a sponsor and this podcast is a labor of love. If
you want to support the show, the best way to do it is to purchase one of my
courses or suggest one to a friend.
Dive into Docker is a video course that takes you from not knowing what Docker is
to being able to confidently use Docker and Docker Compose for your own apps.
Long gone are the days of "but it works on my machine!". A bunch of follow
along labs are included.
Build a SAAS App with Flask is a video course where we build a real
world SAAS app that accepts payments, has a custom admin, includes high test
coverage and goes over how to implement and apply 50+ common web app features.
There's over 20+ hours of video.

Dec 9, 2019 • 56min
Qvault Is an Open Source Tool to Manage Passwords and Crypto Keys
In this episode of Running in Production, Lane Wagner goes over how he
built Qvault which is an open source password
manager that specializes in cryptocurrency. It’s built with Electron and has
a Serverless component that uses Golang. It’s all hosted on AWS.
If you were ever wondering how Serverless works in the context of building a
native or web application this episode has you covered. Lane talks about how a
bunch of different AWS services all come together to make it work. We also talk
about a Serverless framework called Serverless!
Topics Include
1:03 – Qvault is an Electron based password manager with a focus on cryptocurrency
2:16 – The focus has been a secure desktop app but a browser extension is coming soon
2:45 – Creating a secure browser extension without sharing your master key
3:12 – It’s an open source app, so if you’re skeptical you can compile it yourself
3:46 – Motivation for using Golang for the Serverless component
5:00 – For personal projects learning something new (Serverless) is worthwhile
5:48 – The TL;DR on what Serverless is and how it works
6:49 – AWS API Gateway helps map Serverless functions to HTTP requests
7:05 – Instead of 1 app with many routes, you have many individual functions
7:50 – A Serverless framework called Serverless helps tie everything together
8:33 – Tying in a Serverless function to a specific URL endpoint
9:25 – Calling these URL endpoints from the Electron app is like any other REST API
10:40 – What’s being executed within these Serverless functions?
11:12 – When it comes to Bitcoin and cryptocurrencies, it’s all about privacy and security
12:13 – Passwords are encrypted client side in the Electron app
13:17 – Encrypted vault file gets saved client side and it’s optionally saved server side too
14:01 – This data is stored inside of PostgreSQL using RDS within AWS
14:20 – Electron app -> API endpoint -> Serverless function -> data gets written to Postgres
14:49 – Using a managed database vs managing your own database
15:28 – The developer / development experience for writing Serverless functions
17:41 – When hacking on a new Serverless function, it just gets pushed to production
18:37 – The 2 biggest Serverless wins are function isolation and scaling auto-magically
18:56 – Serverless scales to the size of your wallet
19:21 – But it also costs nothing if no one is using it
20:02 – The turn around time for AWS to spin up an environment to run a Serverless function
20:35 – Function warming helps keep spin up times to milliseconds
21:44 – There are tricks to keep your functions warm to avoid a multi-second spin up time
22:21 – For Qvault’s API, response times were never a problem partly due to using Golang
22:53 – The Electron app is written in JavaScript using Vue
23:28 – Electron is basically a browser bundled with a specific JavaScript app
23:56 – Electron apps can be pretty bloated but it’s super convenient to develop with
24:45 – On Arch someone made a package that tries to use what you have installed already
25:43 – A recap of which AWS services are being used
26:02 – Using Route 53 on AWS for DNS hosting saves a lot of headaches
27:15 – Wait, how is CloudFront (Amazon’s CDN) being used on the back-end?
28:24 – It’s not, but CloudFormation is (it’s so easy to mix up AWS service names!)
28:33 – The TL;DR on what CloudFormation is, how it’s being used and why it’s useful
29:29 – Serverless framework converts platform agnostic configs into platform specific configs
30:03 – CloudFormation is especially handy for Serverless due to the number of endpoints
30:44 – Every Serverless endpoint is being served over HTTPS with Amazon’s ACM SSL certs
31:31 – There are no external software as a service dependencies besides what’s on AWS
32:04 – For logging, error reporting and metrics it’s all AWS services
32:36 – Getting logs from a Serverless function involves using CloudWatch and S3
32:53 – One nice thing about Serverless is there’s no long running state
33:45 – Strategies for dealing with database migrations with a Serverless set up
34:53 – Dealing with long running migrations that surpass AWS Lambda’s 15 minute timeout
36:41 – Lane is a big fan of CI / CD and the master branch always matching production
37:13 – A CI pipeline is being used for the Electron app with Travis CI
37:28 – The Electron app has an auto-update function to check for updates on demand
38:09 – The Serverless side of things doesn’t change much and there is no CI pipeline
38:42 – The turn around time is nearly instant for a new function version to take effect
39:59 – The Serverless framework sets environment variables for secret / sensitive values
41:01 – The work flow for changing a sensitive value to an existing Serverless function
43:18 – Dealing with disasters and malicious users
44:00 – Qvault hashes passwords before it’s sent to the server
45:50 – Running all of this on AWS costs in between $20 and $30 / month
46:36 – On AWS it’s easy to upgrade to a larger instance size but it’s hard to downgrade
46:42 – The RDS instance is running on a t2.micro since the DB is very simple
47:34 – Most of the app’s complexity is client side in the Electron app
48:10 – There’s 53k+ lines of code but that includes the node_modules/ directory
48:37 – The app itself has about 3-5k lines of code across ~40 files
49:01 – The complexity being on the front-end is necessary due to security requirements
49:32 – Lessons learned? Serverless couples your app logic to your provider, it’s not great
50:48 – There’s a lot of DevOps complexity where you trade 1 ops problem for another
51:25 – But Serverless is likely easier to set up than an entire Kubernetes cluster
51:39 – That being said, Serverless is very cost effective for low traffic APIs
52:12 – Lane would likely choose Serverless again for his specific use case
52:29 – Another nice thing about Serverless is not having to worry about scaling up
53:08 – Should you use Serverless for a traditional web application?
53:46 – It really depends on what you care about, such as cost vs development speed
54:16 – Serverless can get really expensive at larger scale (more so than regular hosting)
55:39 – You can find Lane on Twitter at @wagslane and his app can be found at qvault.io
Links
📄 References
https://en.wikipedia.org/wiki/Serverless_computing
https://en.wikipedia.org/wiki/Cryptocurrency
https://en.wikipedia.org/wiki/Bitcoin
https://serverless.com/
https://en.wikipedia.org/wiki/Representational_state_transfer
https://docs.aws.amazon.com/IAM/latest/UserGuide/id_users.html
https://serverless.com/blog/keep-your-lambdas-warm/
https://en.wikipedia.org/wiki/List_of_DNS_record_types
https://linux.die.net/man/1/kill
https://www.postgresql.org/docs/current/functions-json.html
https://medium.com/coryodaniel/from-erverless-to-elixir-48752db4d7bc
⚙️ Tech Stack
golang →
electron →
acm →
aws →
cloudformation →
cloudfront →
cloudwatch →
open-source →
postgres →
rds →
route53 →
s3 →
serverless →
travis-ci →
vue →
Support the Show
This episode does not have a sponsor and this podcast is a labor of love. If
you want to support the show, the best way to do it is to purchase one of my
courses or suggest one to a friend.
Dive into Docker is a video course that takes you from not knowing what Docker is
to being able to confidently use Docker and Docker Compose for your own apps.
Long gone are the days of "but it works on my machine!". A bunch of follow
along labs are included.
Build a SAAS App with Flask is a video course where we build a real
world SAAS app that accepts payments, has a custom admin, includes high test
coverage and goes over how to implement and apply 50+ common web app features.
There's over 20+ hours of video.

Dec 5, 2019 • 43min
EarlyBrd Alerts You of New Job Board Postings So You Can Bid Faster
In this episode of Running in Production, Stetson Blake goes over how he
built EarlyBrd using Flask which is a web framework
written in Python. This SAAS app focuses on sending out emails and it also
happens to use Stripe for subscriptions. It’s been up since March 2019.
Stetson’s motto has been to keep moving forward by writing code and making
decisions instead of getting hung up in endless research loops. His set up is
optimized for simplicity and to solve the problems he’s run into so far as a
solo developer working on the project.
Topics Include
1:44 – Running the latest stable build of Flask and Python 3.7.x
2:24 – Motivation for using Flask and Python
2:57 – Grappling with Django vs Flask
3:38 – Double edge sword, batteries included vs very few opinions
3:55 – Community support was a big factor in choosing Flask
5:32 – Stetson would choose Flask again if he re-wrote his app today
6:01 – The site uses server side templates with Jinja and no JavaScript
6:55 – Using what was built into Flask was a big factor in going with server side templates
7:30 – The app’s core functionality is emailing users when new jobs are available
7:56 – Starting to use Celery to send emails through MailGun
8:46 – The web front-end is basically a way to configure what emails you receive
9:38 – Sticking to a content delivery strategy that works for your app
11:01 – Earlybrd is mostly a monolithic application
11:23 – Being a solo developer is a nice match for having a monolithic app
11:52 – gunicorn is Stetson’s Python web server of choice
12:13 – PostgreSQL is being used as a database and everything runs in Docker
12:38 – A separate Python service does a bit of work outside of Celery
13:18 – There’s no admin dashboard, DB interaction is done with TablePlus (a GUI app)
14:44 – Finding a balance between making admin features vs user features
15:08 – Redis is being used as a back-end for Celery
15:22 – Everything is running in Docker containers through Docker Compose
16:18 – gunicorn is exposed to the internet directly
17:14 – AWS was chosen due to prior experience and loving it in general
18:00 – Everything runs on a single t2.micro EC2 instance
18:40 – Ubuntu 18.04 LTS is being used as the operating system
19:25 – Prometheus and Grafana are being used for monitoring and they run in a home lab
21:31 – Using a Python script, Dead Man’s Snitch and Uptime Robot for down time alerts
22:29 – What does Dead Man’s Snitch do?
23:45 – Using Sentry’s free tier for getting notified of app errors
24:25 – Using Slack to get notified of certain errors and alerts
24:50 – Stripe is being used to handle subscriptions after the free trial ends
25:55 – So many things for developers to learn and being surprised that anything works
26:24 – Walking through a code deploy from Stetson’s dev box into production
27:37 – Building your Docker images on your server vs using a Docker registry
28:22 – A little bit of down time between Docker Compose restarts
29:34 – No automated tests before git pushing the code, just linting
29:47 – The lack of tests mainly comes down to a lack of time
30:07 – To test or not to test, that is the question
31:00 – Daily sql dumps of the database to an S3 bucket managed by a cron job
31:38 – Choosing between cron jobs and Celery periodic tasks on a set interval
32:48 – Will everything come up if you forcefully reboot your server? Yep!
33:21 – Applying the 80 / 20 rule when it comes to disaster recovery
34:21 – Database migrations get run manually when necessary
35:02 – The main app is roughly 1,000 to 1,500 lines of Flask / Python code
35:28 – SQLAlchemy isn’t being used because there was a lot on the plate already
36:52 – Doing it the wrong way initially helps you understand why it might be wrong
38:01 – Best tips? Just get moving to the best of your ability
38:54 – Users not receiving alerts due to lack of monitoring was one mistake (but it’s fixed)
40:16 – End users (especially developers) tend to be forgiving with bugs if you’re honest
40:41 – Some developers enjoy hunting bugs and alerting someone if they found something
41:53 – You can find Stetson @stets_10 on Twitter and on LinkedIn, also check out EarlyBrd
Links
📄 References
https://www.python.org/dev/peps/pep-0373/
https://www.jetbrains.com/research/python-developers-survey-2018/
https://tableplus.com/
https://dbeaver.io/
https://aws.amazon.com/
https://github.com/prometheus/node_exporter
https://git-scm.com/book/en/v2/Git-on-the-Server-Getting-Git-on-a-Server
https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks
https://media.makeameme.org/created/i-dont-always-mt4th0.jpg
⚙️ Tech Stack
flask →
python →
aws →
cloudflare →
docker →
grafana →
mailgun →
postgres →
prometheus →
redis →
s3 →
sentry →
slack →
stripe →
ubuntu →
uptime-robot →
🛠 Libraries Used
https://github.com/celery/celery
https://gunicorn.org/
https://github.com/psf/black
https://github.com/sqlalchemy/sqlalchemy
Support the Show
This episode does not have a sponsor and this podcast is a labor of love. If
you want to support the show, the best way to do it is to purchase one of my
courses or suggest one to a friend.
Dive into Docker is a video course that takes you from not knowing what Docker is
to being able to confidently use Docker and Docker Compose for your own apps.
Long gone are the days of "but it works on my machine!". A bunch of follow
along labs are included.
Build a SAAS App with Flask is a video course where we build a real
world SAAS app that accepts payments, has a custom admin, includes high test
coverage and goes over how to implement and apply 50+ common web app features.
There's over 20+ hours of video.

Dec 2, 2019 • 1h 14min
Real Python Is One of the Largest Python Learning Platforms Around
Dan Bader, the mastermind behind Real Python, shares his journey in creating one of the largest Python learning platforms. He highlights how he transitioned from a PHP backend to a custom Django app, emphasizing the joyful developer experience with Django. Dan discusses the intricacies of managing a monolithic application, keeping dependencies up to date, and the importance of effective development practices. He also talks about the challenges of maintaining high-traffic uptime and shares insights on deploying with Heroku to optimize performance.

Nov 25, 2019 • 52min
Learn Elixir and Phoenix by Building Things Over at Alchemist Camp
In this episode of Running in Production, Mark guides us through
how he builds and deploys his video and article driven learning platform called
Alchemist Camp. The site gets about 12,000+
visitors a month and it’s all hosted on a single $10 / month DigitalOcean
server.
One takeaway is that you can be quite productive as a solo developer but the
bar is constantly being raised for what developers need to learn. For example,
at one point we talked about the new SCA workflows with Stripe since he
collects payments for subscriptions.
Topics Include
1:53 – What type of content does Alchemist Camp have?
3:41 – The whole platform was developed by Mark
4:12 – Motivation for using Elixir and Phoenix
5:17 – Would you use Phoenix again if you rewrote your app today?
6:52 – Finding a balance between productivity and ease of maintenance
7:51 – Alchemist Camp is a monolithic application but uses it Phoenix contexts
9:07 – The app has roughly 10,000+ lines of Elixir code across 240+ Elixir modules
10:02 – Monolithic apps work very well in a number of different use cases
10:42 – Server rendered templates with sprinkles of JavaScript
11:06 – There’s an API component but it’s for a public subscriber API to download videos
12:04 – The site is very speedy from an end user’s POV even without Turbolinks
12:24 – Waiting a bit longer before trying out Live View
12:48 – Pretty severe RSI limited development to 10 hours a week for a while
14:20 – PostgreSQL is the database of choice
14:34 – nginx is being used, primarily for handling Let’s Encrypt certificates
15:36 – nginx is also used to serve static files and deal with compression
16:29 – Docker is not being used in development, but it’s part of the deploy process
16:40 – Going over previous ways the app was deployed with distillery and edeliver
18:19 – Going over the current deployment method which still uses edeliver
18:25 – GitLab CI / CD helps push code to production with Docker and edeliver
19:05 – Docker isn’t used in production, processes are managed with systemd
19:34 – The server was just upgraded to run Ubuntu 18.04 LTS
20:34 – Everything (including the database) is running on 1 server on DigitalOcean
21:08 – Render is an interesting Heroku alternative that Mark might use next
22:34 – The server is manually configured but using Ansible is in the works
23:27 – Do everything manually first and then automate afterwards when needed
24:21 – Managed database service vs self hosting your own database
25:18 – Logging events into your own database vs using another service
26:30 – Using DigitalOcean’s built in monitoring dashboard
27:40 – It’s hosted on the $10 / month server with 1 CPU core and 2 GB of memory
29:03 – Using ETS with a custom GenServer for caching certain page responses
30:20 – It held up after many people slammed his site using various benchmark tools
31:28 – One bottleneck was compiling Markdown into HTML on each page load
33:09 – Amazon SES is being used to send transactional emails out
34:21 – Marketing emails are done with Mailchimp but that’s being moved to ConvertKit
36:25 – Using Stripe to handle subscription payments, and PayPal is done manually
37:45 – Barrier of entry for handling payments is going up with things like SCA
38:53 – Logging is old school, just hop on the server and check out the log files
39:12 – Taking advantage of DigitalOcean’s built in alerting system
40:34 – Using Let’s Encrypt for issuing SSL certificates with the Certbot tool
40:49 – DNS records are being hosted on DigitalOcean
41:28 – Getting notified by email if your SSL certificates are expiring soon
42:19 – Handling disasters with daily and weekly automated backups
43:17 – There’s lots of ways to backup a database, use the one that works best for you
44:27 – Database backups are being saved on DO Spaces (S3 compatible object storage)
44:59 – There’s no URL based health checks on the app itself but that may change soon
45:35 – Sometimes you can’t believe your site actually works because you don’t get alerts
46:58 – Best tips? Keep your code and infrastructure simple early on and ship your app
48:18 – Region based discount had a display bug, but developers (as end users) are forgiving
51:23 – You can find Mark @AlchemistCamp on Twitter and check out his new podcast
Links
📄 References
https://en.wikipedia.org/wiki/Domain-driven_design
https://nickjanetakis.com/blog/microservices-are-something-you-grow-into-not-begin-with
https://github.com/turbolinks/turbolinks
https://github.com/google/brotli
https://stackoverflow.com/a/414258 (using setcap)
https://soundcloud.com/elixirtalk/episode-157-feat-chris-mccord-liveviewphoenix-part-deux
https://elixirforum.com/t/7-5-second-average-page-load-speed-for-200-visitors-hitting-a-phoenix-driven-website-on-a-5-month-digital-ocean-droplet/15073
https://convertkit.com/
https://nanobox.io/
⚙️ Tech Stack
phoenix →
elixir →
digitalocean →
gitlab-ci →
lets-encrypt →
mailchimp →
nginx →
postgres →
render →
ses →
stripe →
systemd →
ubuntu →
🛠 Libraries Used
https://github.com/bitwalker/distillery
https://github.com/edeliver/edeliver
https://github.com/OvermindDL1/pid_file
https://github.com/whitfin/cachex
https://github.com/heresydev/stripy
Support the Show
This episode does not have a sponsor and this podcast is a labor of love. If
you want to support the show, the best way to do it is to purchase one of my
courses or suggest one to a friend.
Dive into Docker is a video course that takes you from not knowing what Docker is
to being able to confidently use Docker and Docker Compose for your own apps.
Long gone are the days of "but it works on my machine!". A bunch of follow
along labs are included.
Build a SAAS App with Flask is a video course where we build a real
world SAAS app that accepts payments, has a custom admin, includes high test
coverage and goes over how to implement and apply 50+ common web app features.
There's over 20+ hours of video.

Nov 18, 2019 • 58min
A Video Based AWS Certificate Training Platform Called Exam Pro
In this episode of Running in Production, Andrew Brown talks about how he
and his team use Ruby on Rails to build an AWS certification training platform
called Exam Pro. We talked about a huge range of
AWS services and how they all come together to run and deploy his application.
They’ve gone all-in with AWS. Even their development environment is running on
AWS using Cloud9 IDE. Exam Pro has been running in production since late 2018.
Topics Include
1:21 – A small team of developers actively work on the Exam Pro platform
2:40 – Motivation for using Ruby on Rails
4:52 – Would you use Rails again if you rewrote your app today?
5:21 – Monoliths are optimized for developer happiness not DevOps happiness
7:29 – Bypassing ActiveRecord to run raw SQL queries for database reads
8:19 – Using Rails Engines to break up the admin dashboard from the main app
9:22 – Trade offs for using 1 git repo vs multiple git repos
10:18 – Server side templates and a bit of JavaScript or an API back-end with lots of JS?
11:36 – Soon enough the front-end code will be completely separate and hosted on S3
12:02 – Pain points of using the asset pipeline and Rails specific build tools
13:57 – Action Cable is being used for something (but we don’t know what haha)
14:53 – Not using Sidekiq for background tasks, instead AWS SQS and the Ruby AWS SDK
16:47 – Docker is being used to run tests but not for dev and prod
18:38 – Cloud9 IDE is being used in development as an AWS based dev environment
20:03 – AWS Aurora is being used to manage a PostgreSQL database
21:01 – Your data is your most important asset, don’t leave it to chance
22:10 – A recap on what AWS SQS is and how it compares to Sidekiq, Resque or DelayedJob
23:26 – The main app responds back in 50-60 milliseconds without caching
25:29 – We never touch our servers, not even to SSH into them
26:40 – The Rails app is fronted by CloudFront and a load balancer, but not nginx
27:21 – SSL is terminated at the ELB level, not at each individual EC2 instance
28:27 – Comparing ELB to ALB and even NLB
29:07 – Strategies for migrating away from a monolithic application
29:59 – An S3 outage story that lead to using multi-region DNS fail over using Route 53
32:47 – What about error reporting, logging, monitoring and metrics?
35:27 – Sending transactional and campaign emails with SES and PinPoint
37:32 – Setting up 3rd party services with infrastructure as code tools is a huge win
39:24 – Sometimes there’s exceptions to the above, such as using Stripe to accept payments
41:08 – Configuration management on AWS with CloudFormation and Systems Manager
44:14 – They are using Amazon Linux 2 as their distro of choice
45:00 – Overall hosting costs less than $500 / month after all is said and done
45:49 – Zero down time deploys using blue / green deployments across 3 web servers
47:36 – Walking through a code deploy using various AWS resources and services
50:09 – Is is worth using managed services / mini-Heroku alternatives instead?
51:01 – Everyone Andrew knows who uses Heroku ends up leaving due to how pricey it is
52:20 – How do Rails database migrations get run?
52:42 – AWS really helps with database backups and disaster prevention / recovery
55:08 – Best tips and advice? Build a ton of apps and automate as much as possible
56:25 – You can find Andrew on Exam Pro,
LinkedIn,
YouTube,
dev.to,
GitHub and
Twitter.
Links
📄 References
https://en.wikipedia.org/wiki/Domain-specific_language
https://en.wikipedia.org/wiki/Center_for_Internet_Security
https://en.wikipedia.org/wiki/Application_performance_management
https://en.wikipedia.org/wiki/Payment_Card_Industry_Data_Security_Standard
⚙️ Tech Stack
rails →
ruby →
acm →
aurora →
aws →
cloudformation →
cloudfront →
cloudwatch →
codedeploy →
datadog →
docker →
ecs →
lambda →
postgres →
route53 →
serverless →
ses →
sqs →
stripe →
websockets →
🛠 Libraries Used
https://github.com/puma/puma
https://github.com/ExamProCo/dilithium.js
https://github.com/rails/webpacker
https://aws.amazon.com/sdk-for-ruby/
https://github.com/phstc/shoryuken
Support the Show
This episode does not have a sponsor and this podcast is a labor of love. If
you want to support the show, the best way to do it is to purchase one of my
courses or suggest one to a friend.
Dive into Docker is a video course that takes you from not knowing what Docker is
to being able to confidently use Docker and Docker Compose for your own apps.
Long gone are the days of "but it works on my machine!". A bunch of follow
along labs are included.
Build a SAAS App with Flask is a video course where we build a real
world SAAS app that accepts payments, has a custom admin, includes high test
coverage and goes over how to implement and apply 50+ common web app features.
There's over 20+ hours of video.

Nov 10, 2019 • 51min
Serving Medical University Employees, Health Officials and Students
In this episode of Running in Production, Gabriel Robertson talks about how he
uses Phoenix and Elixir to build and deploy an ever changing internal web
application that medical University employees, health officials and students
use to access various systems and resources.
The application has a number of interesting security, up-time and browser
compatibility requirements. It’s been running in production since 2017.
Topics Include
2:28 – Motivation for using Elixir and Phoenix
5:39 – Would you use Phoenix again if you rewrote your app today?
7:49 – Replacing Excel sheets and paper with a medical app that accesses an Oracle database
9:50 – Building an extensive security and permission system
10:24 – Supporting terminal browsers with server side templates and progressive JavaScript
11:18 – Employees, health officials and students use the app, it gets ~80 concurrent users
13:21 – Progressive enhancements with Drab (an Elixir library that competes with Live View)
16:51 – Using the BEAM and Cachex for caching data without using Redis
18:26 – Average page response times are in micro-seconds
18:39 – Docker is being used in development and production without Kubernetes or Swarm
20:45 – Using nginx as a reverse proxy, mainly for handling SSL certificates
21:52 – Assets are bundled with npm itself but Gabriel recommends using Webpack today
23:09 – Handling email transactions, error reporting, logging and metrics
25:48 – Everything is hosted on premises mainly for security reasons
27:50 – Running RedHat since it was installed before he got hired, but recommends Debian
28:56 – The Phoenix app runs on a VM with 40GB of storage, 8GB of memory and 6 CPU cores
29:19 – The primary server has 12TB of storage, 128GB of memory and 128 CPU cores
30:11 – The Phoenix app has 17,500+ lines of Elixir code spread across 150+ files
31:53 – It’s a pleasure to navigate, maintain and update the code base
34:04 – Configuration management is done with a VMware vSphere related tool
34:56 – Walking through a code deploy with Docker, Distillery and custom shell scripts
39:54 – 2 seconds of down time per deploy without a complex load balancer or orchestrator
41:03 – Handling disaster recovery by backing up the code and data every day
42:38 – Gabriel tried to bring down the app with a massive spike of traffic but it stayed up
44:37 – Best tips and advice? Love / learn Docker and use static typing when you can
48:19 – Separate your concerns and keep your functions short and simple
49:42 – You can find Gabriel on his site, GitHub, Twitter and on IRC at freenode #elixir-lang
Links
📄 References
http://yaws.hyber.org/
http://nitrogenproject.com/
https://lynx.browser.org/
https://elixirforum.com/t/potentially-removing-brunch-from-the-phoenix-new-template-generator/2454
https://soundcloud.com/elixirtalk/episode-157-feat-chris-mccord-liveviewphoenix-part-deux
https://elixirforum.com/t/pidfile-create-and-manage-a-pid-file-from-the-beam-process/7620
https://concourse-ci.org/
https://drone.io/
https://github.com/wg/wrk
https://github.com/JoeDog/siege
⚙️ Tech Stack
phoenix →
elixir →
docker →
lets-encrypt →
nginx →
oracle →
postgres →
redhat →
systemd →
vsphere →
🛠 Libraries Used
https://github.com/josefs/Gradualizer
https://github.com/OvermindDL1/gradualixir
https://github.com/jeremyjh/dialyxir
https://github.com/grych/drab
https://github.com/philss/floki
https://github.com/whitfin/cachex
https://github.com/bitwalker/distillery
Support the Show
This episode does not have a sponsor and this podcast is a labor of love. If
you want to support the show, the best way to do it is to purchase one of my
courses or suggest one to a friend.
Dive into Docker is a video course that takes you from not knowing what Docker is
to being able to confidently use Docker and Docker Compose for your own apps.
Long gone are the days of "but it works on my machine!". A bunch of follow
along labs are included.
Build a SAAS App with Flask is a video course where we build a real
world SAAS app that accepts payments, has a custom admin, includes high test
coverage and goes over how to implement and apply 50+ common web app features.
There's over 20+ hours of video.

Oct 18, 2019 • 3min
Preview of What's to Come
In this episode of Running in Production, Nick briefly talks about the goal of
this podcast which is to have developers / engineers on the show who are
running any web application in production. Guests will go into why they chose
their tech stack, lessons learned and everything in between.
Topics Include
0:41 – A site to learn details about how folks are running their site in production
1:13 – Are you a developer / engineer who runs a site in production? Become a guest
1:25 – From small side projects to massive sites at scale, everyone is welcome
1:52 – There’s also email based interviews if you want to do that instead
2:10 – I can really use your help getting this site off the ground (I’m not kidding!)
Links
Become a guest on the podcast
Get interviewed by email
Support the Show
This episode does not have a sponsor and this podcast is a labor of love. If
you want to support the show, the best way to do it is to purchase one of my
courses or suggest one to a friend.
Dive into Docker is a video course that takes you from not knowing what Docker is
to being able to confidently use Docker and Docker Compose for your own apps.
Long gone are the days of "but it works on my machine!". A bunch of follow
along labs are included.
Build a SAAS App with Flask is a video course where we build a real
world SAAS app that accepts payments, has a custom admin, includes high test
coverage and goes over how to implement and apply 50+ common web app features.
There's over 20+ hours of video.