spire-plugin-datastore-k8s

command module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: May 6, 2019 License: Apache-2.0 Imports: 23 Imported by: 0

README

Kubernetes datastore plugin for SPIRE server

A SPIRE datastore plugin that enables you to store data using Kubernetes Custom Resource.

Motivation

  • Make running SPIRE Server on Kubernetes simpler
  • Enables SPIRE Server to run without managing persistent volumes

Installation

Download latest binary and install it to the plugin directory.

$ curl -L -O https://github.com/summerwind/spire-plugin-datastore-k8s/releases/latest/download/spire-plugin-datastore-k8s-linux-amd64.tar.gz
$ tar zxvf spire-plugin-datastore-k8s.tar.gz
$ mv spire-plugin-datastore-k8s /path/to/plugin

Configuration

The plugin accepts the following configuration options:

Configuration Description
namespace Kubernetes namespace to manage custom resources
kubeconfig Path to configuration file to access kubernetes API

A sample configuration for SPIRE server:

plugins {
  DataStore "k8s" {
    plugin_cmd = "/path/to/plugin"
    plugin_data {
      namespace = "spire"
    }
  }
}

Deploying to Kubernetes

You must create CustomResourceDefinition (CRD) resources in your Kubernetes cluster before you deploy the plugin. Create CRDs as follows:

$ curl -L https://github.com/summerwind/spire-plugin-datastore-k8s/releases/latest/download/crd.yaml | kubectl apply -f -

In addition, the Pod of the SPIRE server must have permissions to manage the resources of the CRDs you created. See example manifest below for more information about permissions.

Build from soruce

To build a binary from source, first build the container image and get the binary from it.

$ git clone https://github.com/summerwind/spire-plugin-datastore-k8s
$ cd spire-plugin-datastore-k8s
$ make build-container
$ docker create -n spire summerwind/spire:latest
$ docker cp spire:/opt/spire/bin/spire-plugin-datastore-k8s ./
$ docker rm spire

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
pkg
apis
Package apis contains Kubernetes API groups.
Package apis contains Kubernetes API groups.
apis/v1alpha1
Package v1alpha1 contains API Schema definitions for the kubernetes datastore v1alpha1 API group +k8s:openapi-gen=true +k8s:deepcopy-gen=package,register +k8s:conversion-gen=github.com/summerwind/spire-plugin-datastore-k8s/pkg/apis +k8s:defaulter-gen=TypeMeta +groupName=kubernetes.spire.summerwind.dev
Package v1alpha1 contains API Schema definitions for the kubernetes datastore v1alpha1 API group +k8s:openapi-gen=true +k8s:deepcopy-gen=package,register +k8s:conversion-gen=github.com/summerwind/spire-plugin-datastore-k8s/pkg/apis +k8s:defaulter-gen=TypeMeta +groupName=kubernetes.spire.summerwind.dev

Jump to

Keyboard shortcuts

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