Name: local-volume-release
Owner: Cloud Foundry
Description: null
Created: 2016-06-14 17:33:16.0
Updated: 2018-05-07 23:27:19.0
Pushed: 2018-05-07 23:27:18.0
Homepage: null
Size: 189
Language: Shell
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
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.
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.
Install GO:
r ~/workspace ~/go
/workspace
https://storage.googleapis.com/golang/go1.9.linux-amd64.tar.gz
tar -C /usr/local -xzf go1.9.linux-amd64.tar.gz
'export GOPATH=$HOME/go' >> ~/.bashrc
'export PATH=$PATH:/usr/local/go/bin:$GOPATH/bin' >> ~/.bashrc
$SHELL
Install direnv:
r -p $GOPATH/src/github.com/direnv
clone https://github.com/direnv/direnv.git $GOPATH/src/github.com/direnv/direnv
d $GOPATH/src/github.com/direnv/direnv
make
sudo make install
'eval "$(direnv hook bash)"' >> ~/.bashrc
$SHELL
Check out local-volume-release (master branch) from git:
/workspace
clone https://github.com/cloudfoundry/local-volume-release.git
/workspace/local-volume-release
nv allow
checkout master
ripts/update
-n create-release --force
-n upload-release
You should have it already after deploying Cloud Foundry, but if not clone the cf-deployment repository from git:
~/workspace
t clone https://github.com/cloudfoundry/cf-deployment.git
~/workspace/cf-deployment
Now redeploy your cf-deployment while including the local-volume-release ops file:
sh -e my-env -d cf deploy cf.yml \
eployment-vars.yml \
./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:
int deployment-vars.yml --path /local-broker-password
reate-service-broker localbroker admin <PASSWORD> http://local-broker.YOUR.DOMAIN.com
nable-service-access local-volume
reate-service local-volume free-local-disk local-volume-instance
ush pora -f ./assets/pora/manifest.yml -p ./assets/pora/ --no-start
ind-service pora local-volume-instance
tart 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
curl http://pora.YOUR.DOMAIN.com
should return the instance index for your appcurl http://pora.YOUR.DOMAIN.com/write
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