diff --git a/.drone.yml b/.drone.yml index e7f56bd..eef53a5 100644 --- a/.drone.yml +++ b/.drone.yml @@ -10,7 +10,4 @@ steps: - name: lint image: bdebyl/yamllint command: - - export YML_FILES=$(find ansible/ -name '*.yml' -not -name '*vault*') - - source $PWD/.lint-vars.sh - - ansible-lint -x $ANSIBLE_LINT_SKIP_LIST $YML_FILES - - yamllint $YML_FILES + - .lint.sh diff --git a/.lint.sh b/.lint.sh new file mode 100755 index 0000000..5de4cd3 --- /dev/null +++ b/.lint.sh @@ -0,0 +1,7 @@ +#!/bin/sh +export YML_FILES="$(find ansible/ -name '*.yml' -not -name '*vault*')" + +# Source the lint variables file (shared with Makefile) +. ./.lint-vars.sh +ansible-lint -x "$ANSIBLE_LINT_SKIP_LIST" $YML_FILES +yamllint $YML_FILES