Switch branches/tags
Nothing to show
Find file History
Ward, Michael S Ward, Michael S
Ward, Michael S and Ward, Michael S add shebang so docker doesnt throw exec error
Latest commit 04ef085 Mar 24, 2017

readme.adoc

Couchbase Docker Image

This directory shows how to build a custom Couchbase Docker image that:

  1. Setups memory for Index and Data

  2. Configures the Couchbase server with Index, Data, and Query service

  3. Sets up username and password credentials

Build the Image

docker build -t arungupta/couchbase .

Run the Container

docker-compose up -d

Cluster using Docker Services

  1. Create network:

    docker network create \
    -d overlay \
    couchbase
  2. Create master:

    docker service create \
    --name couchbase-master \
    --replicas 1 \
    -p 8091:8091 \
    --network couchbase \
    -e TYPE=MASTER \
    arungupta/couchbase
  3. Create worker

    docker service create \
    --name couchbase-worker \
    --replicas 1 \
    --network couchbase \
    -e TYPE=WORKER \
    -e COUCHBASE_MASTER=couchbase-master.couchbase \
    -e AUTO_REBALANCE=false \
    arungupta/couchbase
  4. Scale cluster

    docker service scale couchbase-worker=2

Cluster using Kubernetes

  1. Create Master RC

    kubectl.sh create -f master-service.yml
  2. Create Worker RC

    kubectl.sh create -f worker-service.yml
  3. Scale cluster

    kubectl.sh scale --replicas=3 -f worker-service.yml