From 3ae1de12b28a73f3d5f49b12a219ae0ae25485a2 Mon Sep 17 00:00:00 2001 From: GotthardG <51994228+GotthardG@users.noreply.github.com> Date: Thu, 10 Apr 2025 14:02:19 +0200 Subject: [PATCH] Add job processing system with streaming endpoint Introduced a `processing` router to handle job streaming using server-sent events. Added `Jobs` and `JobStatus` models for managing job-related data, along with database creation logic. Updated the `sample` router to create new job entries during experiment creation. --- .gitlab-ci.yml | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 460daff..cb8ce21 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -57,17 +57,24 @@ release: stage: release when: manual variables: - TWINE_USERNAME: gitlab-ci-token # Keep username the same - TWINE_PASSWORD: $CI_JOB_TOKEN # Use PAT stored in GitLab CI/CD Variables + TWINE_USERNAME: gitlab-ci-token + TWINE_PASSWORD: $CI_JOB_TOKEN script: - - echo "Setting up Python dependencies..." - - source $VIRTUAL_ENV/bin/activate - - pip install -r requirements.txt - - mkdir -p /app/backend/ssl - - rm -f openapi.json || true - - rm -rf python-client || true - - bash make_openapi_client.sh # Generate OpenAPI client and package - - ls backend/python-client/dist/ # Debug artifacts to ensure files exist + # build and run commands within docker container context + - docker-compose build backend + + # Run commands inside your 'backend' service container + - docker-compose run --rm backend mkdir -p /app/backend/ssl + - docker-compose run --rm backend bash make_openapi_client.sh + + # After script finishes execution within the container, + # revert to the runner environment context if needed + # Assuming 'python-client' is generated and mounted correctly, + # subsequent twine commands must be run out of the container + + - ls backend/python-client/dist/ # Ensure files exist + + # install further publishing requirements outside of docker - pip install --upgrade build setuptools wheel twine - twine check backend/python-client/dist/* - twine upload --repository-url ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/pypi backend/python-client/dist/* \ No newline at end of file