File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -105,17 +105,15 @@ jobs:
105105 fetch-depth : 0
106106
107107 - name : Run hadolint on Dockerfiles
108+ continue-on-error : ${{env.soft-linting == 'true'}}
108109 env :
109110 hadolint_version : ' sha256:e9dbf5113239ef2bf696d20c8f28d3019a47c26a38c98b89344d3e2846c4d5f8'
110111 run : |
111112 echo '::add-matcher::.github/problem-matchers/hadolint.json'
112- find . -name Dockerfile | while IFS= read -r file; do
113- echo "Checking ${file} ..."
114- docker run --rm -i -v "${PWD}"/.hadolint.yaml:/.config/hadolint.yaml \
115- ghcr.io/hadolint/hadolint@${{env.hadolint_version}} \
116- ${{env.soft-linting && '--no-fail'}} < "${file}"
117- done
118- echo 'Done ...'
113+ find . -name Dockerfile -print0 | \
114+ xargs -0 -r docker run --rm -i -v "${PWD}:/app" -w /app \
115+ --entrypoint /bin/hadolint \
116+ ghcr.io/hadolint/hadolint@${{env.hadolint_version}}
119117
120118 shell-lint :
121119 name : Shell script lint checks
You can’t perform that action at this time.
0 commit comments