From 3cb1b23669a1202e10f56e606c69d74c9cbc5410 Mon Sep 17 00:00:00 2001 From: Alexis Bruneteau Date: Wed, 1 Oct 2025 17:52:21 +0200 Subject: [PATCH] Add DVC S3 credentials to CI/CD pipeline MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Configure DVC to use AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY from Gitea secrets (DVC_ID and DVC_PASSWORD) for MinIO/S3 access. Changes: - Added DVC credentials to all DVC operations (pull/push) - Changed poetry install to use --no-root flag for faster installs - Credentials applied to both test and train jobs 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- .gitea/workflows/mlops-pipeline.yml | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/mlops-pipeline.yml b/.gitea/workflows/mlops-pipeline.yml index 5f12f3f..e53233d 100644 --- a/.gitea/workflows/mlops-pipeline.yml +++ b/.gitea/workflows/mlops-pipeline.yml @@ -31,12 +31,15 @@ jobs: run: pip install poetry - name: Install dependencies - run: poetry install --no-interaction + run: poetry install --no-interaction --no-root - name: Setup DVC run: | poetry run dvc remote list poetry run dvc pull || echo "DVC pull failed, continuing..." + env: + AWS_ACCESS_KEY_ID: ${{ secrets.DVC_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.DVC_PASSWORD }} - name: Start API server run: | @@ -72,12 +75,15 @@ jobs: run: pip install poetry - name: Install dependencies - run: poetry install --no-interaction + run: poetry install --no-interaction --no-root - name: Setup DVC run: | poetry run dvc remote list poetry run dvc pull || echo "DVC pull failed, continuing..." + env: + AWS_ACCESS_KEY_ID: ${{ secrets.DVC_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.DVC_PASSWORD }} - name: Run DVC pipeline run: poetry run dvc repro @@ -89,6 +95,9 @@ jobs: - name: Push DVC changes run: | poetry run dvc push || echo "DVC push failed, continuing..." + env: + AWS_ACCESS_KEY_ID: ${{ secrets.DVC_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.DVC_PASSWORD }} deploy: needs: train