Skip to content
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src/System/CloudFoundry
test
.gitignore
.hindent.yaml
.travis.yml
CHANGELOG.md
LICENSE
README.md
Setup.hs
cabal.config
cfenv-0.1.0.0.tar.gz
cfenv.cabal
package.yaml
stack.yaml

README.md

Haskell CFEnv

Build Status

A port of go-cfenv for Haskell.

The purpose of this library is to assist you in writing Haskell apps that run on Cloud Foundry. It provides convenience functions and structures that map to Cloud Foundry environment variable primitives.

Usage

{-# LANGUAGE OverloadedStrings #-}

import Data.String (fromString)
import Data.Monoid (mconcat)

import Web.Scotty

import qualified System.CloudFoundry.Environment as CfEnv

main = do
  app <- CfEnv.current
  
  scotty (CfEnv.port app) $
    get "/" $ do
      html $ mconcat ["<pre>", (fromString (show app)), "</pre>"] 

Documentation

For me information see cfenv on Hackage.

Missing Functionality

  • Find services by pattern matching
  • Some cases from go-cfenv around handling missing data
You can’t perform that action at this time.