diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml new file mode 100644 index 0000000..28e9b1f --- /dev/null +++ b/.gitea/workflows/ci.yml @@ -0,0 +1,24 @@ +# doorman CI [#784] — fleet standard per Discourse t/333. +# Badge-door code: shellcheck zero-warning + functional tests + secret scan. +name: ci +on: [push, pull_request] +jobs: + lint-and-test: + runs-on: ubuntu-latest + container: + image: node:20-bookworm + steps: + - uses: actions/checkout@v4 + - name: shellcheck (zero-warning) + run: | + apt-get update -qq && apt-get install -qq -y shellcheck >/dev/null + git ls-files '*.sh' | grep -v '^legacy/' | xargs -r shellcheck + - name: functional tests + run: bash tests/run-tests.sh + - name: secret scan + run: | + if grep -rInE "BEGIN (RSA |OPENSSH |EC |DSA )?PRIVATE KEY|aws_secret_access_key *=|AKIA[0-9A-Z]{16}" --exclude-dir=.git --exclude-dir=legacy .; then + echo "::error::secret material committed"; exit 1 + else + echo "secret scan clean" + fi