Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Add_workflow_for_techpubs
AUTH1UserResourceIdentifier{userKey=8a00a02355cd1c2f0155cd26cb8305e9, userName='null'}
JIRAIDAUTHSBX-117834
REV5UserResourceIdentifier{userKey=8a00a02355cd1c2f0155cd26cb8305e9, userName='null'}
REV6UserResourceIdentifier{userKey=8a00a02355cd1c2f0155cd26cb8305e9, userName='null'}
REV3UserResourceIdentifier{userKey=8a00a0c87b4755e3017b4ba436730001, userName='null'}
REV1UserResourceIdentifier{userKey=8a00a02355cd1c2f0155cd26ccf9091c, userName='null'}

Table of Contents
maxLevel3

The following steps describe the procedures to Instantiate the Azure Standalone SBC or the HA SBC with HFE using IAC. The Azure CLI version used for this document is 2.24.

  1. Access and Share SBC Image in Azure.
  2. Retrieve the latest IAC tarball from the Ribbon Support Portal.
  3. Create an Ubuntu 18.04 LTS instance in Azure.
  4. Run az login and sign in as a user with the role 'owner' for the subscription.
  5. If you haven't created one already, create a Service Principal that contains 'owner' permissions for the subscription.

    Example:

    Code Block
    az ad sp create-for-rbac -n rbbn-iac --role="owner" --scopes="/subscriptions/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXa511"


    Info
    • Ensure the Service Principle created as 'owner' has sufficient privileges to create and assign roles.
    • Store the outputs "appId" and "password" from the commands to use as credentials for login in as the Service Principal.
    • Verify the output includes credentials that you must protect.


  6. Copy the IAC tarball to the Azure instance.

    Code Block
    scp -i <pem_file> <iac_tarball> <username>@<ip_azure_instance>:/home/<username>


  7. Make a directory to extract the IAC tarball:

    Code Block
    mkdir iac_package


  8. Copy the IAC tarball to the created directory created above and change it to that directory:

    Code Block
    cp iac_sustaining_*.tar.gz  iac_package/
    cd iac_package


  9. Extract the IAC tarball using tar.

    Code Block
    tar xvfz iac_sustaining_*.tar.gz


  10. To set up the IAC environment, follow the instructions available in ./iac_package/README.md

  11. Follow the Azure instructions in ./iac_package/help/REAMDE.azure.md file to create either:
    • Standalone SBC
      • To setup Standalone,  follow the instructions in ./iac_package/orchestration/azure/sbc_stand_alone/README.md
    • HA SBC with HFE
      • To setup SBC HA with HFE 2.1, follow the instructions in ./iac_package/orchestration/azure/sbc_hfe2.1/README.md
      • Create a HFE Storage Account to store the HFE_AZ.sh script 
  12. For either Standalone or HA with HFE, update the "terraform.tfvars" to provide inputs for deployment. Update the following:
    1. resource_group_names
    2. resource_group_locations
    3. hfe_script_url
    4. remote_ssh_ip
    5. address_prefix_pkt0Src
    6. address_prefix_pkt1Src
    7. image_name Microsoft.Compute/images/rbbn-sbc-v10.01.11.img

      Code Block
      image_name = "/subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxa31/resourceGroups/mage_RBBN-SBC-RG/providers/Microsoft.Compute/images/rbbn-sbc-v10.01.11.img


  13. Export the following environment variables, stored from the Service Principal creation:

    Code Block
    export ARM_SUBSCRIPTION_ID="<subscription_id>"
    export ARM_TENANT_ID="<tenant_id>"
    export ARM_CLIENT_ID="<appId>"
    export ARM_CLIENT_SECRET="<password>"


  14. Use the Terraform commands mentioned below:
    1. Initialize Terraform:

      Code Block
      terraform init


    2. Run Terraform plan command, to preview the changes and ensure that "terraform.tfvars" are configured correctly before applying:

      Code Block
      terraform plan


    3. Apply the resource configuration:

      Code Block
      terraform apply


      Info

      Ensure to create resources according to deployment needs.


      Info

      For Standalone SBC, make a note of the following field:

      • SBC public IP: sbc_public_ip


      Info

      For the HA SBC with HFE setup, make a note of the following fields:

      • Active SBC public IP: active_sbc_public_ip
      • Standby SBC public IP: standby_sbc_public_ip


  15. To destroy all SBC resources from Microsoft Azure:

    Code Block
    terraform destroy