Search code examples
dockeribm-cloudcloud-foundry

Docker container as CF garden


I want to run some test against local container which is Garden like, I want to use docker which should fits our requirement, is there some docker image /prototype which build as CF garden container ? with the FS like home/vcap/app/..... I just want to simulate E2E tests locally without deployment ...


Solution

  • It's hard to tell exactly what you're asking about here, so if this doesn't answer your question please expand your question. That said, if you're looking for the filesystem or "stack" that's used on CloudFoundry when you cf push an app that is currently called cflinuxfs and it's based off of Ubuntu 14.04 Trusty.

    The image itself is maintained as a docker image here -> https://hub.docker.com/r/cloudfoundry/cflinuxfs2/.

    If you want manually enter the container and work, maybe to run some tests or compile software locally, you can docker pull cloudfoundry/cflinuxfs2 and docker run cloudfoundry/cflinuxfs2 /bin/bash and run your tests in the resulting container. This will give you more control than using cflocal, as it will let you spin up a raw docker container with the same file system as an app running on CF and run whatever you want in that container.

    If your intent is to run buildpacks inside this container, then you should use the cflocal plugin because it will do basically what I said above but also handle running the buildpack in docker container that is created so it's way more convenient.

    Hope that helps!