Add: documentation tools

This commit is contained in:
jez 2022-03-21 23:56:53 -04:00
parent 335757bf44
commit 2d776ef954
2 changed files with 59 additions and 0 deletions

48
.terraform-docs.yml Normal file
View File

@ -0,0 +1,48 @@
formatter: "" # this is required
version: ""
header-from: main.tf
footer-from: ""
recursive:
enabled: true
path: .
sections:
hide: []
show: []
content: ""
output:
file: ""
mode: inject
template: |-
<!-- BEGIN_TF_DOCS -->
{{ .Content }}
<!-- END_TF_DOCS -->
output-values:
enabled: false
from: ""
sort:
enabled: true
by: name
settings:
anchor: true
color: true
default: true
description: true
escape: true
hide-empty: false
html: true
indent: 2
lockfile: true
read-comments: true
required: true
sensitive: true
type: true

11
build_docs.sh Executable file
View File

@ -0,0 +1,11 @@
#!/bin/bash
for i in $(ls -1 | grep -E "virt_|cloud_"); do
echo terraform-docs markdown "$i > $i/README.md"
terraform-docs markdown "$i" > "$i/README.md"
done