Giter VIP home page Giter VIP logo

lostromos's Introduction

Lostrómos

Build Status codecov

NOTE: Under active development. Not ready for production usage.

Problem statement

Lostrómos is a way to manage deployments through Custom Resources. This allows a user to harness the power and flexibility of the Kubernetes platform to more easily control resources through outside applications.

WP Engine uses Lostrómos to customize deployments into GKE. As we spin up new clusters, we use another tool to monitor the google api for changes and update Custom Resources as they happen. Lostrómos watches for Custom Resources and applies a predefined template based on the information received. This allows us to deconstruct a larger service by deliniating based on functionality. Our applications now manage resources, and Lostrómos handles the deployments.

How it works

Lostrómos is a service that creates Kubernetes resources based on a Custom Resource endpoint in the Kubernetes API. It is an implementation of the Operator pattern established by CoreOS.

Lostrómos manages objects (pods, sets, jobs - anything that can be managed with a CRD) via Helm or Go templates, using values from Custom Resources as new events are captured from the Kubernetes API. It applies templates to the corresponding objects to reconcile with Kubernetes.

It is intended to be deployed into a Kubernetes cluster. Its main configuration details are:

  • An API endpoint of a Custom Resource Definition to watch
  • A set of go templates to apply for each Custom Resource

Its configuration could also include shared values to use in the templating (eg. docker image in deployments, a common annotation or label).

Dependencies

Dependency Version
Golang 1.9.0+
Minikube 0.22.3+
Docker 17.09.0+
Python 3.0+

Quick Start

NOTE: This assumes you have all of the above dependency requirements.

Run the following script (changing out os_version for darwin/linux/windows depending on your system) to get a basic setup. This script will install Go and Python dependencies, build Lostrómos, build a docker image with Lostrómos, then run it in Minikube and perform integration testing.

make install-go-deps
make vendor
make install-python-deps
make build-cross
./out/lostromos-os_version-amd64 version
minikube start
eval $(minikube docker-env) # This links docker with minikube so that the image you build in the next step will be available.
make docker-build-test
kubectl create -f test/data/crd.yml
kubectl expose pod lostromos --type=LoadBalancer
make LOSTROMOS_IP_AND_PORT=`minikube service lostromos --url | cut -c 8-` integration-tests
eval $(minikube docker-env -u) # Unlinks minikube and docker.

Using Lostrómos

Contributing

See Contribution Guildelines to get started.

Report a Bug

To report an issue or suggest an improvement please open an issue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.