Skip to content
Michael Neil edited this page Sep 28, 2018 · 39 revisions

mu

Amazon ECS (EC2 Container Service) provides an excellent platform for deploying microservices as containers. The challenge however is that there is a significant learning curve for microservice developers to deploy their applications in an efficient manner. Specifically, they must learn to use CloudFormation to orchestrate the management of ECS, ECR, EC2, ELB, VPC, and IAM resources. Additionally, tools like CodeBuild and CodePipeline must be mastered to create a continuous delivery pipeline for their microservices.

To address these challenges, this tool was created to simplify the declaration and administration of the AWS resources necessary to support microservices. Similar to how the Serverless Framework improved the developer experience of Lambda and API Gateway, this tool makes it easier for developers to use ECS as a microservices platform.

The mu tool uses CloudFormation stacks to manage all resources it creates. Additionally, mu will not create any databases or other AWS resources to support itself. It will only create resources (via CloudFormation) necessary to run your microservices. This means at any point you can stop using mu and continue to manage the AWS resources that it created via AWS tools such as the CLI or the console.

Architecture Diagram

Demo

Watch the 90 second demo below to see mu in action!

Demo

Getting Started

Install latest version to /usr/local/bin (or for additional options, see wiki):

curl -s https://getmu.io/install.sh | sh

Assuming your project already has a Dockerfile, you can initialize your mu.yml file with: mu init. More details available in the quickstart.

Examples

Check out the the following snippets of mu.yml configuration that you can use in your own project:

  • Basic - Simple website with continuous delivery pipeline deploying to dev and prod environments
  • Test Automation - Example of automating end-to-end testing via Newman
  • Databases - Defining databases for a service
  • Scheduled Tasks - Defining commands to be run on a recurring schedule
  • Env Variables - Defining environment variables for the service
  • Local Env Variables - Substituting local environment variables into mu.yml
  • HTTPS - Enable HTTPS on the ALB for an environment
  • DNS - Associate Route53 resource record with ALB for an environment
  • VPC Target - Targeting an existing VPC for an environment
  • Custom CloudFormation - Demonstration of adding custom AWS resources via CloudFormation
  • VPN Connection - Demonstration of adding VPN via CloudFormation
  • Traditional Infrastructure - Demonstration of using EC2 + CodeDeploy rather than ECS for running services

Reference Implementations

Implementation Description
Wordpress Demonstration of deploying PHP application with database
Sinatra Demonstration of deploying Sinatra application
Rails Demonstration of deploying Rails application
ASP.NET Core 2.0 Running .NET on ECS
Spring Boot Running Spring Boot on ECS
NGINX Simple webserver on ECS
DynamoDB Service that uses a private DynamoDB extension
SPA Single-page Application with CloudFront
EC2 Deploying VPC, EC2 instances, ALB, and RDS instances without configuring or deploying an application
Node.js Deploying a Node.js application
Crystal Deploying a Crystal application

Reference

Refer to the following for complete details on the configuration of mu.yml and the cli usage:

Support

Need help? Check out the FAQ to try to find an answer to your question. If you can't find an answer there, ask on Gitter!

Contributing

Want to contribute to Mu? Awesome! Check out the contributing guidelines to get involved.