Files
nomad/website/content/docs/commands/var/init.mdx
Tim Gross 0ac85db680 cli: fix missing -quiet flag for var init (#17526)
The `var init` command was intended to have support for a `-quiet` flag but it
was not documented and never parsed.
2023-06-14 14:52:46 -04:00

37 lines
748 B
Plaintext

---
layout: docs
page_title: 'Commands: var init'
description: |
Generate an example variable specification.
---
# Command: var init
The `var init` creates an example variable specification file that can be used
as a starting point to customize further.
## Usage
```plaintext
nomad var init <filename>
```
When no filename is supplied, a default filename of "spec.nv.hcl" or
"spec.nv.json" will be used depending on the output format.
## Init Options
- `-out` `(enum: hcl | json)`: Format of generated variable
specification. Defaults to `hcl`.
- `-quiet`: Do not print success message.
## Examples
Create an example variable specification:
```shell-session
$ nomad var init
Example variable specification written to spec.nv.hcl
```