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

Feat: run yq in container if necessary #269

Closed
wants to merge 2 commits into from
Closed

Conversation

Dunky13
Copy link
Contributor

@Dunky13 Dunky13 commented Jan 7, 2021

Implemented a function dyq that runs the yq command in a docker container when the local version is either not installed or not in version 3.

This code prefers local execution over containerised execution due to performance. Plus, why run it in a container, when you can run in locally?

Marc Went added 2 commits January 6, 2021 17:33
yq had to be installed locally due to bin/common.sh yq execution through the otomi bridge. By
running the yq commands in a docker container the installation as well as the version are
guaranteed. As yq@4 has breaking changes. Now sticky at yq@3

#268
In CI there is no docker(-in-docker) but a local yq is available. So this implementation checks if
there is a local yq and is at correct version (3) if so, use local execution, if yq is not installed
then use docker and the docker image to run it. If neither is installed, exit en throw error

#268
@Dunky13 Dunky13 requested a review from Morriz January 7, 2021 12:08
@Dunky13 Dunky13 linked an issue Jan 7, 2021 that may be closed by this pull request
@j-zimnowoda
Copy link
Contributor

Hey, I reviewed exactly the same code at #271
If you want to make separate PRs, please make sure they do not overlap

@j-zimnowoda j-zimnowoda closed this Jan 7, 2021
@Morriz Morriz deleted the yq-error-message branch January 13, 2021 16:54
@0-sv 0-sv mentioned this pull request Jan 18, 2021
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.

Run yq in container to prevent local errors due to versions
2 participants