[mod] CI: refactor checker.yml - make search.checker (#4730)

Style changes, cleanup and improved integration with CI by leveraging the use of
shared cache between all workflows (not functional until all workflows have been
refactored).
This commit is contained in:
Ivan Gabaldon 2025-05-08 13:58:06 +02:00 committed by GitHub
parent bc06b1aece
commit f32fcb1243
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,31 +1,46 @@
name: "Checker"
on: # yamllint disable-line rule:truthy
---
name: Checker
# yamllint disable-line rule:truthy
on:
workflow_dispatch:
schedule:
- cron: "0 4 * * 5"
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: false
permissions:
contents: read
env:
PYTHON_VERSION: "3.13"
jobs:
checker:
name: Checker
runs-on: ubuntu-24.04
search:
name: Search
runs-on: ubuntu-24.04-arm
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Ubuntu packages
run: |
sudo ./utils/searxng.sh install packages
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.13'
architecture: 'x64'
python-version: "${{ env.PYTHON_VERSION }}"
- name: Install Python dependencies
run: |
make V=1 install
- name: Checkout
uses: actions/checkout@v4
with:
persist-credentials: "false"
- name: Checker
run: |
make search.checker
- name: Setup cache Python
uses: actions/cache@v4
with:
key: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-${{ hashFiles('./requirements*.txt') }}"
restore-keys: "python-${{ env.PYTHON_VERSION }}-${{ runner.arch }}-"
path: "./local"
- name: Setup venv
run: make V=1 install
- name: Search checker
run: make search.checker