Skip to content

Commit 1cb0bc8

Browse files
committed
dec-18 lint docker file
1 parent af83fd0 commit 1cb0bc8

File tree

1 file changed

+17
-3
lines changed

1 file changed

+17
-3
lines changed

.github/workflows/docker-pipeline.yaml

+17-3
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,20 @@ jobs:
1414
name: lint dockerfiles
1515
runs-on: [ubuntu-latest]
1616
steps:
17-
- name: Checkout Code
18-
uses: actions/checkout@v3
19-
17+
- name: Checkout Code
18+
uses: actions/checkout@v3
19+
- name: Install hadolint
20+
runs: |
21+
sudo wget -O /usr/local/bin/hadolint \
22+
https://github.com/hadolint/hadolint/releases/latest/download/hadolint-Linux-x86_64
23+
sudo chmod +x /usr/local/bin/hadolint
24+
- name: Find and Lint Dockerfiles
25+
run: |
26+
find . -name "Dockerfile" | while read dockerfile; do
27+
echo "Linting $dockerfile"
28+
hadolint "$dockerfile"
29+
done
30+
31+
32+
33+

0 commit comments

Comments
 (0)