Deploy Charmed OAI RAN

This guide explains how to deploy the Charmed OAI RAN CU and DU applications using Terraform.

1. Create a Terraform module for the Radio Access Network

Create a Terraform module for the Radio Access Network and add Charmed OAI RAN CU and Charmed OAI RAN DU to it. Then, replace the placeholders in the DU configuration with the actual values to meet your requirements. Please check the DU Configuration to see the supported ranges.

cat << EOF > ran.tf
resource "juju_model" "oai-ran" {
  name = "ran"
}

module "cu" {
  source = "git::https://github.com/canonical/oai-ran-cu-k8s-operator//terraform"

  model      = juju_model.oai-ran.name
  config     = {
    "n3-interface-name": "ran"
  }
}

module "du" {
  source = "git::https://github.com/canonical/oai-ran-du-k8s-operator//terraform"

  model      = juju_model.oai-ran.name
  config     = {
    "simulation-mode": false,
    "use-three-quarter-sampling": true,
    "bandwidth": <your bandwidth in MHz>,
    "frequency-band": <your frequency band>,
    "sub-carrier-spacing": <your sub carrierspacing in kHz>,
    "center-frequency": "<your center frequency in MHz>",
  }
}

resource "juju_integration" "cu-amf" {
  model = juju_model.oai-ran.name
  application {
    name     = module.cu.app_name
    endpoint = module.cu.fiveg_n2_endpoint
  }
  application {
    offer_url = module.sdcore.amf_fiveg_n2_offer_url  // Offer URL from the AMF charm
  }
}

resource "juju_integration" "cu-nms" {
  model = juju_model.oai-ran.name
  application {
    name     = module.cu.app_name
    endpoint = module.cu.fiveg_core_gnb_endpoint
  }
  application {
    offer_url = module.sdcore.nms_fiveg_core_gnb_offer_url    // Offer URL from the NMS charm
  }
}

resource "juju_integration" "du-cu" {
  model = juju_model.oai-ran.name
  application {
    name     = module.du.app_name
    endpoint = module.du.fiveg_f1_endpoint
  }
  application {
    name     = module.cu.app_name
    endpoint = module.cu.fiveg_f1_endpoint
  }
}

EOF

Note

The instruction above assumes that the OAI RAN will be integrated to Charmed Aether SD-Core. If you use a different 5G core network, you will need to change the AMF and NMS offer URLs.

2. Update Juju Terraform provider

terraform init

3. Deploy Charmed OAI RAN

terraform apply -auto-approve

4. Monitor the status of the deployment

juju switch ran
juju status --watch 1s --relations

At this stage both the cu and the du applications are expected to be in the waiting/idle state and the messages should indicate they’re waiting for network configuration. The charms will go to active/idle state once network configuration information necessary to start the workloads is provided to the charms through the fiveg_core_gnb (between the Core and the CU) and fiveg_f1 (between the CU and DU) Juju integrations. This information is automatically exchanged when the charms are integrated with Charmed Aether SD-Core.