Skip to content
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

Scanning scripts are not working for 1.9 #1032

Closed
4 tasks done
kimwnasptd opened this issue Aug 22, 2024 · 5 comments
Closed
4 tasks done

Scanning scripts are not working for 1.9 #1032

kimwnasptd opened this issue Aug 22, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@kimwnasptd
Copy link
Contributor

kimwnasptd commented Aug 22, 2024

Bug Description

Right now the action for scanning 1.9 is failing.

Currently the main reason is that an incorrect path is getting used, introduced by #1027. But we observed follow-up issues with the scanning like canonical/knative-operators#219.

The current list of bugs that need to be resolved around the scanning are:

You can see an initially failing scan (because of incorrect path) in
https://github.com/canonical/bundle-kubeflow/actions/runs/10500366253/job/29088636529

To Reproduce

Check the Actions tab

Environment

current state of the repo as of 22 August 2024

Relevant Log Output

> Run BUNDLE="releases/1.9/stable/kubeflow"
Error: open releases/1.9/stable/kubeflow/bundle.yaml: no such file or directory
Error: open releases/1.9/stable/kubeflow/bundle.yaml: no such file or directory
Image list:

...
Traceback (most recent call last):
  File "./kubeflow-ci/scripts/images/get-summary.py", line 148, in <module>
    main(args.report_path, args.print_header)
  File "./kubeflow-ci/scripts/images/get-summary.py", line 79, in main
    file_list = get_reports_files_list(report_path)
  File "./kubeflow-ci/scripts/images/get-summary.py", line 33, in get_reports_files_list
    raise ValueError(f"Failed to retrieve list of files for {report_path}")
ValueError: Failed to retrieve list of files for ./trivy-reports

Additional Context

No response

@kimwnasptd kimwnasptd added the bug Something isn't working label Aug 22, 2024
Copy link

Thank you for reporting us your feedback!

The internal ticket has been created: https://warthogs.atlassian.net/browse/KF-6142.

This message was autogenerated

@kimwnasptd
Copy link
Contributor Author

Then, while not directly related to ensuring the action is working, we also need to fix Knative image gathering logic to include rocks canonical/knative-operators#220

@kimwnasptd
Copy link
Contributor Author

After resolving canonical/knative-operators#219 the next error we see is the following (after setting set -xe):

+ git clone --branch main https://github.com/canonical/kubeflow-roles-operator
Cloning into 'kubeflow-roles-operator'...
remote: Enumerating objects: 502, done.
remote: Counting objects: 100% (226/226), done.
remote: Compressing objects: 100% (114/114), done.
remote: Total 502 (delta 146), reused 152 (delta 112), pack-reused 276 (from 1)
Receiving objects: 100% (502/502), 120.49 KiB | 1.15 MiB/s, done.
Resolving deltas: 100% (262/262), done.
+ cd kubeflow-roles-operator
+ IMAGES+=($(bash ./tools/get-images.sh))
++ bash ./tools/get-images.sh
bash: ./tools/get-images.sh: No such file or directory

This is because the kubelflow-roles-operator does not include any OCI images. There are 2 approaches here:

  1. Add an empty tools/get-images.sh executable in that repo
  2. Have a check in our script and don't run image gathering for that repo

@kimwnasptd
Copy link
Contributor Author

I resolved the above issue in the PR that refactors the code to use python scripts #1036

The script will ignore the roles that don't have images in them

@kimwnasptd
Copy link
Contributor Author

Closing this, since the final effort of #1036 is done.

You can find an update action in
https://github.com/canonical/bundle-kubeflow/actions/runs/10736791016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant