Prototype for representing ARM modules using jsonnet.
- Clone the repository
- Make sure that you have jsonnet installed and on your path
- Run
jsonnet <example file> -J <root of repository>
<root>
+-- core
+-- module.libsonnet # Main module file exposing module
+-- moduledef.libsonnet # Structure of a module
+-- resource.libsonnet # Structure for an individual resource
+-- example_consumers
+-- vmss_cli.jsonnet # Intended to be a module used by the azure cli vmss create command
+-- <other modules>
+-- module.libsonnet
A module is a folder that contains the following files:
modulename
+-- module.libsonnet
+-- parameters.schema.json
+-- <additional libsonnet files>
where modulename is the name of the module.
The structure of a module is a json object with two required properties; resources and outputs.
local core = import 'core/module.libsonnet';
{
resources: {
resource1: core.Module {
},
resource2: core.Module {
}
},
outputs: {
}
}