Skip to main content
Version: 1.1.2

Subnet

PropertyValue
KindSubnet
API Group/Versionarubacloud.com/v1alpha1
CRD Namesubnets.arubacloud.com
ScopeNamespaced
Short Namessn, arusn

Description

A Subnet defines a network segment within a VPC. CloudServers attach to one or more Subnets to receive network connectivity. Each Subnet belongs to exactly one VPC and one Project. Subnets support DHCP configuration and can be of type Advanced (full-featured, with DHCP support) or Basic.

Spec Fields

FieldTypeRequiredDefaultValidationDescription
tenantstringNoAruba Cloud tenant identifier. Must match the owning VPC's tenant.
regionstringYesITBG-BergamoAruba Cloud region. Must match the parent VPC's region.
typestringYesEnum: Advanced, BasicSubnet type. Advanced supports DHCP; Basic is a simpler variant.
cidrstringYesIPv4 CIDR pattern (e.g., 10.0.1.0/24)The IP address range for this subnet
dhcp.enabledboolYesWhether DHCP is enabled for this subnet
tags[]stringNoLabels propagated to the Aruba Cloud resource
vpcReferenceResourceReferenceYesReference to the owning VPC
projectReferenceResourceReferenceYesReference to the owning Project

Status Fields

FieldTypeDescription
phasestringCurrent lifecycle phase
resourceIDstringAruba Cloud Subnet ID, set after creation
messagestringHuman-readable status message
observedGenerationint64Last .metadata.generation processed
phaseStartTimetimestampWhen the current phase began
conditions[]ConditionStandard Kubernetes conditions
projectIDstringResolved Aruba Cloud project ID
vpcIDstringResolved Aruba Cloud VPC ID

References

Owned by: VPC (and Project)

Referenced by:

  • CloudServer — via spec.subnetReferences (one or more Subnets can be attached)

Lifecycle

  • Creation ordering: Both the VPC and Project must be Active before the Subnet can be created.
  • Deletion behaviour: Subnets have no children. Deletion proceeds directly: the operator calls the Aruba Cloud API to delete the subnet, then removes the finalizer.
  • Update behaviour: tags can be updated. cidr, type, dhcp.enabled, and the parent references are effectively immutable (changing a subnet's CIDR requires recreating it).
  • Tenant and region validation: The operator validates that spec.tenant and spec.region match the parent VPC. Mismatches cause Failed+IntentionValidationFailed.

Example

apiVersion: arubacloud.com/v1alpha1
kind: Subnet
metadata:
name: web-subnet
namespace: default
spec:
tenant: ARU-123456
region: ITBG-Bergamo
type: Advanced
cidr: "10.0.1.0/24"
dhcp:
enabled: true
vpcReference:
name: web-vpc
namespace: default
projectReference:
name: my-project
namespace: default
tags:
- production

kubectl Quick Reference

# List all subnets
kubectl get sn -n default

# Describe a subnet
kubectl describe arusn web-subnet -n default