IBS Mirror utilities lib
Copyright 2025 SUSE LLC
SPDX-License-Identifier: FSFAP
QE SAP <qe-sap@suse.de>
Package with common methods allowing the SUT to interact with IBSm
Calculate a main range that can be used in Azure for vnet or in AWS for vpc. Also calculate a secondary range within the main one for Azure subnet address ranges. The format is 10.ip2.ip3.0/21 and /24 respectively. ip2 and ip3 are calculated using the slot number as seed.
ibsm_network_peering_azure_create(
ibsm_rg => 'IBSmRg',
sut_rg => 'SUTRg',
name_prefix => 'something');
Create two peering in Azure. Given two resource group names, this function first calculate two peering names. The caller can provide a prefix but name also contain the vnet names from the two resource groups.
ibsm_network_peering_azure_delete(
ibsm_rg => 'IBSmRg',
sut_rg => 'SUTRg',
name_prefix => 'something');
Delete the two network peerings between the two provided deployments. This function is symmetrical to ibsm_network_peering_azure_create.
ibsm_network_peering_gcp_create(
ibsm_ncc_hub => 'projects/ibsm-project/locations/global/hubs/ibsm-hub',
sut_network => 'my-network',
sut_project => 'my-project',
spoke_name => 'my-spoke');
Create a GCP NCC VPC spoke in the SUT project connecting to the IBSm NCC hub. Die if some commands return with error or if the spoke does not turn in ACTIVE state within timeout.
ibsm_network_peering_gcp_delete(spoke_name => 'my-spoke' [, timeout => 600]);
Delete the GCP NCC spoke connecting the SUT to the IBSm hub.
ibsm_network_peering_aws_create(
region => 'us-west-1',
job_id => 'job-123',
ibsm_ip_range => '10.0.0.0/8',
ibsm_prj_tag => 'tag');
Create a network peering on AWS using Transit Gateway.
ibsm_network_peering_aws_delete(region => 'us-west-1', job_id => 'job-123');
Delete AWS TGW attachment for the SUT.