Re: CF Local - Stage and launch CF apps locally in Docker


Dr Nic Williams <drnicwilliams@...>
 

Steven, that sounds very novel! Look forward to playing with it soon.

Dr Nic

On Thu, Mar 23, 2017 at 3:54 AM, Stephen Levine <slevine(a)pivotal.io> wrote:

Hi All,

This came up in another thread last month, and I've been encouraged to
share it more widely.

In my spare time, I've been working on a personal project called CF Local.
It allows you to:

1. Stage and launch CF app droplets locally in Docker, without CF
2. Download app droplets that have already been staged in CF, and run them
locally
3. Stage app droplets locally from source code, and push them to CF
4. Automatically tunnel service connections from a locally running app to
an app running in CF (using SSH forwarding), with zero configuration
required
5. Launch an app droplet locally, with the live-running app root mounted
to a local directory

For example, you could pull an app from CF to debug it:
$ cf local pull some-app
Then start it locally, connected to the same services as the remote app,
with the app root available locally as well:
$ cf local run some-app -f some-app -d some-dir

Or you could stage and run an app locally, connected to real CF services:
$ git clone https://github.com/sclevine/another-app
$ cd another-app
$ cf local stage another-app -f remote-app-providing-services
$ cf local run another-app -f remote-app-providing-services

The tool is available as a cf CLI plugin here: https://github.com/
sclevine/cflocal
And binaries are available for download here: https://github.com/
sclevine/cflocal/releases

CF Local communicates directly with the Docker daemon, so it doesn't
require a local Docker CLI.

Hope this is useful,
Stephen
--
Dr Nic Williams
Stark & Wayne LLC
http://starkandwayne.com
+61 437 276 076
twitter @drnic

Join cf-dev@lists.cloudfoundry.org to automatically receive all group messages.