Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
77c3914
feat(redis): implement redis keys reset
tibo-pdn Jul 6, 2026
9afa62b
Update unit coverage badge
tibo-pdn Jul 6, 2026
ebc12d0
Merge origin/main into 704-reset-all-redis-keys-when-api-startup
Copilot Jul 10, 2026
f36c4f2
fix(cicd): semgrep and release update improvments (#957)
leoguillaume Jul 11, 2026
2342f8a
chore(doc): update generated documentation and release versions (#958)
github-actions[bot] Jul 11, 2026
cf6b29f
chore(deps): bump undici from 7.25.0 to 7.28.0 in /docs (#939)
dependabot[bot] Jul 11, 2026
7aa03c0
refacto(keys): migrate GET /v1/admin/tokens to clean architecture (#947)
leoguillaume Jul 20, 2026
c51962b
fix(cicd): install missing packages to run e2e tests and change docum…
leoguillaume Jul 22, 2026
6ee8b37
chore(deps): bump tar from 7.5.13 to 7.5.21 in /docs (#966)
dependabot[bot] Jul 22, 2026
e763146
chore(deps): bump svgo in /docs (#965)
dependabot[bot] Jul 22, 2026
9e34d82
fix(cicd): install missing packages to run e2e tests and change docum…
leoguillaume Jul 22, 2026
f0fe8fe
chore(deps): bump sharp from 0.34.5 to 0.35.0 in /docs (#967)
dependabot[bot] Jul 22, 2026
12e9d36
fix(auth): return generic invalid-credentials error to prevent user e…
bakr-a Jul 22, 2026
7740dd6
fix(cicd): ignore unfixed perl-base CVEs blocking Trivy CRITICAL scan…
leoguillaume Jul 22, 2026
9fd3f6b
refacto(users): patch /v1/admin/users endpoint toward clean architect…
benjaminpilia Jul 22, 2026
ae826c8
feat(redis): move reset redis keys out of legacy class
tibo-pdn Jul 22, 2026
f7185a8
Merge branch '704-reset-all-redis-keys-when-api-startup' of github.co…
tibo-pdn Jul 22, 2026
c55f59b
feat(redis): implement redis keys reset
tibo-pdn Jul 6, 2026
36eb0e7
feat(redis): move reset redis keys out of legacy class
tibo-pdn Jul 22, 2026
21869bb
Update unit coverage badge
tibo-pdn Jul 22, 2026
0e0d603
Merge branch '704-reset-all-redis-keys-when-api-startup' of github.co…
tibo-pdn Jul 22, 2026
2d23ed1
Update unit coverage badge
tibo-pdn Jul 22, 2026
6a105f9
feat(redis): implement redis keys reset
tibo-pdn Jul 6, 2026
17d947a
feat(redis): move reset redis keys out of legacy class
tibo-pdn Jul 22, 2026
cdfdce9
Merge branch '704-reset-all-redis-keys-when-api-startup' of github.co…
tibo-pdn Jul 22, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ RABBITMQ_HOST=rabbitmq
REDIS_PORT=6379
REDIS_USER=redis
REDIS_PASSWORD=changeme

11 changes: 2 additions & 9 deletions .github/.env.ci.example
Original file line number Diff line number Diff line change
@@ -1,12 +1,5 @@
# Application configuration
COMPOSE_NAME=opengatellm-ci
CONFIG_FILE=api/tests/integ/config.test.yml
COMPOSE_FILE=.github/compose.ci.yml

# Dependencies
POSTGRES_PORT=15432
REDIS_PORT=16379
RABBITMQ_PORT=25672
RABBITMQ_UI_PORT=15672

# Secrets (to complete)
# ALBERT_API_KEY=
ALBERT_API_KEY=
8 changes: 8 additions & 0 deletions .github/.trivyignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@ CVE-2026-42496 exp:2026-09-01
# Reported in perl-base from base image. Re-evaluate after 2026-09-01.
CVE-2026-8376 exp:2026-09-01

# Perl regex trie overflow (incorrect matches with >65535 alternation branches) — no upstream Debian fix yet
# Reported in perl-base from base image. Upstream fix is in Perl 5.43.10 only. Re-evaluate after 2026-09-01.
CVE-2026-13221 exp:2026-09-01

# Perl Storable signed integer overflow on crafted SX_HOOK — no upstream Debian fix yet
# Reported in perl-base from base image. Fixed upstream in Storable 3.41. Re-evaluate after 2026-09-01.
CVE-2026-57433 exp:2026-09-01

# libssh2 Out-of-Bounds Write via Unchecked — no upstream Debian fix yet
# Reported in libssh2-1t64 from base image. Re-evaluate after 2026-09-01.
CVE-2026-55200 exp:2026-09-01
Expand Down
2 changes: 1 addition & 1 deletion .github/badges/coverage.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"schemaVersion":1,"label":"coverage","message":"55.48%","color":"red"}
{"schemaVersion": 1, "label": "coverage", "message": "59.81%", "color": "red"}
37 changes: 0 additions & 37 deletions .github/compose.ci.yml

This file was deleted.

30 changes: 4 additions & 26 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ on:
jobs:
prepare:
name: Prepare build
if: >-
github.event_name == 'workflow_dispatch' ||
github.event_name == 'release' ||
github.actor != 'github-actions[bot]'
runs-on: ubuntu-latest
# Builds triggered by a PR commit wait here for a manual approval from the GitHub Actions UI
# (configure required reviewers on the "build-approval" environment in repo settings).
# Builds triggered by push/release/workflow_dispatch use the unprotected "build-auto" environment
# and therefore run immediately, exactly like before.
environment: ${{ github.event_name == 'pull_request' && 'build-approval' || 'build-auto' }}
outputs:
image_tag: ${{ steps.set_tag.outputs.tag }}
Expand Down Expand Up @@ -49,17 +49,12 @@ jobs:
env:
API_IMAGE_NAME: ghcr.io/etalab-ia/opengatellm/api
IMAGE_TAG: ${{ needs.prepare.outputs.image_tag }}
outputs:
commit_title: ${{ steps.get_head_commit_title.outputs.title }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref || github.ref_name }}

- id: get_head_commit_title
run: echo "title=$(git log --format=%B -n 1 HEAD | head -n 1)" >> $GITHUB_OUTPUT

- name: Log in to GitHub Container Registry
uses: docker/login-action@v3
with:
Expand Down Expand Up @@ -206,20 +201,3 @@ jobs:
with:
image-name: ghcr.io/etalab-ia/opengatellm/playground
image-tag: ${{ needs.prepare.outputs.image_tag }}

deploy-dev:
# Only chain automatically into the deploy workflow for the pre-existing, auto-triggered flow
# (push to main). Builds approved manually from a PR are not deployed automatically.
if: github.event_name == 'push'
name: Deploy to dev
needs:
- build-opengatellm-api
- trivy-scan-api
- build-opengatellm-playground
- trivy-scan-playground
- build-albert-playground
uses: ./.github/workflows/deploy.yml
with:
commit_title: ${{ needs.build-opengatellm-api.outputs.commit_title }}
secrets:
GITLAB_CI_TOKEN: ${{ secrets.GITLAB_CI_TOKEN }}
45 changes: 28 additions & 17 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,10 @@
name: Deploy

on:
workflow_call:
inputs:
commit_title:
description: "Title of the commit that triggered the build, used for the GitLab pipeline name"
required: true
type: string
environment:
description: "Deployment environment"
required: false
type: string
default: dev
secrets:
GITLAB_CI_TOKEN:
required: true
workflow_run:
workflows: ["Build and scan images"]
types:
- completed
workflow_dispatch:
inputs:
commit_title:
Expand All @@ -30,14 +20,35 @@ on:

jobs:
deploy-dev:
name: Deploy from ${{ github.ref_name }}/${{ github.sha }}
if: >-
github.event_name == 'workflow_dispatch' ||
(
github.event.workflow_run.conclusion == 'success' &&
github.event.workflow_run.event == 'push' &&
github.event.workflow_run.actor.login != 'github-actions[bot]'
)
name: Deploy from ${{ github.event.workflow_run.head_branch || github.ref_name }}/${{ github.event.workflow_run.head_sha || github.sha }}
runs-on: ubuntu-latest
steps:
- name: Get commit title
id: commit_title
env:
HEAD_COMMIT_MESSAGE: ${{ github.event.workflow_run.head_commit.message }}
EVENT_NAME: ${{ github.event_name }}
COMMIT_TITLE_INPUT: ${{ inputs.commit_title }}
run: |
if [ "$EVENT_NAME" = "workflow_dispatch" ]; then
TITLE="$COMMIT_TITLE_INPUT"
else
TITLE="$(echo "$HEAD_COMMIT_MESSAGE" | head -n 1)"
fi
echo "title=$TITLE" >> "$GITHUB_OUTPUT"

- name: Trigger dev deployment
env:
GITLAB_CI_TOKEN: ${{ secrets.GITLAB_CI_TOKEN }}
PIPELINE_NAME: ${{ github.event.repository.name }} - ${{ inputs.commit_title }}
DEPLOYMENT_ENVIRONMENT: ${{ inputs.environment }}
PIPELINE_NAME: ${{ github.event.repository.name }} - ${{ steps.commit_title.outputs.title }}
DEPLOYMENT_ENVIRONMENT: ${{ inputs.environment || 'dev' }}
run: |
RESPONSE="$(curl --request POST \
--form token="$GITLAB_CI_TOKEN" \
Expand Down
54 changes: 24 additions & 30 deletions .github/workflows/release_updates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,22 +18,14 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: astral-sh/setup-uv@d4b2f3b6ecc6e67c4457f6d3e41ec42d3d0fcb86 # v5.4.2

- name: Checkout du code
uses: actions/checkout@v4
with:
ref: main
ref: ${{ github.event_name == 'pull_request' && github.sha || 'main' }}
fetch-depth: 0

- name: Configure Python
uses: actions/setup-python@v5
with:
python-version: '3.12'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install ".[api,playground,dev]"

- name: Update project version
run: |
git fetch --tags --force
Expand All @@ -43,34 +35,36 @@ jobs:
exit 0
fi
sed -i -E "s/^[[:space:]]*version[[:space:]]*=.*/version = \"${latest_version}\"/" pyproject.toml
sed -i -E "s|(image:[[:space:]]*ghcr.io/etalab-ia/opengatellm/api:).*|\\1${latest_version}|" compose.example.yml
sed -i -E "s|(image:[[:space:]]*ghcr.io/etalab-ia/opengatellm/playground:).*|\\1${latest_version}|" compose.example.yml
sed -i -E "s/^[[:space:]]*swagger_version:[[:space:]]*.*/ swagger_version: ${latest_version}/" config.example.yml
sed -i -E "s/(badge:[[:space:]]*)'[^']*'/\1'v${latest_version}'/" docs/astro.config.mjs

- name: Generate documentation
env:
DOCS_DIR: ${{ github.workspace }}/docs
CONFIG_FILE: ${{ github.workspace }}/config.example.yml
run: |
uv venv
uv pip install -p .venv/bin/python ".[api,playground,dev]"
. .venv/bin/activate
PYTHONPATH=. python ./scripts/docs/generate_configuration_documentation.py --output ./docs/src/content/docs/configuration/configuration_file.mdx
make quickstart
api_health=unknown
for _ in $(seq 1 30); do
api_container_id="$(docker compose --env-file .env --file compose.example.yml ps -q api)"
if [ -n "$api_container_id" ]; then
api_health="$(docker inspect --format='{{if .State.Health}}{{.State.Health.Status}}{{else}}none{{end}}' "$api_container_id")"
if [ "$api_health" = "healthy" ]; then
break
fi
fi
sleep 2
done
if [ "$api_health" != "healthy" ]; then
echo "API container is not healthy (status: $api_health)"
docker compose --env-file .env --file compose.yml logs --no-color api
if ! docker compose --file ./compose.example.yml up --detach --wait; then
echo "Services did not become healthy." >&2
echo "::group::Docker Compose status"
docker compose --file ./compose.example.yml ps || true
echo "::endgroup::"

echo "::group::Docker Compose logs (all services)"
docker compose --file ./compose.example.yml logs --no-color || true
echo "::endgroup::"

echo "::group::API health probe"
curl -sv "http://localhost:8000/health" || true
echo "::endgroup::"
exit 1
fi
curl -fSL --retry 8 --retry-all-errors --retry-delay 2 http://localhost:8000/openapi.json -o ./docs/openapi.json
docker pull redocly/cli
docker run --rm -v ${{ github.workspace }}/docs:/spec redocly/cli build-docs /spec/openapi.json --output /spec/redoc-static.html
docker run --rm -v "$DOCS_DIR:/spec" redocly/cli build-docs /spec/openapi.json --output /spec/redoc-static.html

- name: Create pull request for release updates
uses: peter-evans/create-pull-request@v6
Expand Down
Loading
Loading