aptomi

module
v0.1.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 5, 2018 License: Apache-2.0

README

Aptomi Logo

Release License Go Report Card Build Status Coverage Status Godoc GitHub last commit Slack Status

Aptomi simplifies roll-out, operation and control of container-based applications on k8s. It introduces a service-centric abstraction that allows Dev and Ops to collaborate asynchronously. It enables teams to create and operate services, share them across the organization, fully control their lifecycle while enforcing Ops/Governance policies. Changes and updates are executed with a goal of minimizing disruptive impact on depending services.

It is particularly useful in environments with multiple teams, clouds and data centers, where intent-based management plays an important role in running large application infrastructure. Aptomi’s current focus is Kubernetes, but it's designed to work with any container runtime and container orchestration technologies.

What is Aptomi

Demo

Short demo (5 minutes, Asciinema)

asciicast

Detailed demo (13 minutes, Youtube)

youtube

Table of contents

Features & Benefits

  • Deploy and manage container-based applications with ease
    • Dev and Ops think applications and services, not infrastructure primitives and thousands of containers
    • Built-in service discovery ensures all dependencies always are up to date
    • No need to change existing application templates (Helm, Ksonnet, k8s YAMLs, etc)
    • Run on k8s, OpenShift (support for AWS ECS, GKE, Docker Datacenter, Mesos is pluggable)
  • Lazy allocation of resources
    • Containers are only running when the corresponding service has consumers
  • Continuous state enforcement
    • Desired state of all services is rendered as a DAG system and continuously validated/enforced
    • Changes/rules can be enforced at any time (change service parameters, relocate the whole application w/ dependencies to another cluster, restrict access, etc)
    • Disruption impact of change on depending services is minimized
  • Flexible rule engine. Examples:
    • Production Instances get deployed to us-west, Staging Instances get deployed to us-west
    • Web and Mobile teams always share the same small flavor of Analytics service in Staging, while Healthcare team gets a dedicated high-performance instance of the same service
    • Development teams can never deploy to Production
    • Personal development instances of MyApp can only be running from 7am to 11pm and should be terminated overnight for all developers
  • Insights & Contextual visibility
    • UI to explore services instances, see why services were instantiated, visualize dependencies and impact of changes

Quickstart

Step #1: Installation

There are several ways to install Aptomi. The simplest one is Compact, but you may pick one that suits your needs:

Installation Mode Complexity Aptomi App Deployment Description
Compact Easy Local machine Yes Aptomi will be installed on a local machine (binaries or in a single Docker container)
Kubernetes Medium Container on k8s Yes Aptomi will be deployed on k8s via Helm chart

You can also install it in a stripped-down mode, mostly to explore concepts and look at API/UI. It will use a fake executor and thus will NOT be able to perform any app deployments to k8s:

Installation Mode Aptomi / UI App Deployment Description
Concepts Local machine No Use this only if you want get familiar with Aptomi concepts, API and UI. k8s is not required

Step #2: Setting up k8s Cluster

You need to have access a k8s cluster to deploy apps from the provided examples:

Kubernetes Cluster When to use How to run
Your own If you already have k8s cluster set up Configure Aptomi to use an existing k8s cluster
Google Kubernetes Engine Useful if you have a new Google account and free credits Configure Aptomi to use GKE
k8s / Minikube Single-node, local machine with 16GB+ RAM Configure Aptomi to use Minikube
k8s / Docker For Mac Single-node, local machine with 16GB+ RAM Configure Aptomi to use Docker For Mac

Having a powerful k8s cluster with good internet connection will definitely provide better experience compared to a single-node k8s local cluster. GKE would be one of the best options.

Step #3: Running Examples

Once Aptomi server is up and k8s cluster is ready, you can get started by running the following examples:

Example Description
twitter-analytics Twitter Analytics Application, multiple services, multi-cloud

How It Works

Architecture

Aptomi Components

State Enforcement

Aptomi Enforcement

Language

Aptomi Language

See language documentation

How to contribute

The very least you can do is to report a bug!

If you want to make a pull request for a bug fix or contribute a feature, see our Development Guide for how to develop, run and test your code.

In general, we are always looking for feedback on:

  • Aptomi object model - definitions of services, contracts, rules, clusters
  • Pluggability - support for additional label sources (in addition to LDAP), app engines (in addition to Helm), cloud providers

Contact us on Slack Status.

Roadmap

Feature Backlog, as well as weekly project milestones, are good places to look at the roadmap items.

If you have any questions, please contact us on Slack Status.

Directories

