Skip to content

Add trivy image scanning #413

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 23 commits into from
Aug 14, 2024
Merged

Add trivy image scanning #413

merged 23 commits into from
Aug 14, 2024

Conversation

sjpb
Copy link
Collaborator

@sjpb sjpb commented Jul 18, 2024

  • Scans builds for vulerabilities using Trivy. Fails build if CRITICAL vulns found
  • Refactors builds to only build one image per matrix run, and only run the builds we use.

@sjpb sjpb force-pushed the feat/image-scan branch 2 times, most recently from 1ab7ad1 to 6c419ba Compare July 18, 2024 13:07
@sjpb sjpb closed this Jul 18, 2024
@sjpb sjpb reopened this Jul 18, 2024
@sjpb sjpb force-pushed the feat/image-scan branch from 717cf21 to 0689d8f Compare July 18, 2024 15:14
@sjpb sjpb force-pushed the feat/image-scan branch from 0689d8f to c1c5aa5 Compare July 18, 2024 16:09
@sjpb sjpb force-pushed the feat/image-scan branch from c1c5aa5 to 0a44b23 Compare July 18, 2024 16:20
@github-advanced-security
Copy link

This pull request sets up GitHub code scanning for this repository. Once the scans have completed and the checks have passed, the analysis results for this pull request branch will appear on this overview. Once you merge this pull request, the 'Security' tab will show more code scanning analysis results (for example, for the default branch). Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results. For more information about GitHub code scanning, check out the documentation.

sjpb and others added 11 commits August 9, 2024 15:14
* use run_number as a shorter ID for CI

* slurmci group name warning

* Revert "slurmci group name warning"  - underscores not valid linux hostname and stripped in host, leading to slurmdbd config failure

This reverts commit 61dfad6.

---------

Co-authored-by: Bertie <[email protected]>
* Add ansible-init role to requirements.yml

* Add ansible-init to groups and plays

* Configure cluster_infra ansible-init metadata

* Only run site.yml once ansible-init has completed

* Wait for ansible init to finish before running bootstrap

* revert to using cluster_infra metadata defaults

* update image

* revert sausage bastion changes

* set ansible_init_wait as common var

* use run_number as a shorter ID for CI

* install ood apps in fatimage

* add ood jupyter install to fatimage

* bump image

* jupyter_compute ood into fatimage

* bump fatimage for jupyter_compute ood

* Update stackhpc.yml

* duplicate tuned inventory group name

* Fix invalid group name for slurmci

* Update stackhpc.yml

undo groupname changes

* slurmci group name warning

* rm ood changes

* bump fatimage

* change azimuth collection in bootstrap

* update azimuth image utils version

* update requirements

* Update bastion.yml

* Use azimuth image utils collection for ansible-init

* bump fatimage

---------

Co-authored-by: bertie <[email protected]>
Co-authored-by: bertiethorpe <[email protected]>
* Turn off higher priority MPI net devices

* Update pingmatrix.sh.j2

* Update pingmatrix.sh.j2

* Update pingpong.sh.j2

* Replace j2 comments with bash

* Update pingpong.sh.j2

---------

Co-authored-by: Steve Brasier <[email protected]>
@bertiethorpe
Copy link
Member

@bertiethorpe
Copy link
Member

@bertiethorpe bertiethorpe marked this pull request as ready for review August 13, 2024 14:51
@bertiethorpe bertiethorpe requested a review from a team as a code owner August 13, 2024 14:51
Copy link
Collaborator Author

@sjpb sjpb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM other than a task name / comments change please.

bertiethorpe
bertiethorpe previously approved these changes Aug 14, 2024
@sjpb sjpb merged commit 412dc53 into main Aug 14, 2024
1 check passed
@sjpb sjpb deleted the feat/image-scan branch August 14, 2024 13:49
MaxBed4d pushed a commit that referenced this pull request Oct 15, 2024
* add trivy image scanning

* bump fatimage workflow to ubuntu 22.04

* make setup script work in CI TODO: FIXME

* fix libguestfs install

* run only 1x build per matrix entry, & only builds required

* fix packer README

* fix image download

* Use shorter names for CI clusters (#415)

* use run_number as a shorter ID for CI

* slurmci group name warning

* Revert "slurmci group name warning"  - underscores not valid linux hostname and stripped in host, leading to slurmdbd config failure

This reverts commit 61dfad6.

---------

Co-authored-by: Bertie <[email protected]>

* install ood apps in fatimage

* add ood jupyter install to fatimage

* jupyter_compute ood into fatimage

* bump fatimage

* allow items in compute mapping to have different keys e.g. only specify image_id for some compute groups (#412)

* Support ansible-init for remote collections (#411)

* Add ansible-init role to requirements.yml

* Add ansible-init to groups and plays

* Configure cluster_infra ansible-init metadata

* Only run site.yml once ansible-init has completed

* Wait for ansible init to finish before running bootstrap

* revert to using cluster_infra metadata defaults

* update image

* revert sausage bastion changes

* set ansible_init_wait as common var

* use run_number as a shorter ID for CI

* install ood apps in fatimage

* add ood jupyter install to fatimage

* bump image

* jupyter_compute ood into fatimage

* bump fatimage for jupyter_compute ood

* Update stackhpc.yml

* duplicate tuned inventory group name

* Fix invalid group name for slurmci

* Update stackhpc.yml

undo groupname changes

* slurmci group name warning

* rm ood changes

* bump fatimage

* change azimuth collection in bootstrap

* update azimuth image utils version

* update requirements

* Update bastion.yml

* Use azimuth image utils collection for ansible-init

* bump fatimage

---------

Co-authored-by: bertie <[email protected]>
Co-authored-by: bertiethorpe <[email protected]>

* avoid python-openstackclient v7 due to rebuild bug (#420)

* Update hpctests to obey UCX_NET_DEVICES when RoCE devices present (#421)

* Turn off higher priority MPI net devices

* Update pingmatrix.sh.j2

* Update pingmatrix.sh.j2

* Update pingpong.sh.j2

* Replace j2 comments with bash

* Update pingpong.sh.j2

---------

Co-authored-by: Steve Brasier <[email protected]>

* delete trivy scanned vulnerabilities

* update grafana

* bump image

* Update environments/.stackhpc/hooks/post.yml

Co-authored-by: Steve Brasier <[email protected]>

* Update setup-env.sh

---------

Co-authored-by: Bertie <[email protected]>
Co-authored-by: bertiethorpe <[email protected]>
Co-authored-by: bertiethorpe <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants