AWS in Switzerland and Austria (Alps)

Flying to production – How GVM Sion transformed aircraft reservation and management

View from airplane cockpit looking over the Alps and Rhone Glacier

Fig 1: Flying over the Rhone Glacier

How long does it take you to deploy to production with new features for a new customer? Is your answer less than one minute? In this blog post, we will describe how Switzerland’s oldest flight school, the Groupe de Vol à Moteur de Sion (GVM Sion), deploys to Amazon Web Services AWS in under a minute with the help of 56k.Cloud. Many things can get in the way of quickly delivering new features to your customers, such as legacy infrastructure or a manual deployment process impeding the removal of technical debt. We show how combining serverless infrastructure, automation, testing, and SaaS-ifying your application gives you agility in feature deployment.

Introduction

The GVM Sion is a prominent Swiss flight school and club located in the heart of the Alps in the Valaisan capital, Sion. With seven aircraft and more than 20 instructors, it provides its students with the ability to achieve the first major milestone in a flying career: a private pilot license (PPL). Being also a club, it provides its over 300 member pilots with aircraft rental and continuous flight training services.

Like many flight schools, GVM Sion was faced with aging aircraft reservation and management software that was becoming difficult to use. Pilots and instructors wanted a more mobile-friendly application, and staff wanted more management features. However, the existing application was a legacy app that received only basic maintenance.

In partnership with 56k.Cloud, GVM Sion decided to build a brand new reservation platform called Aviator. This platform will not only accompany GVM Sion in its flight operations over the coming years but will also be opened up to other flight schools, both in Switzerland and abroad, as an affordable modern multi-tenant SaaS application.

Screenshot of Aviator application, from the point of view of a pilot, showing a photo gallery of GVM’s Sion fleet.

Fig 2: Pilots view of Aviator dashboard.

Choosing your infrastructure, why serverless?

The first step in reducing your time to production is choosing the right infrastructure. Keeping things as simple as possible should be one of the fundamental guiding principles in software architecture. A question to ask yourself is whether all the architectural components you build and maintain are part of your company’s core identity and differentiate you from the competition? A more concrete example is whether building, operating, and maintaining a database is necessary? In most cases, while database deployment, maintenance, and security are essential, it’s not the reason you are creating the application. Serverless computing enables your application to scale elastically and simplify the deployment process. It allows engineers to concentrate on innovating and delivering value, rather than managing infrastructure.

Automating all the things

Screenshot of deployment architecture, showing workflow of the intial development commit through to server customer requests in production.

Fig 3: Deployment overview from feature branch to end use in production.

  1. Developers commit their work to a Git branch. Upon opening a pull request, a GitHub action is triggered, which deploys the changes to a development AWS account for automated end-to-end testing.
  2. After passing code review and merging to the mainline branch, a GitHub Action automatically deploys the changes to production using Pulumi. Changes to the front end,a NextJS app, are deployed by Vercel‘s own deployment workflows.
  3. Amazon Cognito authenticates pilots.
  4. The NextJS web app makes HTTP calls against the serverless backend. Amazon API Gateway authenticates the request’s JWT token using an AWS Lambda authorizer and issues short-term credentials.
  5. A Lambda function uses the issued credentials to access Amazon DynamoDB and serve the request.

Automation is critical in enabling quick deployments and starts with how you provision infrastructure on AWS. All serverless services are configured and deployed using Infrastructure as Code (IaC) with Pulumi. Pulumi is an easy-to-use, feature-rich, fast, open-source SDK for resource provisioning. It supports Go, the language used to write the application’s business logic. Go code compiles down to a lightweight single executable that is straightforward and quick to deploy in a Lambda function. Go supports cross-compilation, meaning one can use AWS’s ARM-based Graviton runtime environment for better efficiency and cost performance, even if the local or CI/CD environment uses classic x86 processors. Finally, being a modern statically typed language, it has fast startup times, minimizing Lambda cold start times. Startup times can be further minimized by reducing dependencies wherever possible, using Go’s standard solid library, and relying only on the official AWS SDKs to perform tasks. Frugality with your dependencies increases maintainability, reduces attack vectors, and keeps code binaries small. Lightweight binaries, in turn, reduce deployment times to Lambda.

CI/CD pipeline on GitHub Actions for automated deployments brings it all together. Code quality is maintained through pull requests (PRs) and automated testing, as described in the testing section below. Automating the deployment itself is straightforward: compile the Go binaries and run the Pulumi deployment command to perform infrastructure or code updates. Finally, the frontend is a React web application developed in TypeScript using NextJS and deployed to Vercel. Vercel provides its own CI/CD pipeline, which handles deployments.

A screenshot of the deployment process to AWS using Pulumi with a number of code updates (on the Lambda functions) deployed in under a minute.

Fig 4: A production deployment to AWS using Pulumi with a number of code updates (on the Lambda functions) deployed in under a minute.

Testing

Teams are interested in delivering features to production as frequently as possible. This, however, requires mature test automation in all stages of the CI/CD process. Serverless is well suited for this because ephemeral test environments can be easily managed. Aviator takes advantage of quick deployment times and low-cost environments to run a range of integration and end-to-end tests before code review and merging to the mainline branch. A dedicated GitHub Action automatically runs when opening or updating a PR to deploy and test the code under review in preview environments on AWS. After passing the review, the pull request is merged with the mainline branch. Another GitHub Action, automatically triggered by any change to the mainline branch, takes care of deploying and further testing on the production environment. Keeping deployments small and quick ensures confidence in deployment to production and parity between development and production environments.

On-boarding new customers using multi-tenancy

Finally, getting to production as quickly as possible not only involves managing new features, application versions, and infrastructure but also efficiently onboarding new customers. When multi-tenancy is an architectural afterthought, retrofitting it can make it challenging to keep up with customer demand. Aviator is built from the ground up to support multi-tenancy, and you can dive deeper in this blog post. It provides a pool multi-tenancy SaaS model, meaning all flight schools and clubs are hosted on the same infrastructure. Not only that, but users can belong to multiple tenants and switch between them seamlessly. New customers sign up directly through a self-service form. Then, the platform automatically onboards and registers the new tenant, allowing Aviator to expand to more flight schools across Switzerland and Europe.

Conclusion

GVM Sion transformed aircraft reservation and management with Aviator, a modern, scalable, and cost-efficient platform built with serverless technologies on AWS. Using API Gateway, Lambda and DynamoDB has enabled rapid feature development and deployment. Automation through IaC and CI/CD pipelines ensures seamless and quick updates, while rigorous testing guarantees reliability.

For flight schools interested in leveraging Aviator, onboarding is straightforward, and a guest mode environment is available for exploration. Developers inspired by Aviator’s success can build their serverless applications by following similar architectural principles. A detailed technical breakdown of Aviator’s architecture is available here.