Path Synopsis
cmd
aptomi
Package aptomi is an implementation of command-line interface for Aptomi server (pkg/server).
Package aptomi is an implementation of command-line interface for Aptomi server (pkg/server).
aptomictl
Package aptomictl is an implementation of command-line interface for Aptomi client (pkg/client).
Package aptomictl is an implementation of command-line interface for Aptomi client (pkg/client).
pkg
api
Package api implements REST API support for Aptomi, including user-level and admin-level calls.
Package api implements REST API support for Aptomi, including user-level and admin-level calls.
config
Package config provides support for Aptomi configuration - Server config, Client config, and their common sections (API config)
Package config provides support for Aptomi configuration - Server config, Client config, and their common sections (API config)
engine
Package engine implements core engine of Aptomi, which does policy resolution (resolve), diff calculation between states (diff), and state enforcement by applying actions (apply).
Package engine implements core engine of Aptomi, which does policy resolution (resolve), diff calculation between states (diff), and state enforcement by applying actions (apply).
engine/actual
Package actual defines a state updater, which reacts to changes in actual state done by engine applier.
Package actual defines a state updater, which reacts to changes in actual state done by engine applier.
engine/apply
Package apply implements state enforcer, which executes a list of actions to move from actual state to desired state, performing actual deployment of services and configuration of the underlying cloud components.
Package apply implements state enforcer, which executes a list of actions to move from actual state to desired state, performing actual deployment of services and configuration of the underlying cloud components.
engine/apply/action
Package action defines a base action (actions get born a result of policy diff calculation), as well as context which gets passed to all actions during apply phase.
Package action defines a base action (actions get born a result of policy diff calculation), as well as context which gets passed to all actions during apply phase.
engine/apply/action/component
Package component defines all component-specific actions, which get generated by the policy diff when component changes occur for specific component instances.
Package component defines all component-specific actions, which get generated by the policy diff when component changes occur for specific component instances.
engine/apply/action/global
Package global defines a global post-processing action, which gets generated by the policy diff only once after processing all component instances.
Package global defines a global post-processing action, which gets generated by the policy diff only once after processing all component instances.
engine/diff
Package diff allows Aptomi to determine the difference between actual state (running on the cloud) and desired state (that Aptomi wants to enforce), generating a list of actions to reconcile the difference.
Package diff allows Aptomi to determine the difference between actual state (running on the cloud) and desired state (that Aptomi wants to enforce), generating a list of actions to reconcile the difference.
engine/progress
Package progress implements progress indicators, which are used during state enforcement while running actions and plugins to estimate progress and show completion percentage to the user.
Package progress implements progress indicators, which are used during state enforcement while running actions and plugins to estimate progress and show completion percentage to the user.
engine/resolve
Package resolve is a heart of Aptomi that performs policy resolution, taking policy and service consumption intents as input, producing a set of components to be instantiated in the cloud (desired state) as output, along with their discovery parameters, code parameters, and component instance graph.
Package resolve is a heart of Aptomi that performs policy resolution, taking policy and service consumption intents as input, producing a set of components to be instantiated in the cloud (desired state) as output, along with their discovery parameters, code parameters, and component instance graph.
errors
Package errors defines custom errors which are widely used across Aptomi code base.
Package errors defines custom errors which are widely used across Aptomi code base.
event
Package event implements support for Aptomi Event Logs and saving them to console, memory, and external stores (BoltDB).
Package event implements support for Aptomi Event Logs and saving them to console, memory, and external stores (BoltDB).
external
Package external implements support for all pluggable data sources which are external to Aptomi, such as users and secrets.
Package external implements support for all pluggable data sources which are external to Aptomi, such as users and secrets.
external/secrets
Package secrets implements support for retrieving user Secrets from external sources (File).
Package secrets implements support for retrieving user Secrets from external sources (File).
external/users
Package users implements support for retrieving Users and their labels from external sources (LDAP, File).
Package users implements support for retrieving Users and their labels from external sources (LDAP, File).
lang
Package lang provides core constructs for describing Aptomi policy, as well as core structures for processing policy.
Package lang provides core constructs for describing Aptomi policy, as well as core structures for processing policy.
lang/builder
Package builder provides simple and easy-to-use way to construct Aptomi Policy in the source code, primarily for unit tests.
Package builder provides simple and easy-to-use way to construct Aptomi Policy in the source code, primarily for unit tests.
lang/expression
Package expression provides support for evaluating expressions in Aptomi, with support for caching compiled expressions.
Package expression provides support for evaluating expressions in Aptomi, with support for caching compiled expressions.
lang/template
Package template provides support for evaluating text templates in Aptomi, with support for caching compiled templates.
Package template provides support for evaluating text templates in Aptomi, with support for caching compiled templates.
lang/yaml
Package yaml provides support for marshalling YAML objects and loading/unmarshalling them from YAML files.
Package yaml provides support for marshalling YAML objects and loading/unmarshalling them from YAML files.
plugin
Package plugin introduces plugins for Aptomi engine, which are responsible for component instantiation and management on different cloud providers (e.g.
Package plugin introduces plugins for Aptomi engine, which are responsible for component instantiation and management on different cloud providers (e.g.
plugin/helm
Package helm implements support for Helm plugin, which can deploy Helm charts onto k8s clusters via Helm API.
Package helm implements support for Helm plugin, which can deploy Helm charts onto k8s clusters via Helm API.
runtime/store/core
Package core allows to persist Aptomi engine objects into the object store.
Package core allows to persist Aptomi engine objects into the object store.
server
Package server implements Aptomi server, which serves UI front-end, API calls, as well as does policy resolution & continuous state enforcement.
Package server implements Aptomi server, which serves UI front-end, API calls, as well as does policy resolution & continuous state enforcement.
util
Package util contains various utility methods for working with data (slice, map, nested map, string, time) as well as system-level primitives (files, exec).
Package util contains various utility methods for working with data (slice, map, nested map, string, time) as well as system-level primitives (files, exec).
version
Package version allows to capture and store information about Aptomi binary (version, commit, date) so that we know when and how it was built.
Package version allows to capture and store information about Aptomi binary (version, commit, date) so that we know when and how it was built.
visualization
Package visualization implements Aptomi policy & resolution data visualization using network-based diagrams for visjs
Package visualization implements Aptomi policy & resolution data visualization using network-based diagrams for visjs

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL