All Projects → koki → Short

koki / Short

Licence: apache-2.0
Manageable Kubernetes manifests through a composable, reusable syntax

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to Short

Wordpress Nginx Docker Compose
Run WordPress with nginx using Docker Compose.
Stars: ✭ 460 (+283.33%)
Mutual labels:  compose
Rooks
Essential hooks ⚓ to super charge your components!
Stars: ✭ 889 (+640.83%)
Mutual labels:  compose
Learn Jetpack Compose By Example
🚀 This project contains various examples that show how you would do things the "Jetpack Compose" way
Stars: ✭ 1,319 (+999.17%)
Mutual labels:  compose
Radiography
Text-ray goggles for your Android UI.
Stars: ✭ 482 (+301.67%)
Mutual labels:  compose
Hue
Open source SQL Query Assistant service for Databases/Warehouses
Stars: ✭ 351 (+192.5%)
Mutual labels:  compose
Jetpack Compose Playground
Community-driven collection of Jetpack Compose example code and tutorials 🚀 https://foso.github.io/compose
Stars: ✭ 969 (+707.5%)
Mutual labels:  compose
Compose Jb
Jetpack Compose for Desktop and Web, a modern UI framework for Kotlin that makes building performant and beautiful user interfaces easy and enjoyable.
Stars: ✭ 7,562 (+6201.67%)
Mutual labels:  compose
Twittercompose
TwitterCompose is an Android application 📱 for showcasing Jetpack Compose for building declarative UI in Android.
Stars: ✭ 109 (-9.17%)
Mutual labels:  compose
Compose Spec
The Compose specification
Stars: ✭ 603 (+402.5%)
Mutual labels:  compose
Docker Series
Docker Series about containerizing ASP.NET Core app with MySQL..
Stars: ✭ 88 (-26.67%)
Mutual labels:  compose
Schm
Composable schemas for JavaScript and Node.js
Stars: ✭ 498 (+315%)
Mutual labels:  compose
Docker Compose Elasticsearch Kibana
Docker Compose for Elasticsearch and Kibana
Stars: ✭ 584 (+386.67%)
Mutual labels:  compose
Opencompose
OpenCompose - A higher level abstraction for Kubernetes Resource
Stars: ✭ 66 (-45%)
Mutual labels:  compose
Next Compose Plugins
💡next-compose-plugins provides a cleaner API for enabling and configuring plugins for next.js
Stars: ✭ 465 (+287.5%)
Mutual labels:  compose
Androidcomposesamples
An Android app which provides examples for Android Jetpack Compose
Stars: ✭ 105 (-12.5%)
Mutual labels:  compose
Playandroid
🔥🔥🔥 Kotlin + MVVM + LCE版玩安卓,暗黑模式、横竖屏、无网、弱网、无数据、加载失败等等各种情况,协程、Room、Hilt、DataStore、LiveData、Retrofit、屏幕适配、本地缓存、多语言切换、多 lib,你想要的我都有!!!
Stars: ✭ 414 (+245%)
Mutual labels:  compose
Cloud Integration Beta
Docker CLI with ACI integration (beta)
Stars: ✭ 29 (-75.83%)
Mutual labels:  compose
Kompose
🔥 Architecture pattern for multiplatform mobile apps with Kotlin Multiplatform (common), SwiftUI (iOS) & Compose (Android).
Stars: ✭ 113 (-5.83%)
Mutual labels:  compose
To Do
A Kotlin Multiplatform to-do list app with SwiftUI and Compose UI frontends
Stars: ✭ 105 (-12.5%)
Mutual labels:  compose
Plasma
An Android Application written using latest Android Jetpack components and best practices, which displays trending movies/TV shows and cast, user can search movies and TV shows and also add them to watchlist.
Stars: ✭ 67 (-44.17%)
Mutual labels:  compose

Koki Short

Manageable Kubernetes manifests through composable, reusable syntax

Motivation

The description format for Kubernetes manifests, as it stands today, is verbose and unintuitive. Anecdotally, it has been:

  • Time consuming to write
  • Error-prone, hard to get right without referring to documentation
  • Difficult to maintain, read, and reuse

e.g. In order to create a simple nginx pod that runs on any host in region us-east1 or us-east2, here is the Kubernetes native syntax:

apiVersion: v1
kind: Pod
metadata:
  name: nginx
  labels:
    app: nginx
spec:
  containers:
  - name: nginx_container
    image: nginx:latest
  affinity:
    nodeAffinity:
      requiredDuringSchedulingIgnoredDuringExecution:
      	nodeSelectorTerms:
        - matchExpressions:
          - key: k8s.io/failure-domain
            operator: In
            values: 
            - us-east1
        - matchExpressions:
          - key: k8s.io/failure-domain
            operator: In
            value:
            - us-east2

The Short format is designed to be user friendly, intuitive, reusable, and maintainable. The same pod in Short syntax looks like

pod:
  name: nginx
  labels:
    app: nginx
  containers:
  - name: nginx
    image: nginx:latest
  affinity:
  - node: k8s.io/failure-domain=us-east1,us-east2

Our approach is to reframe Kubernetes manifests in an operator-friendly syntax without sacrificing expressiveness.

Koki Short can transform Kubernetes syntax into Short and Short syntax back into Kubernetes. No information is lost in either direction.

For more information on Koki Short transformations, please refer to Resources.

Modular and Reusable

Koki Short introduces the concept of modules, which are reusable collections of Short resources. Any resource can be reused multiple times in other resources and linked resources can be managed as a single unit on the Koki platform.

Any valid koki resource object can be reused. This includes subtypes of top-level resource types. For example, here's module called affinity_east1.yaml:

affinity:
- node: k8s.io/failure-domain=us-east-1

This affinity value can be reused in any pod spec:

imports:
- affinity: affinity_east1.yaml
pod:
  name: nginx
  labels:
    app: nginx
  containers:
  - name: nginx
    image: nginx-latest
  affinity: ${affinity}  # re-use the affinity resource here

For more information on Koki Modules, please refer to Modules.

Getting started

In order to start using Short, simply download the binary from the releases page.

#start with any existing Kubernetes manifest file
$$ cat kube_manifest.yaml
apiVersion: v1
kind: Pod
metadata:
  name: podName
  namespace: podNamespace
spec:
  hostAliases:
   - ip: 127.0.0.1
     hostnames:
      - localhost
      - myMachine
  affinity:
  nodeAffinity:
    requiredDuringSchedulingIgnoredDuringExecution:
     - matchExpressions:
        - key: k8s.io/failure-domain
          operator: In
          value: us-east1
  containers:
   - name: container
     image: busybox:latest
     ports:
      - containerPort: 6379
        hostPort: 8080
        name: service
        protocol: TCP
     resources:
        limits:
          cpu: "2"
          memory: 1024m
        requests:
          cpu: "1"
          memory: 512m

     
#convert Kubernetes manifest into a Short syntax representation
$$ short -f kube_manifest.yaml
pod:
  name: podName
  namespace: podNamespace
  affinity:
   - node: k8s.io/failure-domain=us-east1
  host_aliases:
   - 127.0.0.1 localhost myMachine
  containers:
   - image: busybox
     cpu:
       min: "1"
       max: "2"
     mem:
       min: "512m"
       max: "1024m"
     expose:
      - port_map: "8080:6379"
        name: service


#input can be json or yaml
$$ short -f kube_manifest.json -f kube_manifest2.yaml -f kube_multi_manifest.yaml

#stream input
$$ cat kube_manifest.yaml | short -

#revert to kubernetes type
$$ short -k -f koki_spec.yaml

#-k flag denotes that it should output Kubernetes manifest

For more information, refer to our getting started guide.

Contribute

Koki is completely open source community driven, including the roadmaps, planning, and implementation. We encourage everyone to help us make Kubernetes manifests more manageable. We welcome Issues, Pull Requests and participation in our weekly meetings.

If you'd like to get started with contributing to Koki Short, read our Roadmap and start with any issue labelled help-wanted or good-first-issue

Important Links

LICENSE

Apache v2.0

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].