diff --git a/end-to-end-tests/src/bin/bootstrap.rs b/end-to-end-tests/src/bin/bootstrap.rs index b02bed4265..4c41d30bdc 100644 --- a/end-to-end-tests/src/bin/bootstrap.rs +++ b/end-to-end-tests/src/bin/bootstrap.rs @@ -8,8 +8,8 @@ use oxide_client::types::{ NameOrId, SiloQuotasUpdate, }; use oxide_client::{ - ClientDisksExt, ClientHiddenExt, ClientProjectsExt, - ClientSystemNetworkingExt, ClientSystemSilosExt, + ClientDisksExt, ClientHiddenExt, ClientProjectsExt, ClientSystemIpPoolsExt, + ClientSystemSilosExt, }; use serde::{de::DeserializeOwned, Deserialize}; use std::time::Duration; diff --git a/end-to-end-tests/src/bin/commtest.rs b/end-to-end-tests/src/bin/commtest.rs index 05e15faafc..5711a52179 100644 --- a/end-to-end-tests/src/bin/commtest.rs +++ b/end-to-end-tests/src/bin/commtest.rs @@ -9,7 +9,7 @@ use oxide_client::{ UsernamePasswordCredentials, }, ClientHiddenExt, ClientLoginExt, ClientProjectsExt, - ClientSystemHardwareExt, ClientSystemNetworkingExt, ClientSystemStatusExt, + ClientSystemHardwareExt, ClientSystemIpPoolsExt, ClientSystemStatusExt, ClientVpcsExt, }; use std::{ diff --git a/nexus/external-api/output/nexus_tags.txt b/nexus/external-api/output/nexus_tags.txt index bde11e2de3..3024eb8ac4 100644 --- a/nexus/external-api/output/nexus_tags.txt +++ b/nexus/external-api/output/nexus_tags.txt @@ -146,11 +146,7 @@ sled_view GET /v1/system/hardware/sleds/{sle switch_list GET /v1/system/hardware/switches switch_view GET /v1/system/hardware/switches/{switch_id} -API operations found with tag "system/metrics" -OPERATION ID METHOD URL PATH -system_metric GET /v1/system/metrics/{metric_name} - -API operations found with tag "system/networking" +API operations found with tag "system/ip-pools" OPERATION ID METHOD URL PATH ip_pool_create POST /v1/system/ip-pools ip_pool_delete DELETE /v1/system/ip-pools/{pool} @@ -169,6 +165,13 @@ ip_pool_silo_update PUT /v1/system/ip-pools/{pool}/sil ip_pool_update PUT /v1/system/ip-pools/{pool} ip_pool_utilization_view GET /v1/system/ip-pools/{pool}/utilization ip_pool_view GET /v1/system/ip-pools/{pool} + +API operations found with tag "system/metrics" +OPERATION ID METHOD URL PATH +system_metric GET /v1/system/metrics/{metric_name} + +API operations found with tag "system/networking" +OPERATION ID METHOD URL PATH networking_address_lot_block_list GET /v1/system/networking/address-lot/{address_lot}/blocks networking_address_lot_create POST /v1/system/networking/address-lot networking_address_lot_delete DELETE /v1/system/networking/address-lot/{address_lot} diff --git a/nexus/external-api/src/lib.rs b/nexus/external-api/src/lib.rs index 669b25145f..2c8ec38c7e 100644 --- a/nexus/external-api/src/lib.rs +++ b/nexus/external-api/src/lib.rs @@ -175,6 +175,12 @@ pub const API_VERSION: &str = "20240821.0"; url = "http://docs.oxide.computer/api/system-metrics" } }, + "system/ip-pools" = { + description = "IP pools are collections of external IPs that can be assigned to silos. When a pool is linked to a silo, users in that silo can allocate IPs from the pool for their instances.", + external_docs = { + url = "http://docs.oxide.computer/api/system-ip-pools" + } + }, "system/networking" = { description = "This provides rack-level network configuration.", external_docs = { @@ -630,7 +636,7 @@ pub trait NexusExternalApi { #[endpoint { method = GET, path = "/v1/system/ip-pools", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_list( rqctx: RequestContext, @@ -641,7 +647,7 @@ pub trait NexusExternalApi { #[endpoint { method = POST, path = "/v1/system/ip-pools", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_create( rqctx: RequestContext, @@ -652,7 +658,7 @@ pub trait NexusExternalApi { #[endpoint { method = GET, path = "/v1/system/ip-pools/{pool}", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_view( rqctx: RequestContext, @@ -663,7 +669,7 @@ pub trait NexusExternalApi { #[endpoint { method = DELETE, path = "/v1/system/ip-pools/{pool}", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_delete( rqctx: RequestContext, @@ -674,7 +680,7 @@ pub trait NexusExternalApi { #[endpoint { method = PUT, path = "/v1/system/ip-pools/{pool}", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_update( rqctx: RequestContext, @@ -686,7 +692,7 @@ pub trait NexusExternalApi { #[endpoint { method = GET, path = "/v1/system/ip-pools/{pool}/utilization", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_utilization_view( rqctx: RequestContext, @@ -697,7 +703,7 @@ pub trait NexusExternalApi { #[endpoint { method = GET, path = "/v1/system/ip-pools/{pool}/silos", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_silo_list( rqctx: RequestContext, @@ -723,7 +729,7 @@ pub trait NexusExternalApi { #[endpoint { method = POST, path = "/v1/system/ip-pools/{pool}/silos", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_silo_link( rqctx: RequestContext, @@ -737,7 +743,7 @@ pub trait NexusExternalApi { #[endpoint { method = DELETE, path = "/v1/system/ip-pools/{pool}/silos/{silo}", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_silo_unlink( rqctx: RequestContext, @@ -754,7 +760,7 @@ pub trait NexusExternalApi { #[endpoint { method = PUT, path = "/v1/system/ip-pools/{pool}/silos/{silo}", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_silo_update( rqctx: RequestContext, @@ -766,7 +772,7 @@ pub trait NexusExternalApi { #[endpoint { method = GET, path = "/v1/system/ip-pools-service", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_service_view( rqctx: RequestContext, @@ -778,7 +784,7 @@ pub trait NexusExternalApi { #[endpoint { method = GET, path = "/v1/system/ip-pools/{pool}/ranges", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_range_list( rqctx: RequestContext, @@ -792,7 +798,7 @@ pub trait NexusExternalApi { #[endpoint { method = POST, path = "/v1/system/ip-pools/{pool}/ranges/add", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_range_add( rqctx: RequestContext, @@ -804,7 +810,7 @@ pub trait NexusExternalApi { #[endpoint { method = POST, path = "/v1/system/ip-pools/{pool}/ranges/remove", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_range_remove( rqctx: RequestContext, @@ -818,7 +824,7 @@ pub trait NexusExternalApi { #[endpoint { method = GET, path = "/v1/system/ip-pools-service/ranges", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_service_range_list( rqctx: RequestContext, @@ -831,7 +837,7 @@ pub trait NexusExternalApi { #[endpoint { method = POST, path = "/v1/system/ip-pools-service/ranges/add", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_service_range_add( rqctx: RequestContext, @@ -842,7 +848,7 @@ pub trait NexusExternalApi { #[endpoint { method = POST, path = "/v1/system/ip-pools-service/ranges/remove", - tags = ["system/networking"], + tags = ["system/ip-pools"], }] async fn ip_pool_service_range_remove( rqctx: RequestContext, diff --git a/openapi/nexus.json b/openapi/nexus.json index a855378cd4..ac437b7c97 100644 --- a/openapi/nexus.json +++ b/openapi/nexus.json @@ -5210,7 +5210,7 @@ "/v1/system/ip-pools": { "get": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "List IP pools", "operationId": "ip_pool_list", @@ -5267,7 +5267,7 @@ }, "post": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Create IP pool", "operationId": "ip_pool_create", @@ -5304,7 +5304,7 @@ "/v1/system/ip-pools/{pool}": { "get": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Fetch IP pool", "operationId": "ip_pool_view", @@ -5340,7 +5340,7 @@ }, "put": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Update IP pool", "operationId": "ip_pool_update", @@ -5386,7 +5386,7 @@ }, "delete": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Delete IP pool", "operationId": "ip_pool_delete", @@ -5417,7 +5417,7 @@ "/v1/system/ip-pools/{pool}/ranges": { "get": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "List ranges for IP pool", "description": "Ranges are ordered by their first address.", @@ -5479,7 +5479,7 @@ "/v1/system/ip-pools/{pool}/ranges/add": { "post": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Add range to IP pool", "description": "IPv6 ranges are not allowed yet.", @@ -5528,7 +5528,7 @@ "/v1/system/ip-pools/{pool}/ranges/remove": { "post": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Remove range from IP pool", "operationId": "ip_pool_range_remove", @@ -5569,7 +5569,7 @@ "/v1/system/ip-pools/{pool}/silos": { "get": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "List IP pool's linked silos", "operationId": "ip_pool_silo_list", @@ -5635,7 +5635,7 @@ }, "post": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Link IP pool to silo", "description": "Users in linked silos can allocate external IPs from this pool for their instances. A silo can have at most one default pool. IPs are allocated from the default pool when users ask for one without specifying a pool.", @@ -5684,7 +5684,7 @@ "/v1/system/ip-pools/{pool}/silos/{silo}": { "put": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Make IP pool default for silo", "description": "When a user asks for an IP (e.g., at instance create time) without specifying a pool, the IP comes from the default pool if a default is configured. When a pool is made the default for a silo, any existing default will remain linked to the silo, but will no longer be the default.", @@ -5738,7 +5738,7 @@ }, "delete": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Unlink IP pool from silo", "description": "Will fail if there are any outstanding IPs allocated in the silo.", @@ -5777,7 +5777,7 @@ "/v1/system/ip-pools/{pool}/utilization": { "get": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Fetch IP pool utilization", "operationId": "ip_pool_utilization_view", @@ -5815,7 +5815,7 @@ "/v1/system/ip-pools-service": { "get": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Fetch Oxide service IP pool", "operationId": "ip_pool_service_view", @@ -5842,7 +5842,7 @@ "/v1/system/ip-pools-service/ranges": { "get": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "List IP ranges for the Oxide service pool", "description": "Ranges are ordered by their first address.", @@ -5895,7 +5895,7 @@ "/v1/system/ip-pools-service/ranges/add": { "post": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Add IP range to Oxide service pool", "description": "IPv6 ranges are not allowed yet.", @@ -5933,7 +5933,7 @@ "/v1/system/ip-pools-service/ranges/remove": { "post": { "tags": [ - "system/networking" + "system/ip-pools" ], "summary": "Remove IP range from Oxide service pool", "operationId": "ip_pool_service_range_remove", @@ -21464,6 +21464,13 @@ "url": "http://docs.oxide.computer/api/system-hardware" } }, + { + "name": "system/ip-pools", + "description": "IP pools are collections of external IPs that can be assigned to silos. When a pool is linked to a silo, users in that silo can allocate IPs from the pool for their instances.", + "externalDocs": { + "url": "http://docs.oxide.computer/api/system-ip-pools" + } + }, { "name": "system/metrics", "description": "Metrics provide insight into the operation of the Oxide deployment. These include telemetry on hardware and software components that can be used to understand the current state as well as to diagnose issues.",