Skip to content

Use CF buildpacks to turn windows apps into docker images

Notifications You must be signed in to change notification settings

dgodd/cfwindowsstager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CF Windows Stager

CF Windows Stager is designed to be a quick way to run Cloud Foundry buildpacks on an application.

This is particularly helpful when building a buildpack (or extension buildpack) where quick run loops are very helpful. Normally when testing buildpacks you need to package them up, create them in CF (which requires admin permissions) and then stage an app. Using CF Windows Stager, you can package the app, and instantly stage an app against it, all locally on your windows machine.

To download and run executables see releases

For descriptions of creating buildpacks, docs

This tool was inspired by cflocal and pack (both of which are currently linux only, whilst this tool runs best on windows).

Example run

go build

.\cfwindowsstager.exe --image fixme/myapp --app ..\hwc-buildpack\fixtures\windows_app\ --buildpack ..\hwc-buildpack\hwc_buildpack-cached-windows2016-v3.1.3.zip

docker run --rm -e PORT=8080 -p 8080:8080 cfwindowsstager/myapp

Then to see the results Invoke-WebRequest -Uri http://127.0.0.1:8080/ -UseBasicParsing

Build lifecycle.tar.gz

go run ./images/

Build executables

The executables on the release page

GOOS=linux go build -o cfwindowsstager.linux .
GOOS=darwin go build -o cfwindowsstager.darwin .
GOOS=windows go build -o cfwindowsstager.exe .
upx cfwindowsstager.{darwin,linux,exe}