From 3a20c5a4bb12b3828d31e7eed75d81775e682c0a Mon Sep 17 00:00:00 2001 From: Swifty Date: Thu, 5 Jun 2025 19:28:48 +0200 Subject: [PATCH] restore dev deploy (#10122) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ### Changes 🏗️ ### Checklist 📋 #### For code changes: - [ ] I have clearly listed my changes in the PR description - [ ] I have made a test plan - [ ] I have tested my changes according to the test plan: - [ ] ...
Example test plan - [ ] Create from scratch and execute an agent with at least 3 blocks - [ ] Import an agent from file upload, and confirm it executes correctly - [ ] Upload agent to marketplace - [ ] Import an agent from marketplace and confirm it executes correctly - [ ] Edit an agent from monitor, and confirm it executes correctly
#### For configuration changes: - [ ] `.env.example` is updated or already compatible with my changes - [ ] `docker-compose.yml` is updated or already compatible with my changes - [ ] I have included a list of my configuration changes in the PR description (under **Changes**)
Examples of configuration changes - Changing ports - Adding new services that need to communicate with each other - Secrets or environment variable changes - New or infrastructure changes such as databases
--- .../platform-autogpt-deploy-dev.yaml | 51 +++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 .github/workflows/platform-autogpt-deploy-dev.yaml diff --git a/.github/workflows/platform-autogpt-deploy-dev.yaml b/.github/workflows/platform-autogpt-deploy-dev.yaml new file mode 100644 index 0000000000..44da8641ec --- /dev/null +++ b/.github/workflows/platform-autogpt-deploy-dev.yaml @@ -0,0 +1,51 @@ +name: AutoGPT Platform - Deploy Dev Environment + +on: + push: + branches: [ dev ] + paths: + - 'autogpt_platform/**' + +permissions: + contents: 'read' + id-token: 'write' + +jobs: + migrate: + environment: develop + name: Run migrations for AutoGPT Platform + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.11' + + - name: Install Python dependencies + run: | + python -m pip install --upgrade pip + pip install prisma + + - name: Run Backend Migrations + working-directory: ./autogpt_platform/backend + run: | + python -m prisma migrate deploy + env: + DATABASE_URL: ${{ secrets.BACKEND_DATABASE_URL }} + DIRECT_URL: ${{ secrets.BACKEND_DATABASE_URL }} + + trigger: + needs: migrate + runs-on: ubuntu-latest + steps: + - name: Trigger deploy workflow + uses: peter-evans/repository-dispatch@v3 + with: + token: ${{ secrets.DEPLOY_TOKEN }} + repository: Significant-Gravitas/AutoGPT_cloud_infrastructure + event-type: build_deploy_dev + client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}", "repository": "${{ github.repository }}"}'