Skip to content

Update dockerlint.yml #351

Update dockerlint.yml

Update dockerlint.yml #351

Workflow file for this run

name: dockerlint
on:
push:
branches:
- develop
pull_request:
workflow_dispatch:
jobs:
dockerlint:
runs-on: ubuntu-slim
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: dockerlint
run: |
set -x
curl -sSfL https://github.com/hadolint/hadolint/releases/latest/download/hadolint-Linux-$(uname -m) -o hadolint
chmod +x hadolint
for file in $(find -name "*Dockerfile"); do
# DL3018 warning: Pin versions in apk add. Instead of `apk add <package>` use `apk add <package>=<version>`
# DL3064 warning: Potentially sensitive data should not be used in the `ARG` or `ENV` commands
# DL3002 warning: Last USER should not be root
./hadolint "$file" --ignore DL3018 --ignore DL3002 --ignore DL3064 | tee -a hadolint.log
done
if [ -n "$(cat hadolint.log)" ]; then
exit 1
fi