Snyk CLI for Infrastructure as Code
With Snyk Infrastructure as Code, you can test your configuration files directly from the CLI. See the following pages for details:
You can also test the following types of files:
Currently, there is no equivalent command to
snyk monitor
for Snyk IaC because the CLI does not send IaC source files back to the platform for periodic testing.For IaC CLI results to appear in the Snyk Web UI, you can use the
snyk iac test --report
command to capture a one-time snapshot. Optionally, run the command on a recurring schedule to regularly test your IaC.Alternatively, you can add an SCM integration and Snyk will monitor and test a given git repository on a recurring basis.
For IaC scans specifically, you must also whitelist the *.snyk.io address, as explained on the page How can we whitelist Snyk IP addresses?​