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

Adds yq and ag utilities #59

Merged
merged 1 commit into from
Aug 12, 2021
Merged

Conversation

clcollins
Copy link
Member

Adds yq (yaml parsing utility) and ag (faster-than-grep recursive
search tool)

Signed-off-by: Christopher Collins collins.christopher@gmail.com

RUN /bin/bash -c "curl -sSLf -O $(curl -sSLf ${YQ_URL} -o - | jq -r '.assets[] | select(.name|test("linux_amd64$")) | .browser_download_url') "
# Check the binary and checksum match
# This is terrible, but not sure how to do this better.
RUN rhash -c checksums | grep Success:1
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm not sure that addresses the issue. The problem is rhash won't check just a single file, so when I check, it shows all the other release binaries from YQ as "missed" and returns 1. It also shows a single success, for the single binary that's been downloaded ( as Success:1) so I was grep-ing on the existence of that to have a return 0 while still doing some kind of validation.

I don't know how to do something better there. Ideally, rhash would just allow for a single-file check, or something like "allow missing", but I haven't found that it has any options like that.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ok, this can be fixed later and we know this is a hack for now, for me that is good enough

@georgettica
Copy link
Contributor

Please fix conflicts and I'll merge

@openshift-ci openshift-ci bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 11, 2021
@georgettica
Copy link
Contributor

@clcollins pinging here as I saw you are online

Adds `yq` (yaml parsing utility) and `ag` (faster-than-grep recursive
search tool)

Signed-off-by: Christopher Collins <collins.christopher@gmail.com>
@clcollins
Copy link
Member Author

@georgettica Rebased, please have a look.

@openshift-ci openshift-ci bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 12, 2021
@georgettica
Copy link
Contributor

/lgtm

@georgettica georgettica merged commit 9f55690 into openshift:master Aug 12, 2021
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Aug 12, 2021
@clcollins clcollins deleted the add_utils branch December 8, 2022 20:00
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants