-
Notifications
You must be signed in to change notification settings - Fork 0
Docker multi arch #1
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds a Docker multi-architecture inspector tool to help analyze Docker images stored in Cloudsmith repositories. The tool provides hierarchical breakdown of images by tag, showing manifest digests, platform information, sync status, and download counts.
- Added a shell script that inspects Docker multi-arch images via Cloudsmith APIs
- Provides download count aggregation across all manifests for complete image statistics
- Updates repository README to reflect its new purpose as a support engineering resource collection
Reviewed Changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated 10 comments.
File | Description |
---|---|
README.md | Updated repository description from template to support engineering resources |
Docker/Multi-Arch-Inspector/run.sh | Main shell script for inspecting Docker multi-arch images |
Docker/Multi-Arch-Inspector/README.md | Documentation explaining the multi-arch inspector tool usage |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
CLOUDSMITH_URL="https://docker.cloudsmith.io" | ||
fi | ||
|
||
# uthorization header |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo in comment: 'uthorization' should be 'Authorization'
# uthorization header | |
# Authorization header |
Copilot uses AI. Check for mistakes.
case ${LC_ALL:-${LC_CTYPE:-$LANG}} in *UTF-8*|*utf8*) : ;; *) CHECK='OK'; CROSS='X' ;; esac | ||
|
||
completed() { printf '%s%s%s %s\n' "$GREEN" "$CHECK" "$RESET" "$*"; } | ||
progress() { printf '%s%s%s %s\n' "$YELLOW" "$TIMER" "$RESET" "$*"; } |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Variable YELLOW is referenced but never defined. This will cause the progress function to output empty color codes.
Copilot uses AI. Check for mistakes.
|
||
completed() { printf '%s%s%s %s\n' "$GREEN" "$CHECK" "$RESET" "$*"; } | ||
progress() { printf '%s%s%s %s\n' "$YELLOW" "$TIMER" "$RESET" "$*"; } | ||
quarantined() { printf '%s%s%s %s\n' "$ORANGE" "$VULN" "$RESET" "$*"; } |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Variable ORANGE is referenced but never defined. This will cause the quarantined function to output empty color codes.
Copilot uses AI. Check for mistakes.
;; | ||
|
||
Failed) | ||
echo " |____ Status: ${STATUS[0]} ${FAIL}" |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Variable FAIL is referenced but never defined. This should be CROSS based on the other status display patterns.
Copilot uses AI. Check for mistakes.
;; | ||
|
||
Failed) | ||
echo " |____ Status: ${STATUS[1]} ${FAIL}" |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Variable FAIL is referenced but never defined. This should be CROSS based on the other status display patterns.
Copilot uses AI. Check for mistakes.
getDockerDigests () { | ||
|
||
local nTAG="$1" | ||
local totalDownloads=0 |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The totalDownloads variable is declared as local inside getDockerDigests function but is being incremented inside the nested getPackageData function where it's not accessible. This will always show 0 downloads.
Copilot uses AI. Check for mistakes.
getDigestData "${DIGESTS[i]}" | ||
echo | ||
done | ||
echo " |___ Total Downloads: ${totalDownloads}" |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The totalDownloads variable is declared as local inside getDockerDigests function but is being incremented inside the nested getPackageData function where it's not accessible. This will always show 0 downloads.
Copilot uses AI. Check for mistakes.
|
||
<img src="example.gif" width=50%> | ||
|
||
## Prequisities |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo in heading: 'Prequisities' should be 'Prerequisites'
## Prequisities | |
## Prerequisites |
Copilot uses AI. Check for mistakes.
|
||
## How to use | ||
|
||
Execute run.sh and pass in 4 arguements ( domain, org, repo and image name). |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo: 'arguements' should be 'arguments'
Execute run.sh and pass in 4 arguements ( domain, org, repo and image name). | |
Execute run.sh and pass in 4 arguments ( domain, org, repo and image name). |
Copilot uses AI. Check for mistakes.
# Docker Multi-Arch images overview script | ||
|
||
The script will return an overview of your Docker multi-arch images stored in your Cloudsmith repository. | ||
It provides a hierarchial breakdown of each image by tag, showing the index digest and it's associated manifest digests with their platform, cloudsmith sync status and downloads count. |
Copilot
AI
Sep 19, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo: 'hierarchial' should be 'hierarchical'
It provides a hierarchial breakdown of each image by tag, showing the index digest and it's associated manifest digests with their platform, cloudsmith sync status and downloads count. | |
It provides a hierarchical breakdown of each image by tag, showing the index digest and it's associated manifest digests with their platform, cloudsmith sync status and downloads count. |
Copilot uses AI. Check for mistakes.
📄 Summary
Added Docker multi-arch script.