cisagov / cisagov/pre-commit-packer
Can't go through validate hook with an pkrvars file as input
- Dominant language
- Shell
- Stars
- 21
- Forks
- 16
- PR merge metrics
- No merged PRs in 30d
Description
# 💡 Summary #
It would be great to allow the args to specify the path to the pkrvars file to be used when validating the packer files
## Motivation and context ##
as of today the basic command with packer works :
packer validate -var-file="inputs/dev.pkrvars.hcl" .
However when using the pre-commit hook validate there is no way to map with the righ pkrvars file.
This would be useful because...
## Implementation notes ##
Please provide details for implementation, such as:
an example would be :
repos:
- repo: https://github.com/cisagov/pre-commit-packer
rev: v0.0.2
hooks:
- id: packer_fmt
- id: packer_validate
args:
- '--args=--var-file="inputs/dev.pkrvars.hcl'
## Acceptance criteria ##
How do we know when this work is done?
- [ ] Ability to run validate by providing a pkrvars.hcl file as input
Contributor guide
Assessment
This issue has not been assessed yet.