open-vault/vendor/github.com/cloudfoundry-community/go-cfclient
Jim Kalafut 2ee7b76469
Bundle MongoDB Atlas (#8309)
2020-02-07 14:09:39 -08:00
..
.gitignore add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
.travis.yml add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
Gopkg.lock add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
Gopkg.toml add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
LICENSE add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
README.md add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
app_update.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
app_usage_events.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
appevents.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
apps.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
buildpacks.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
cf_error.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
client.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
domains.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
environmentvariablegroups.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
error.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
events.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
go.mod add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
go.sum add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
info.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
isolationsegments.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
org_quotas.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
orgs.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
processes.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
route_mappings.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
routes.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
secgroups.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
service_bindings.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
service_brokers.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
service_instances.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
service_keys.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
service_plan_visibilities.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
service_plans.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
service_usage_events.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
services.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
space_quotas.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
spaces.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
stacks.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
tasks.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
types.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
user_provided_service_instances.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
users.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00
v3types.go add PCF auth method, agent, and cli handler 2019-06-06 12:26:04 -07:00

README.md

go-cfclient

Travis-CI GoDoc Report card

Overview

cfclient is a package to assist you in writing apps that need to interact with Cloud Foundry. It provides functions and structures to retrieve and update

Usage

go get github.com/cloudfoundry-community/go-cfclient

NOTE: Currently this project is not versioning its releases and so breaking changes might be introduced. Whilst hopefully notifications of breaking changes are made via commit messages, ideally your project will use a local vendoring system to lock in a version of go-cfclient that is known to work for you. This will allow you to control the timing and maintenance of upgrades to newer versions of this library.

Some example code:

package main

import (
	"github.com/cloudfoundry-community/go-cfclient"
)

func main() {
  c := &cfclient.Config{
    ApiAddress:   "https://api.10.244.0.34.xip.io",
    Username:     "admin",
    Password:     "admin",
  }
  client, _ := cfclient.NewClient(c)
  apps, _ := client.ListApps()
  fmt.Println(apps)
}

Development

Errors

If the Cloud Foundry error definitions change at https://github.com/cloudfoundry/cloud_controller_ng/blob/master/vendor/errors/v2.yml then the error predicate functions in this package need to be regenerated.

To do this, simply use Go to regenerate the code:

go generate

Contributing

Pull requests welcome.