Skip to content

Commit

Permalink
chore: update ci/iscc
Browse files Browse the repository at this point in the history
- Fix container CLI detection

Signed-off-by: Hiroshi Miura <[email protected]>
  • Loading branch information
miurahr committed Jun 2, 2024
1 parent 14817a5 commit 2792b1c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
3 changes: 1 addition & 2 deletions ci/iscc
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,7 @@ WORKDIR /work
ENTRYPOINT ["iscc"]
__EOF__

CMD="$(type -p docker)" || [[ -e $CMD ]] && $CMD info >/dev/null 2>&1 || CMD="$(type -p nerdctl)"
$CMD info > /dev/null || false
CMD="$(type -p docker)" && $CMD info >/dev/null 2>&1 || CMD="$(type -p nerdctl)" && $CMD info > /dev/null || false
echo Select container CLI: $CMD

IMAGEID=$($CMD images -q $IMAGE)
Expand Down
5 changes: 2 additions & 3 deletions ci/osslsigncode
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@ bindpaths() {
done
}

CMD="$(type -p docker)" || [[ -e $CMD ]] && $CMD info >/dev/null 2>1 || CMD="$(type -p nerdctl)"
echo select container CLI: $CMD
$CMD info || false
CMD="$(type -p docker)" && $CMD info >/dev/null 2>1 || CMD="$(type -p nerdctl)" && $CMD info >/dev/null || false
echo Select container CLI: $CMD

# build container image
CTX=$(mktemp -d)
Expand Down

0 comments on commit 2792b1c

Please sign in to comment.