summaryrefslogtreecommitdiffstats
path: root/.github
diff options
context:
space:
mode:
authorAustin S. Hemmelgarn <austin@netdata.cloud>2020-12-09 07:18:35 -0500
committerGitHub <noreply@github.com>2020-12-09 07:18:35 -0500
commita3ada604962b126b20c86a41e8aac5ca451b8a33 (patch)
treef01eb28a0755d94a7cbc49bc351d31e2d9af90f8 /.github
parent6d0f5a672f87605e5bf45da53fdd10c9d196e1be (diff)
Added numerous improvements to our Docker image. (#10308)
* Initial cleanup of Docker entrypoint script. * Add linting for our Docker files. * Fix warnings reported by hadolint. * Add support for automatic claiming on startup. * Optimize Docker image structure. This shuffles some things around in the Docker image to cut down on the total number of layers and make the image more caching friendly, which will cut down on overall time required to both initially pull the image and time spent pulling updated versions of the image. It also shrinks the image size by about 2MB.
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/review.yml21
1 files changed, 21 insertions, 0 deletions
diff --git a/.github/workflows/review.yml b/.github/workflows/review.yml
index 50cabe0a47..ca8f6de130 100644
--- a/.github/workflows/review.yml
+++ b/.github/workflows/review.yml
@@ -5,6 +5,7 @@ on:
pull_request:
env:
run_eslint: 0
+ run_hadolint: 0
run_shellcheck: 0
run_yamllint: 0
jobs:
@@ -29,6 +30,26 @@ jobs:
reporter: github-pr-check
eslint_flags: '.'
+ hadolint:
+ name: hadolint
+ runs-on: ubuntu-latest
+ steps:
+ - name: Git clone repository
+ uses: actions/checkout@v2
+ with:
+ fetch-depth: 0
+ - name: Check files
+ run: |
+ if git diff --name-only origin/${{ github.base_ref }} HEAD | grep -Eq '*Dockerfile*' ; then
+ echo 'run_hadolint=1' >> $GITHUB_ENV
+ fi
+ - name: Run hadolint
+ if: env.run_hadolint == 1
+ uses: reviewdog/action-hadolint@v1
+ with:
+ github_token: ${{ secrets.GITHUB_TOKEN }}
+ reporter: github-pr-check
+
shellcheck:
name: shellcheck
runs-on: ubuntu-latest