Azure Proactive Resiliency Library v2
Tools Glossary GitHub GitHub Issues Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

Create Content from Templates

This section provides information about creating new content from Hugo archetypes/templates. The following scenarios are covered:

Create a New Azure Resource Provider Namespace

  1. Ensure you are in the root directory of the repository within your terminal.

  2. Run the following hugo command within your terminal.

    hugo new --kind azure-provider-namespace  'azure-resources/Storage'
    

Replace Storage with the name of the Azure provider namespace you want to create. Ensure that the name aligns to the available resource providers found in the documentation here.

Also, ensure that it is formatted with no spaces and is using pascal case. For example, MachineLearningServices or VirtualMachineImages.

  1. You should see similar output within your terminal as shown below:

    Content dir "C:\\Repos\\Reliability\\Azure-Proactive-Resiliency-Library-v2\\azure-resources\\Storage" created
    

Create a New Azure Resource Type within an Existing Provider Namespace

  1. Ensure you are in the root directory of the repository within your terminal

  2. Run the following hugo command within your terminal

    hugo new --kind azure-resource-type 'azure-resources/Storage/locations'
    

Replace storageAccounts with the name of the Azure resource type you want to create. Ensure that the name aligns to the available resource types found in the documentation here. At this time, we are only allowing the creation of resource types one level deep, so you cannot create a resource type that is nested within another resource type such as Storage/storageAccounts/blobServices.

Also, ensure that it is formatted with no spaces and is using camel casing. For example, automationAccounts or databaseAccounts.

  1. You should see similar output within your terminal as shown below:
Content dir "C:\\Repos\\Reliability\\Azure-Proactive-Resiliency-Library-v2\\azure-resources\\Storage\\locations" created
  1. You should now see a new directory created within the azure-resources/Storage directory, named after the Azure resource type you specified and containing the relevant folders and files to build out the resource type. You can also verify the creation by inspecting the resource type within your local Hugo site, which should have been rebuilt automatically with the change.

Create a New Azure Specialized Workload

  1. Ensure you are in the root directory of the repository within your terminal

  2. Run the following hugo command within your terminal

    hugo new --kind azure-specialized-workload 'azure-specialized-workloads/oracle'
    

Replace oracle with the name of the specialized workload you want to create.

Also, ensure that it is formatted with no spaces and is using camel case. For example, hpcOnAzure.

  1. You should see similar output within your terminal as shown below:

    Content dir "C:\\Repos\\Reliability\\Azure-Proactive-Resiliency-Library-v2\\azure-specialized-workloads\\oracle" created
    
  2. You should now see a new directory created within the azure-specialized directory, named after the Azure specialized workload you specified. You can verify the creation by inspecting the directory in your local Hugo site, which should have been rebuilt automatically with the change.

Create a New WAF Reliability Stage

  1. Ensure you are in the root directory of the repository within your terminal

  2. Run the following hugo command within your terminal:

    hugo new --kind azure-waf 'azure-waf/develop'
    
Replace develop with the name of the WAF reliability stage you want to create.
  1. You should see similar output within your terminal as shown below:

    Content dir "C:\\Repos\\Reliability\\Azure-Proactive-Resiliency-Library-v2\\azure-waf\\develop" created