resourcecontroller

package
v0.9.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 22, 2024 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Overview

Package resourcecontroller implements resourcecontroller code.

Index

Constants

View Source
const (
	// PowerVSResourceID is Power VS power-iaas service id, can be retrieved using ibmcloud cli
	// ibmcloud catalog service power-iaas.
	PowerVSResourceID = "abd259f0-9990-11e8-acc8-b9f54a8f1661"

	// PowerVSResourcePlanID is Power VS power-iaas plan id, can be retrieved using ibmcloud cli
	// ibmcloud catalog service power-iaas.
	PowerVSResourcePlanID = "f165dd34-3a40-423b-9d95-e90a23f724dd"

	// CosResourceID is IBM COS service id, can be retrieved using ibmcloud cli
	// ibmcloud catalog service cloud-object-storage.
	CosResourceID = "dff97f5c-bc5e-4455-b470-411c3edbe49c"

	// CosResourcePlanID is IBM COS plan id, can be retrieved using ibmcloud cli
	// ibmcloud catalog service cloud-object-storage.
	CosResourcePlanID = "1e4e33e4-cfa6-4f12-9016-be594a6d5f87"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ResourceController

ResourceController interface defines a method that a IBMCLOUD service object should implement in order to use the resourcecontrollerv2 package for listing resource instances.

func NewService

func NewService(options ServiceOptions) (ResourceController, error)

NewService returns a new service for the IBM Cloud Resource Controller api client.

type Service

type Service struct {
	// contains filtered or unexported fields
}

Service holds the IBM Cloud Resource Controller Service specific information.

func (*Service) CreateResourceInstance added in v0.8.0

CreateResourceInstance creates the resource instance.

func (*Service) CreateResourceKey added in v0.8.0

CreateResourceKey creates a new resource key.

func (*Service) DeleteResourceInstance added in v0.8.0

func (s *Service) DeleteResourceInstance(options *resourcecontrollerv2.DeleteResourceInstanceOptions) (*core.DetailedResponse, error)

DeleteResourceInstance deletes the resource instance.

func (*Service) GetInstanceByName added in v0.8.0

func (s *Service) GetInstanceByName(name, resourceID, planID string) (*resourcecontrollerv2.ResourceInstance, error)

GetInstanceByName returns instance with given name, planID and resourceID. If not found, returns nil.

func (*Service) GetResourceInstance

func (s *Service) GetResourceInstance(getResourceInstanceOptions *resourcecontrollerv2.GetResourceInstanceOptions) (result *resourcecontrollerv2.ResourceInstance, response *core.DetailedResponse, err error)

GetResourceInstance will get the resource instance.

func (*Service) GetServiceInstance added in v0.8.0

func (s *Service) GetServiceInstance(id, name string, zone *string) (*resourcecontrollerv2.ResourceInstance, error)

GetServiceInstance returns service instance with given name or id. If not found, returns nil. TODO: Combine GetSreviceInstance() and GetInstanceByName().

func (*Service) GetServiceURL added in v0.3.0

func (s *Service) GetServiceURL() string

GetServiceURL will get the service URL.

func (*Service) ListResourceInstances

func (s *Service) ListResourceInstances(listResourceInstancesOptions *resourcecontrollerv2.ListResourceInstancesOptions) (result *resourcecontrollerv2.ResourceInstancesList, response *core.DetailedResponse, err error)

ListResourceInstances will list all the resource instances.

func (*Service) SetServiceURL added in v0.3.0

func (s *Service) SetServiceURL(url string) error

SetServiceURL sets the service URL.

type ServiceOptions

type ServiceOptions struct {
	*resourcecontrollerv2.ResourceControllerV2Options
}

ServiceOptions holds the IBM Cloud Resource Controller Service Options specific information.

Directories

Path Synopsis
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL