FAQ | This is a LIVE service | Changelog

Workaround trivy's service discovery issue with running terraform init before trivy command

As it was found in #131 (closed), trivy never worked properly with modules declared as

module "name" {
  source  = "gitlab.developers.cam.ac.uk/uis/<module_name>/devops"
  version = "~> 1.2.3"
...
}

because it currently doesn't support remote service discovery.

To workaround this we need to run terraform init before running trivy.

We need to decide the best way to do this. We could add trivy to terraform image and modify trivy job. Or we could add some "before job", that will prepare .terraform folder as an artifact.

Edited by Dmitrii Unterov