Documentation ¶
Index ¶
- func ProjectID(authJSON []byte) (string, error)
- func ProjectIDFromFile(filename string) (string, error)
- func ProjectIDFromSecret(secret *corev1.Secret) (string, error)
- type Client
- type ListComputeImagesOptions
- type ListComputeInstancesOptions
- type ListComputeZonesOptions
- type ListManagedZonesOptions
- type ListResourceRecordSetsOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ProjectID ¶
ProjectID returns the GCP project ID specified in the GCP creds. The supplied byte slice contains the GCP creds.
func ProjectIDFromFile ¶
ProjectIDFromFile returns the GCP project ID specified in the GCP creds. The GCP creds are read from the specified file.
Types ¶
type Client ¶
type Client interface { ListManagedZones(opts ListManagedZonesOptions) (*dns.ManagedZonesListResponse, error) ListResourceRecordSets(managedZone string, opts ListResourceRecordSetsOptions) (*dns.ResourceRecordSetsListResponse, error) AddResourceRecordSet(managedZone string, recordSet *dns.ResourceRecordSet) error DeleteResourceRecordSet(managedZone string, recordSet *dns.ResourceRecordSet) error DeleteResourceRecordSets(managedZone string, recordSet []*dns.ResourceRecordSet) error UpdateResourceRecordSet(managedZone string, addRecordSet, removeRecordSet *dns.ResourceRecordSet) error GetManagedZone(managedZone string) (*dns.ManagedZone, error) CreateManagedZone(managedZone *dns.ManagedZone) (*dns.ManagedZone, error) DeleteManagedZone(managedZone string) error ListComputeZones(ListComputeZonesOptions) (*compute.ZoneList, error) ListComputeImages(ListComputeImagesOptions) (*compute.ImageList, error) ListComputeInstances(ListComputeInstancesOptions, func(*compute.InstanceAggregatedList) error) error StopInstance(*compute.Instance) error StartInstance(*compute.Instance) error }
Client is a wrapper object for actual GCP libraries to allow for easier mocking/testing.
func NewClient ¶
NewClient creates our client wrapper object for interacting with GCP. The supplied byte slice contains the GCP creds.
func NewClientFromFile ¶
NewClientFromFile creates our client wrapper object for interacting with GCP. The GCP creds are read from the specified file.
type ListComputeImagesOptions ¶
ListComputeImagesOptions are the options for listing compute images.
type ListComputeInstancesOptions ¶ added in v1.0.9
type ListComputeZonesOptions ¶
ListComputeZonesOptions are the options for listing compute zones.
type ListManagedZonesOptions ¶
ListManagedZonesOptions are the options for listing managed zones.