Skip to content

Commit

Permalink
add cluster-api provider for gcp schemas (#135)
Browse files Browse the repository at this point in the history
  • Loading branch information
itspngu authored Mar 21, 2023
1 parent 25026dd commit 2b90d83
Show file tree
Hide file tree
Showing 17 changed files with 3,235 additions and 0 deletions.
187 changes: 187 additions & 0 deletions infrastructure.cluster.x-k8s.io/gcpcluster_v1alpha2.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,187 @@
{
"description": "GCPCluster is the Schema for the gcpclusters API",
"properties": {
"apiVersion": {
"description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources",
"type": "string"
},
"kind": {
"description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds",
"type": "string"
},
"metadata": {
"type": "object"
},
"spec": {
"description": "GCPClusterSpec defines the desired state of GCPCluster",
"properties": {
"additionalLabels": {
"additionalProperties": {
"type": "string"
},
"description": "AdditionalLabels is an optional set of tags to add to GCP resources managed by the GCP provider, in addition to the ones added by default.",
"type": "object"
},
"network": {
"description": "NetworkSpec encapsulates all things related to GCP network.",
"properties": {
"autoCreateSubnetworks": {
"description": "AutoCreateSubnetworks: When set to true, the VPC network is created in \"auto\" mode. When set to false, the VPC network is created in \"custom\" mode. \n An auto mode VPC network starts with one subnet per region. Each subnet has a predetermined range as described in Auto mode VPC network IP ranges. \n Defaults to true.",
"type": "boolean"
},
"loadBalancerBackendPort": {
"description": "Allow for configuration of load balancer backend (useful for changing apiserver port)",
"format": "int32",
"type": "integer"
},
"name": {
"description": "Name is the name of the network to be used.",
"type": "string"
},
"subnets": {
"description": "Subnets configuration.",
"items": {
"description": "SubnetSpec configures an GCP Subnet.",
"properties": {
"cidrBlock": {
"description": "CidrBlock is the range of internal addresses that are owned by this subnetwork. Provide this property when you create the subnetwork. For example, 10.0.0.0/8 or 192.168.0.0/16. Ranges must be unique and non-overlapping within a network. Only IPv4 is supported. This field can be set only at resource creation time.",
"type": "string"
},
"description": {
"description": "Description is an optional description associated with the resource.",
"type": "string"
},
"name": {
"description": "Name defines a unique identifier to reference this resource.",
"type": "string"
},
"privateGoogleAccess": {
"description": "PrivateGoogleAccess defines whether VMs in this subnet can access Google services without assigning external IP addresses",
"type": "boolean"
},
"region": {
"description": "Region is the name of the region where the Subnetwork resides.",
"type": "string"
},
"routeTableId": {
"description": "EnableFlowLogs: Whether to enable flow logging for this subnetwork. If this field is not explicitly set, it will not appear in get listings. If not set the default behavior is to disable flow logging.",
"type": "boolean"
},
"secondaryCidrBlocks": {
"additionalProperties": {
"type": "string"
},
"description": "SecondaryCidrBlocks defines secondary CIDR ranges, from which secondary IP ranges of a VM may be allocated",
"type": "object"
}
},
"type": "object",
"additionalProperties": false
},
"type": "array"
}
},
"type": "object",
"additionalProperties": false
},
"project": {
"description": "Project is the name of the project to deploy the cluster to.",
"type": "string"
},
"region": {
"description": "The GCP Region the cluster lives in.",
"type": "string"
}
},
"required": [
"project",
"region"
],
"type": "object",
"additionalProperties": false
},
"status": {
"description": "GCPClusterStatus defines the observed state of GCPCluster",
"properties": {
"apiEndpoints": {
"description": "APIEndpoints represents the endpoints to communicate with the control plane.",
"items": {
"description": "APIEndpoint represents a reachable Kubernetes API endpoint.",
"properties": {
"host": {
"description": "The hostname on which the API server is serving.",
"type": "string"
},
"port": {
"description": "The port on which the API server is serving.",
"type": "integer"
}
},
"required": [
"host",
"port"
],
"type": "object",
"additionalProperties": false
},
"type": "array"
},
"network": {
"description": "Network encapsulates GCP networking resources.",
"properties": {
"apiServerBackendService": {
"description": "APIServerBackendService is the full reference to the backend service created for the API Server.",
"type": "string"
},
"apiServerForwardingRule": {
"description": "APIServerForwardingRule is the full reference to the forwarding rule created for the API Server.",
"type": "string"
},
"apiServerHealthCheck": {
"description": "APIServerHealthCheck is the full reference to the health check created for the API Server.",
"type": "string"
},
"apiServerInstanceGroups": {
"additionalProperties": {
"type": "string"
},
"description": "APIServerInstanceGroups is a map from zone to the full reference to the instance groups created for the control plane nodes created in the same zone.",
"type": "object"
},
"apiServerIpAddress": {
"description": "APIServerAddress is the IPV4 global address assigned to the load balancer created for the API Server.",
"type": "string"
},
"apiServerTargetProxy": {
"description": "APIServerTargetProxy is the full reference to the target proxy created for the API Server.",
"type": "string"
},
"firewallRules": {
"additionalProperties": {
"type": "string"
},
"description": "FirewallRules is a map from the name of the rule to its full reference.",
"type": "object"
},
"selfLink": {
"description": "SelfLink is the link to the Network used for this cluster.",
"type": "string"
}
},
"type": "object",
"additionalProperties": false
},
"ready": {
"description": "Bastion Instance `json:\"bastion,omitempty\"`",
"type": "boolean"
}
},
"required": [
"ready"
],
"type": "object",
"additionalProperties": false
}
},
"type": "object"
}
Loading

0 comments on commit 2b90d83

Please sign in to comment.