Skip to content

aarondandy/armpit

Repository files navigation

Armpit

Manage Azure cloud resources imperatively using TypeScript.

  • Write automation scripts in TypeScript, a DSL designed for working with JSON data.
  • Leverage the Azure CLI with simple result serialization and easy argument passing via Execa.
  • Can be used along with the Azure SDK too and with some specialized helpers!
  • Run steps asynchronously for improved performance in more complex scripts.
  • A powerful language for complex scenarios requiring branching or iteration.

Examples

A simple script to define a storage account:

import type { SkuName, StorageAccount } from "@azure/arm-storage";
import az from "armpit";

const sku: SkuName = "Standard_LRS";
const name = "garbagefile";

await az.account.ensureActiveAccount();
const rg = await az.group("samples", "centralus");
const sa = await rg<StorageAccount>`storage account create -n ${name} --sku ${sku} --kind StorageV2`;
console.log(`Storage account ready: ${sa.name}`);

More samples can be found in the samples workspace.

About

Adequate resource management programming infrastructure toolkit

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •