Documentation
¶
Overview ¶
TODO
See:
How to use this package ¶
First create a GceProvider object:
gceProvider := tcgceprovider.New(nil)
and then call one or more of gceProvider's methods, e.g.:
err := gceProvider.Ping(.....)
handling any errors...
if err != nil { // handle error... }
Taskcluster Schema ¶
The source code of this go package was auto-generated from the API definition at https://taskcluster-staging.net/references/gce-provider/v1/api.json together with the input and output schemas it references, downloaded on Tue, 29 Jan 2019 at 08:22:00 UTC. The code was generated by https://github.com/taskcluster/taskcluster-client-go/blob/master/build.sh.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GceProvider ¶
func New ¶
func New(credentials *tcclient.Credentials, rootURL string) *GceProvider
New returns a GceProvider client, configured to run against production. Pass in nil credentials to create a client without authentication. The returned client is mutable, so returned settings can be altered.
gceProvider := tcgceprovider.New( nil, // client without authentication "http://localhost:1234/my/taskcluster", // taskcluster hosted at this root URL on local machine ) err := gceProvider.Ping(.....) // for example, call the Ping(.....) API endpoint (described further down)... if err != nil { // handle errors... }
func NewFromEnv ¶
func NewFromEnv() *GceProvider
NewFromEnv returns a *GceProvider configured from environment variables.
The root URL is taken from TASKCLUSTER_PROXY_URL if set to a non-empty string, otherwise from TASKCLUSTER_ROOT_URL if set, otherwise the empty string.
The credentials are taken from environment variables:
TASKCLUSTER_CLIENT_ID TASKCLUSTER_ACCESS_TOKEN TASKCLUSTER_CERTIFICATE
If TASKCLUSTER_CLIENT_ID is empty/unset, authentication will be disabled.
func (*GceProvider) GetCredentials ¶
func (gceProvider *GceProvider) GetCredentials() error
Stability: *** EXPERIMENTAL ***
TODO ¶
See #getCredentials
func (*GceProvider) Ping ¶
func (gceProvider *GceProvider) Ping() error
Respond without doing anything. This endpoint is used to check that the service is up.
See #ping