Skip to content

Commit

Permalink
create the IBMCLoudPlatform type for use in the ingress operator
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreaM12345 committed Jan 17, 2020
1 parent 0e2ff1e commit 1edb92e
Show file tree
Hide file tree
Showing 6 changed files with 59 additions and 4 deletions.
26 changes: 26 additions & 0 deletions config/v1/types_infrastructure.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,20 @@ const (

// OvirtPlatformType represents oVirt/RHV infrastructure.
OvirtPlatformType PlatformType = "oVirt"

// IBMCloudPlatformType represents IBM Cloud infrastructure.
IBMCloudPlatformType PlatformType = "IBMCloud"
)

// IBMCloudProviderType is a specific supported IBM Cloud provider cluster type
type IBMCloudProviderType string

const (
// Classic means that the IBM Cloud cluster is using classic infrastructure
IBMCloudProviderTypeClassic IBMCloudProviderType = "Classic"

// VPC means that the IBM Cloud cluster is using VPC infrastructure
IBMCloudProviderTypeVPC IBMCloudProviderType = "VPC"
)

// PlatformStatus holds the current status specific to the underlying infrastructure provider
Expand Down Expand Up @@ -255,6 +269,18 @@ type VSpherePlatformStatus struct {
NodeDNSIP string `json:"nodeDNSIP,omitempty"`
}

//IBMCloudPlatformStatus holds the current status of the IBMCloud infrastructure provider.
type IBMCloudPlatformStatus struct {
// Location is where the cluster has been deployed
Location string `json:"location,omitempty"`

// ResourceGroupName is the Resource Group for new IBMCloud resources created for the cluster.
ResourceGroupName string `json:"resourceGroupName,omitempty"`

// ProviderType indicates the type of cluster that was created
ProviderType IBMCloudProviderType `json:"providerType,omitempty"`
}

// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

// InfrastructureList is
Expand Down
16 changes: 16 additions & 0 deletions config/v1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions config/v1/zz_generated.swagger_doc_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,10 @@ spec:
etc. \n If unset, the default is based on infrastructure.config.openshift.io/cluster
.status.platform: \n AWS: LoadBalancerService (with External
scope) Azure: LoadBalancerService (with External scope) GCP:
\ LoadBalancerService (with External scope) Libvirt: HostNetwork
\n Any other platform types (including None) default to HostNetwork.
\n endpointPublishingStrategy cannot be updated."
\ LoadBalancerService (with External scope) IBMCloud: LoadBalancerService
(with External scope) Libvirt: HostNetwork \n Any other platform
types (including None) default to HostNetwork. \n endpointPublishingStrategy
cannot be updated."
type: object
required:
- type
Expand Down
1 change: 1 addition & 0 deletions operator/v1/types_ingress.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ type IngressControllerSpec struct {
// AWS: LoadBalancerService (with External scope)
// Azure: LoadBalancerService (with External scope)
// GCP: LoadBalancerService (with External scope)
// IBMCloud: LoadBalancerService (with External scope)
// Libvirt: HostNetwork
//
// Any other platform types (including None) default to HostNetwork.
Expand Down
2 changes: 1 addition & 1 deletion operator/v1/zz_generated.swagger_doc_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 1edb92e

Please sign in to comment.