HOMELAB-1330: ci(workflows): fix lint tooling and pre-existing repo lint errors #336

Open
aaron wants to merge 6 commits from plane/HOMELAB-1330-ci-lint into live
Owner

What

Fixes the CI failures seen on PR #330 after the runner label fix in HOMELAB-1326. The linter jobs were failing because of missing tooling on the K8s runner and pre-existing repo lint errors, not because of the Mattermost changes.

Changes

  • core/terraform/live/network/outputs.tf: removed module.truenas.* outputs that reference a module no longer declared in main.tf, which was causing terraform validate to fail.
  • core/manifests/gateway/routes/otel-collector.yaml and tempo.yaml: added missing newline at EOF so yamllint exits cleanly.
  • .forgejo/workflows/ci.yaml:
    • Install pyyaml before parsing Helm values.yaml files.
    • Make the AI review steps non-blocking when the Ollama endpoint is unreachable.
  • .forgejo/workflows/lint.yaml:
    • Make the yamllint install step more robust across runner images.
    • Download a prebuilt shellcheck binary from the official stable release instead of relying on apt/apk, which are not available in the K8s runner image.

Verify

  • terraform validate passes for core/terraform/live/network
  • yamllint -d relaxed core/manifests/ core/ansible/ exits 0
  • find core/scripts -name '*.sh' -exec shellcheck {} + exits 0
  • python3 -c "import yaml; yaml.safe_load(...) works for all core/charts/**/values.yaml
  • PR #330 rebased on live shows green lint jobs (expected pr-title still fails by design)
## What Fixes the CI failures seen on PR #330 after the runner label fix in HOMELAB-1326. The linter jobs were failing because of missing tooling on the K8s runner and pre-existing repo lint errors, not because of the Mattermost changes. ## Changes - `core/terraform/live/network/outputs.tf`: removed `module.truenas.*` outputs that reference a module no longer declared in `main.tf`, which was causing `terraform validate` to fail. - `core/manifests/gateway/routes/otel-collector.yaml` and `tempo.yaml`: added missing newline at EOF so `yamllint` exits cleanly. - `.forgejo/workflows/ci.yaml`: - Install `pyyaml` before parsing Helm `values.yaml` files. - Make the AI review steps non-blocking when the Ollama endpoint is unreachable. - `.forgejo/workflows/lint.yaml`: - Make the `yamllint` install step more robust across runner images. - Download a prebuilt `shellcheck` binary from the official stable release instead of relying on `apt`/`apk`, which are not available in the K8s runner image. ## Verify - [x] `terraform validate` passes for `core/terraform/live/network` - [x] `yamllint -d relaxed core/manifests/ core/ansible/` exits 0 - [x] `find core/scripts -name '*.sh' -exec shellcheck {} +` exits 0 - [x] `python3 -c "import yaml; yaml.safe_load(...)` works for all `core/charts/**/values.yaml` - [ ] PR #330 rebased on `live` shows green lint jobs (expected `pr-title` still fails by design)
HOMELAB-1330: ci(workflows): fix lint tooling and pre-existing repo lint errors
Some checks failed
CI Review / pr-title (pull_request) Successful in 0s
CI Review / helm-validate (pull_request) Failing after 6s
CI Review / ai-review (pull_request) Successful in 6s
Lint & Validate / terraform-validate (pull_request) Successful in 1m40s
Lint & Validate / yaml-lint (pull_request) Failing after 3s
Lint & Validate / shellcheck (pull_request) Successful in 4s
2955d2a1d2

AI Review (advisory)

🔍 CI Specialist Review

AI review skipped — Ollama endpoint unavailable.


🏗️ Infra Engineer Review

AI review skipped — Ollama endpoint unavailable.

Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge.

## AI Review (advisory) ### 🔍 CI Specialist Review AI review skipped — Ollama endpoint unavailable. --- ### 🏗️ Infra Engineer Review AI review skipped — Ollama endpoint unavailable. _Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge._
HOMELAB-1330: ci(workflows): add apk/apt fallbacks for PyYAML and yamllint
Some checks failed
CI Review / pr-title (pull_request) Successful in 0s
CI Review / helm-validate (pull_request) Failing after 6s
CI Review / ai-review (pull_request) Successful in 4s
Lint & Validate / terraform-validate (pull_request) Successful in 1m37s
Lint & Validate / yaml-lint (pull_request) Failing after 28s
Lint & Validate / shellcheck (pull_request) Successful in 2s
30454d52cf

AI Review (advisory)

🔍 CI Specialist Review

AI review skipped — Ollama endpoint unavailable.


🏗️ Infra Engineer Review

AI review skipped — Ollama endpoint unavailable.

Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge.

## AI Review (advisory) ### 🔍 CI Specialist Review AI review skipped — Ollama endpoint unavailable. --- ### 🏗️ Infra Engineer Review AI review skipped — Ollama endpoint unavailable. _Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge._
HOMELAB-1330: ci(workflows): install lint tools in Python venvs
Some checks failed
Lint & Validate / yaml-lint (pull_request) Waiting to run
Lint & Validate / shellcheck (pull_request) Waiting to run
CI Review / pr-title (pull_request) Successful in 0s
CI Review / helm-validate (pull_request) Failing after 5s
CI Review / ai-review (pull_request) Successful in 3s
Lint & Validate / terraform-validate (pull_request) Has been cancelled
09c1779e04

AI Review (advisory)

🔍 CI Specialist Review

AI review skipped — Ollama endpoint unavailable.


🏗️ Infra Engineer Review

AI review skipped — Ollama endpoint unavailable.

Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge.

## AI Review (advisory) ### 🔍 CI Specialist Review AI review skipped — Ollama endpoint unavailable. --- ### 🏗️ Infra Engineer Review AI review skipped — Ollama endpoint unavailable. _Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge._
HOMELAB-1330: ci(workflows): drop unused Helm install in helm-validate
Some checks failed
Lint & Validate / yaml-lint (pull_request) Waiting to run
Lint & Validate / shellcheck (pull_request) Waiting to run
CI Review / pr-title (pull_request) Successful in 0s
CI Review / helm-validate (pull_request) Failing after 3s
CI Review / ai-review (pull_request) Successful in 4s
Lint & Validate / terraform-validate (pull_request) Has been cancelled
720b940c52

AI Review (advisory)

🔍 CI Specialist Review

AI review skipped — Ollama endpoint unavailable.


🏗️ Infra Engineer Review

AI review skipped — Ollama endpoint unavailable.

Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge.

## AI Review (advisory) ### 🔍 CI Specialist Review AI review skipped — Ollama endpoint unavailable. --- ### 🏗️ Infra Engineer Review AI review skipped — Ollama endpoint unavailable. _Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge._
HOMELAB-1330: ci(workflows): prefer system packages for lint tools
Some checks failed
CI Review / pr-title (pull_request) Failing after 13m10s
CI Review / helm-validate (pull_request) Failing after 3s
CI Review / ai-review (pull_request) Successful in 7s
Lint & Validate / terraform-validate (pull_request) Successful in 1m43s
Lint & Validate / yaml-lint (pull_request) Failing after 8s
Lint & Validate / shellcheck (pull_request) Successful in 2s
2067585bfc

AI Review (advisory)

🔍 CI Specialist Review

AI review skipped — Ollama endpoint unavailable.


🏗️ Infra Engineer Review

AI review skipped — Ollama endpoint unavailable.

Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge.

## AI Review (advisory) ### 🔍 CI Specialist Review AI review skipped — Ollama endpoint unavailable. --- ### 🏗️ Infra Engineer Review AI review skipped — Ollama endpoint unavailable. _Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge._
HOMELAB-1330: ci(workflows): run yaml-lint and helm-validate in python container
Some checks failed
CI Review / pr-title (pull_request) Successful in 1s
CI Review / helm-validate (pull_request) Failing after 17s
CI Review / ai-review (pull_request) Successful in 3s
Lint & Validate / terraform-validate (pull_request) Successful in 2m45s
Lint & Validate / yaml-lint (pull_request) Failing after 9s
Lint & Validate / shellcheck (pull_request) Successful in 3s
7497048cbf
Use harbor.aaron.reynoza.org/docker-cache/library/python:3-slim and install

yamllint/pyyaml via pip. The K8s runner image lacks Python and the runner

user cannot apt-install, so the previous apk/apt/pip fallbacks failed.

AI Review (advisory)

🔍 CI Specialist Review

AI review skipped — Ollama endpoint unavailable.


🏗️ Infra Engineer Review

AI review skipped — Ollama endpoint unavailable.

Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge.

## AI Review (advisory) ### 🔍 CI Specialist Review AI review skipped — Ollama endpoint unavailable. --- ### 🏗️ Infra Engineer Review AI review skipped — Ollama endpoint unavailable. _Powered by qwen2.5-coder:7b via Ollama. Advisory only — does not block merge._
Some checks failed
CI Review / pr-title (pull_request) Successful in 1s
Required
Details
CI Review / helm-validate (pull_request) Failing after 17s
Required
Details
CI Review / ai-review (pull_request) Successful in 3s
Lint & Validate / terraform-validate (pull_request) Successful in 2m45s
Required
Details
Lint & Validate / yaml-lint (pull_request) Failing after 9s
Required
Details
Lint & Validate / shellcheck (pull_request) Successful in 3s
Required
Details
This pull request has changes conflicting with the target branch.
  • .forgejo/workflows/ci.yaml
  • .forgejo/workflows/lint.yaml
  • core/terraform/live/network/outputs.tf
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin plane/HOMELAB-1330-ci-lint:plane/HOMELAB-1330-ci-lint
git switch plane/HOMELAB-1330-ci-lint
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
aaron/infra-core!336
No description provided.