GithubHelp home page GithubHelp logo

isabella232 / aerospike-kubernetes Goto Github PK

View Code? Open in Web Editor NEW

This project forked from aerospike/aerospike-kubernetes

0.0 0.0 0.0 3.7 MB

Home Page: http://www.aerospike.com/docs

License: Apache License 2.0

Shell 49.59% Mustache 50.41%

aerospike-kubernetes's Introduction

aerospike-kubernetes

This project uses Aerospike Server Community Edition. For Aerospike Server Enterprise Edition, please refer aerospike/aerospike-kubernetes-enterprise.

This project contains the init container used in Kubernetes (k8s) and the Aerospike StatefulSet definition. These manifests will allow you to deploy a fully formed Aerospike cluster in minutes.

It uses:

Usage:

Configure:

Set environment variables (modify if necessary):

export APP_NAME=aerospike
export NAMESPACE=default
export AEROSPIKE_NODES=3
export AEROSPIKE_NAMESPACE=test
export AEROSPIKE_REPL=2
export AEROSPIKE_MEM=1
export AEROSPIKE_TTL=0
export AEROSPIKE_NSUP_PERIOD=0 # if AEROSPIKE_TTL is not 0, AEROSPIKE_NSUP_PERIOD should not be 0.

All AEROSPIKE_* parameters except AEROSPIKE_NODES, AEROSPIKE_MEM are optional. Default values are listed above. All other parameters are required.

Configuring Storage:

The statefulset definition refers to a custom StorageClass ssd. You can find the storageclass ssd definition in storageclass-aws.yaml or storageclass-gcp.yaml (Uncomment them to use). You can also define your own storageclass and use it within the statefulset definition.

Dynamic provisioning for local volumes are not supported yet. However, a local volume provisioner can be deployed to automate the provisioning of local devices. Please check examples/ for using a local volume static provisioner.

If you want to use the raw block volume mode, you need to define volumeMode as Block in the Volume Claim and use volumeDevices and devicePath instead of volumeMounts and mountPath as shown in the example below.

  volumeClaimTemplates:
  - metadata:
      name: data-dev
      labels: *AerospikeDeploymentLabels
    spec:
      volumeMode: Block
      accessModes:
        - ReadWriteOnce
      storageClassName: ssd
      resources:
        requests:
          storage: ${AEROSPIKE_MEM}Gi
.....
volumeMounts:
        - name: confdir
          mountPath: /etc/aerospike
volumeDevices:
        - name: data-dev
          devicePath: /dev/sdb
.....

For Kubernetes version > 1.11, there's a default storage class gp2 available on AWS EKS clusters, uses aws-ebs provisioner and volume type gp2.

Examples:

To view and run the examples, go to examples/

Deployment:

Please follow the below steps or run start.sh script:

  1. Expand manifest template:
cat manifests/* | envsubst > expanded.yaml
  1. Create the configmap object:
kubectl create configmap aerospike-conf -n $NAMESPACE --from-file=configs/
  1. Deploy:
kubectl create -f expanded.yaml

Helm Charts

Helm chart for the same can be found here

Requirements

  • Kubernetes 1.8+
  • Kubernetes DNS add-in

aerospike-kubernetes's People

Contributors

danielcoman avatar eastresident avatar ken-tune avatar mtendjou avatar spkesan avatar vbehar avatar whyrg avatar

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.