Skip to content
Switch branches/tags

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

local volume release

This is a bosh release that packages a localdriver and a localbroker for consumption by a Cloud Foundry deployment.

local-volume-release is a "dummy" volume release that exposes ephemeral storage on the diego cell as a volume in cloud-foundry. As such it is really only suitable for experimenting with apps that require volumes. The easiest way to consume local-volume-release is to install PCFDev which comes with local-volume-release already included.

The instructions below will help you should you desire to install local-volume-release into your own Cloud Foundry deployment.

Deploying local-volume-release with Cloud Foundry


  1. Install Cloud Foundry, or start from an existing CF deployment. If you are starting from scratch, the article Overview of Deploying Cloud Foundry provides detailed instructions.

  2. Install GO:

    mkdir ~/workspace ~/go
    cd ~/workspace
    sudo tar -C /usr/local -xzf go1.9.linux-amd64.tar.gz
    echo 'export GOPATH=$HOME/go' >> ~/.bashrc
    echo 'export PATH=$PATH:/usr/local/go/bin:$GOPATH/bin' >> ~/.bashrc
    exec $SHELL
  3. Install direnv:

    mkdir -p $GOPATH/src/
    git clone $GOPATH/src/
    pushd $GOPATH/src/
        sudo make install
    echo 'eval "$(direnv hook bash)"' >> ~/.bashrc
    exec $SHELL

Create and Upload this Release

  1. Check out local-volume-release (master branch) from git:

    cd ~/workspace
    git clone
    cd ~/workspace/local-volume-release
    direnv allow
    git checkout master
    bosh -n create-release --force 
    bosh -n upload-release

Redeploy Cloud Foundry with local-volume-release enabled

  1. You should have it already after deploying Cloud Foundry, but if not clone the cf-deployment repository from git:

    $ cd ~/workspace
    $ git clone
    $ cd ~/workspace/cf-deployment
  2. Now redeploy your cf-deployment while including the local-volume-release ops file:

    $ bosh -e my-env -d cf deploy cf.yml \
    -v deployment-vars.yml \ 
    -o ../efs-volume-release/operations/enable-local-volume-service.yml

Note: the above command is an example, but your deployment command should match the one you used to deploy Cloud Foundry initially, with the addition of a -o ../local-volume-release/operations/enable-local-volume-service.yml option.

Your CF deployment will now have a running service broker and volume drivers, ready to create and mount local "volumes". Unless you have explicitly defined a variable for your service broker password, BOSH will generate one for you.
If you let BOSH generate the efsbroker password for you, you can find the password for use in broker registration via the bosh interpolate command:

bosh int deployment-vars.yml --path /local-broker-password

Register local-broker

cf create-service-broker localbroker admin <PASSWORD>
cf enable-service-access local-volume

Deploy pora and test volume services

cf create-service local-volume free-local-disk local-volume-instance
cf push pora -f ./assets/pora/manifest.yml -p ./assets/pora/ --no-start
cf bind-service pora local-volume-instance
cf start pora

Bind Parameters

  • mount: By default, volumes are mounted into the application container in an arbitrarily named folder under /var/vcap/data. If you prefer to mount your directory to some specific path where your application expects it, you can control the container mount path by specifying the mount option. The resulting bind command would look something like cf bind-service pora local-volume-instance -c '{"mount":"/var/foo"}'

Test the app to make sure that it can access your volume

  • to check if the app is running, curl should return the instance index for your app
  • to check if the app can access the shared volume curl writes a file to the share and then reads it back out again.


If you have trouble getting this release to operate properly, try consulting the Volume Services Troubleshooting Page


No description, website, or topics provided.




No packages published