-
Notifications
You must be signed in to change notification settings - Fork 70
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
[REQ] Implement Copa Metrics #761
Comments
I believe copa uses buildkit and buildKit provides extensive logging and can expose detailed metrics about the build process. so we can have this. Let me know , if I can start working on this ? |
@pradhans0906 thanks for your interest! it would be great if you can provide link to existing buildkit metrics and create a doc/list of metrics that can be useful for copa specifically |
So what I meant from from my comment was : We can get the build kit to run on debug mode (--debug) `BUILDKIT_PROGRESS=plain copa patch --scanner docker-scout -i node:18 --debug DEBU[0000] Trying docker driver #2 resolve image config for docker-image://docker.io/library/node:18 #3 docker-image://docker.io/library/node:18 #3 docker-image://docker.io/library/node:18 #3 docker-image://docker.io/library/node:18 #3 docker-image://docker.io/library/node:18 #3 docker-image://docker.io/library/node:18 #4 docker-image://docker.io/library/debian:12-slim #4 docker-image://docker.io/library/debian:12-slim #5 apt-get update #6 apt-get install busybox-static #7 copy /bin/busybox /bin/busybox #8 mkdir /copa-out #9 /bin/busybox sh -c #9 DONE 0.1s #10 apt-get update #11 sh -c apt-get -s upgrade 2>/dev/null | grep -q ^Inst || exit 1 #12 sh -c output=$(apt-get upgrade -y && apt-get clean -y && apt-get autoremove 2>&1); if [ $? -ne 0 ]; then echo $output >>error_log.txt; fi #13 /bin/sh -c if [ -s error_log.txt ]; then cat error_log.txt; exit 1; fi #14 sh -c grep "^Package:|^Version:" "/var/lib/dpkg/status" >> "results.manifest" #15 diff (/bin/sh -c if [ -s error_log.txt ]; then cat error_log.txt; exit 1; fi) -> (sh -c grep "^Package:|^Version:" "/var/lib/dpkg/status" >> "results.manifest") #16 diff (sh -c apt-get -s upgrade 2>/dev/null | grep -q ^Inst || exit 1) -> (/bin/sh -c if [ -s error_log.txt ]; then cat error_log.txt; exit 1; fi) #17 merge (docker-image://docker.io/library/node:18, diff (sh -c apt-get -s upgrade 2>/dev/null | grep -q ^Inst || exit 1) -> (/bin/sh -c if [ -s error_log.txt ]; then cat error_log.txt; exit 1; fi)) #18 exporting to docker image format Let me know if my understanding matches yours, or if you had a different approach in mind for incorporating BuildKit's debug output as metrics for Copa. |
What kind of request is this?
None
What is your request or suggestion?
Have copa return metrics like total time to run, this could be helpful to compare update all vs scanner approach and when adding new features.
Are you willing to submit PRs to contribute to this feature request?
The text was updated successfully, but these errors were encountered: