From 90283cedaea63c46ccd161b45d0cb05240e2a6e3 Mon Sep 17 00:00:00 2001 From: Damien Arnodo Date: Sat, 31 Jan 2026 15:43:00 +0000 Subject: [PATCH] ci: add workflow for automatic deployment --- .gitea/workflows/deploy.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .gitea/workflows/deploy.yml diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml new file mode 100644 index 0000000..2a9ad9c --- /dev/null +++ b/.gitea/workflows/deploy.yml @@ -0,0 +1,31 @@ +name: Deploy Prefect Flows + +on: + push: + branches: [main] + paths: + - 'flows/**' + - 'deploy.py' + workflow_dispatch: + +jobs: + deploy: + runs-on: docker + container: + image: python:3.12-slim + steps: + - name: Install dependencies + run: | + apt-get update && apt-get install -y git + pip install --no-cache-dir prefect prefect-aws + + - name: Checkout repository + run: | + git clone --depth 1 https://gitea.arnodo.fr/${{ gitea.repository }}.git . + git checkout ${{ gitea.sha }} + + - name: Deploy flows to Prefect + env: + PREFECT_API_URL: ${{ secrets.PREFECT_API_URL }} + run: | + python deploy.py