// TestMigrateServiceCIDR validates the steps necessary to migrate a cluster default ServiceCIDR // including the existing kubernetes.default service. // 1. start apiserver with --service-cluster-ip-range 192.168.0.0/29" // 2. create services to use some addresses on the cidr // 3. create a temporary new ServiceCIDR 10.168.0.0/24 to migrate the cluster to it // 4. delete the default service CIDR so the allocators ignore it (it will be pending because of the finalizer and having still IPs) // 5. recreate the services, the allocator should pick the temporary ServiceCIDR // 6. start the new apiserver with the new ServiceCIDRs on the flags and shutdown the old one // 7. delete the kubernetes.default service, the new apiserver will recreate it within the new ServiceCIDR func TestMigrateServiceCIDR(t *testing.T) { … }