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

fix: Attempt to install jq on all runners #105

Merged
merged 4 commits into from
Jan 17, 2024

Conversation

musoke
Copy link
Contributor

@musoke musoke commented Jan 16, 2024

Fixes: #104

I took the simplest approach, of just removing the check on whether the runner is hosted by GitHub. This seems to work for both non-container and container jobs.

There may be other cases and subtleties that I am missing.

The one caveat is that the container has to have curl installed; this was easy to do but may be worth adding to the readme.

if: ${{ !startsWith(runner.name, 'GitHub Actions') }}
# # Skip installation on GitHub-hosted runners:
# # https://github.com/orgs/community/discussions/48359#discussioncomment-5323864
# if: ${{ !startsWith(runner.name, 'GitHub Actions') }}
uses: dcarbone/install-jq-action@v2.1.0
with:
force: false # Skip install when an existing `jq` is present
Copy link
Contributor Author

Choose a reason for hiding this comment

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

force: false means that dcarbone/install-jq-action does not attempt to install jq if it already exists. This seems to be sufficient to avoid reinstalling it on GitHub-hosted images, which already have jq installed?

Copy link
Member

Choose a reason for hiding this comment

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

The fact that jq is required should be clearly documented though

action.yml Outdated Show resolved Hide resolved
Co-authored-by: Ian Butterworth <i.r.butterworth@gmail.com>
@IanButterworth
Copy link
Member

Please do add the curl note to the readme

Copy link
Member

@IanButterworth IanButterworth left a comment

Choose a reason for hiding this comment

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

LGTM. @omus

Copy link
Collaborator

@omus omus left a comment

Choose a reason for hiding this comment

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

Thanks for this. Let's get this working first and later we can try find a way avoid the install if it's slowing things down.

README.md Outdated Show resolved Hide resolved
@IanButterworth IanButterworth merged commit 3e0649a into julia-actions:main Jan 17, 2024
19 checks passed
@musoke musoke deleted the jq-install branch January 17, 2024 23:05
@musoke musoke restored the jq-install branch January 17, 2024 23:09
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request Jan 17, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request Jan 17, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request Jan 17, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request Jan 17, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request Apr 13, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request Apr 13, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request Apr 13, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request May 6, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105, which is included in
v2.0.0.
musoke added a commit to musoke/WolframExpr.jl that referenced this pull request May 6, 2024
There was a bug in julia-actions/cache that prevented v1.5.1 from
running in jobs that run in containers.  This is fixed by
julia-actions/cache#105, which is included in
v2.0.0.
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.

Cannot assume jq is installed on runners named GitHub Actions
4 participants