Hoolit.Templates.IamTemplateSuite 1.1.2

dotnet new install Hoolit.Templates.IamTemplateSuite::1.1.2
                    
This package contains a .NET Template Package you can call from the shell/command line.

IAM Template Suite

The IAM Template Suite provides a collection of integrated templates designed to streamline the provisioning of IAM infrastructure.

📘 To provision the full IAM infrastructure using the suite, follow the instructions in GUIDE.md.


📥 Installation

To install the template suite globally on your machine:

dotnet new install <package-name>

To view the installed templates:

dotnet new --list

🚀️ Usage

After installation, create a new project using one of the templates:

dotnet new <shortName> [options]
  • Replace <shortName> with the template's short name (see dotnet new --list).
  • Include any parameters defined by the template.
    • Optionally use --dry-run to preview the output without creating files.

This will generate a new project directory based on the selected template's structure.


🤝 Contributing

Interested in improving or adding new templates? Follow these steps:

1. Create a New Template

cd Templates
mkdir <NewTemplateName>
cd <NewTemplateName>

Set up your project inside this directory as usual, including all files, folders, and configuration you want included in the template.

2. Configure Template Metadata

Inside your template root, create a .template.config directory with a template.json file:

mkdir .template.config
touch .template.config/template.json

Populate template.json with the required metadata. Refer to other templates in the suite for guidance.

3. Test Your Template

Install the template locally to test:

dotnet new install .

Generate a new project to validate it:

dotnet new <your-short-name>

📦 Dependencies (NuGet Packages)

The templates depend on each other via NuGet packages. You can set up the required development environment using the provided scripts:

  • Setup: LocalDev/SetupLocalEnv.sh
    • Creates a local NuGet feed
    • Packs and publishes specified packages into the feed
  • Teardown: LocalDev/DestroyLocalEnv.sh
    • Destroys everything created by the Setup script

➕ Adding New NuGet Packages

1. Add a Symbol in template.json
"DefaultFalse": {
  "type": "parameter",
  "datatype": "bool",
  "defaultValue": "false",
  "description": "Include template development configuration"
}
2. Configure .csproj for Local Packaging

In each NuGet package project:


<PropertyGroup>
  <PackageOutputPath>../path/to/LocalDev/LocalNuGetFeed</PackageOutputPath>
</PropertyGroup>

Build and deploy to the local feed:

dotnet build

Finally add the package to the PROJECTS list in LocalDev/SetupLocalEnv.sh.

📥 Consuming NuGet Packages

In consuming projects, add a package reference in your .csproj:

<ItemGroup>
  <PackageReference Include="TOrgName.T*RepositoryName.Core" Version="*-*" />
</ItemGroup>

Then, configure nuget.config (ensure the filename is lowercase):

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <packageSources>
    <add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
    
    <add key="LocalNuGetFeed" value="../../../LocalDev/LocalNuGetFeed" />
    
    <add key="TOrgPackageSourceKey" value="TOrgPackageSourceValue" />
    
  </packageSources>
  <packageSourceMapping>
    <packageSource key="nuget.org">
      <package pattern="*" />
    </packageSource>
    
    <packageSource key="LocalNuGetFeed">
      <package pattern="TOrgName.*" />
    </packageSource>
    
    <packageSource key="TOrgPackageSourceKey">
      <package pattern="TOrgName.*" />
    </packageSource>
    
  </packageSourceMapping>
  
  <disabledPackageSources>
    <add key="TOrgPackageSourceKey" value="true" />
  </disabledPackageSources>
  
</configuration>
  • net9.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.1.2 271 3/23/2025
1.1.1 258 3/23/2025