Automating Docker Deployment with Github Actions

As developers, we often need to deploy applications to server environments. In this guide, I’ll show you how to automate Docker container deployments using GitHub Actions, Docker Hub, and a simple cron job. Whether you’re new to Docker or looking to streamline your deployment process, this tutorial will walk you through both manual and automated approaches. Part 1: The Manual Process Before building an Docker image, we setup a simple web server in main....

January 18, 2025 · Max Scheijen

Azure Functions and FastAPI

I’m a huge fan of FastAPI. It’s a high-performance web framework for building APIs in Python, based on type hints and Pydantic, which enables automatic documentation and data validation. At work, we extensively use Azure Functions. These are serverless resources that reduce the need for infrastructure configuration and maintenance, allowing us to focus more on writing code. To create Azure Functions in Python, we can use the azure-functions package. However, I really love FastAPI as a framework for building APIs....

December 14, 2024 · Max Scheijen

HTML Form and JSON for single endpoint in FastAPI

A common challenge when building a FastAPI application is handling different content types, like JSON and Form data. Any many cases your API needs to support both formats, especially when dealing with web forms and modern front-end applications that often send json payloads. This post demonstrates how to build a FastAPI application that handles and validates both JSON and from data inputs on a single endpoint. The Challenge: Handling Different Content Types By default, web browsers use application/x-www-form-urlencoded or multipart/form-data content types when submitting forms....

October 5, 2024 · Max Scheijen