Commit 84d6b61d authored by Clement Bois's avatar Clement Bois
Browse files

Merge branch 'fix/trivy-cache' into 'master'

fix: add cache for trivy

Closes docker#132

See merge request to-be-continuous/terraform!155
parents d3eac726 3bc9b313
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1190,6 +1190,8 @@ tf-trivy:
    entrypoint: [""]
  stage: test
  needs: []
  variables:
    TRIVY_CACHE_DIR: ".trivycache/"
  script:
    - mkdir -p -m 777 reports
    - exit_code=0
@@ -1210,6 +1212,10 @@ tf-trivy:
    paths:
      - "$TF_PROJECT_DIR/reports/tf-trivy.*"
  dependencies: []
  cache:
    - key: "$CI_COMMIT_REF_SLUG-trivy"
      paths:
        - .trivycache/
  rules:
    - if: '$TF_TRIVY_DISABLED == "true"'
      when: never