snapshotpolicy

command module
v0.0.0-...-c5dc7fc Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2019 License: Apache-2.0 Imports: 28 Imported by: 0

README

SnapshotPolicy

A Kubernetes controller for use in conjuction with VolumeSnapshot. This controller will create and retain volumesnapshot objects as declared.

Build

Check this out at $GOPATH/src/github.com/cisco-sso/snapshotpolicy

dep ensure
go build .

Or simply run docker build . anwywhere where this is checked out.

Example SnapshotPolicy

See artifacts/examples

apiVersion: snapshotpolicy.ciscosso.io/v1alpha1
kind: snapshotpolicy
metadata:
  name: demo-pvc-policy
spec:
  claims:
  - demo-pvc
  unit: minute
  period: 1
  retention: 3
  strategy:
    name: inuse

The above snapshot policy will create volume snapshots of the PersistentVolumeClaim named demo-pvc every 1 minute and retain 3 snapshots. Each time the control loop is ran when 3 snapshots exist one will be deleted.

Strategy InUse

A strategy has been added to perform no operation prior to creating the snapshot. Annotations have been added in the following branch of volume snapshot to achieve this and only support the openstack provider. https://github.com/cisco-sso/external-storage/tree/openstack-in-use-snapshots

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
pkg
apis/snapshotpolicy/v1alpha1
Package v1alpha1 is the v1alpha1 version of the API.
Package v1alpha1 is the v1alpha1 version of the API.
client/clientset/versioned
This package has the automatically generated clientset.
This package has the automatically generated clientset.
client/clientset/versioned/fake
This package has the automatically generated fake clientset.
This package has the automatically generated fake clientset.
client/clientset/versioned/scheme
This package contains the scheme of the automatically generated clientset.
This package contains the scheme of the automatically generated clientset.
client/clientset/versioned/typed/snapshotpolicy/v1alpha1
This package has the automatically generated typed clients.
This package has the automatically generated typed clients.
client/clientset/versioned/typed/snapshotpolicy/v1alpha1/fake
Package fake has the automatically generated clients.
Package fake has the automatically generated clients.

Jump to

Keyboard shortcuts

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