chore: remove gitlab config #7
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Deployment | |
| on: | |
| push: | |
| branches: | |
| - main | |
| workflow_dispatch: | |
| inputs: | |
| BEC_CORE_BRANCH: | |
| description: 'Branch of BEC Core to install' | |
| required: false | |
| type: string | |
| BEC_ATLAS_BRANCH: | |
| description: 'Branch of BEC Atlas to install' | |
| required: false | |
| type: string | |
| BEC_DEPLOYMENT_ENVIRONMENT: | |
| description: 'Deployment environment (e.g., dev, qa or prod)' | |
| required: false | |
| default: 'qa' | |
| type: string | |
| # default: least privileged permissions across all jobs | |
| permissions: | |
| contents: read | |
| jobs: | |
| release: | |
| runs-on: ubuntu-latest | |
| concurrency: | |
| group: ${{ github.workflow }}-release-${{ github.ref_name }} | |
| cancel-in-progress: false | |
| steps: | |
| - name: Run deployment | |
| shell: bash | |
| run: | | |
| # Use inputs if available (workflow_dispatch), otherwise use defaults for push | |
| DEPLOYMENT_ENV="${{ inputs.BEC_DEPLOYMENT_ENVIRONMENT || 'qa' }}" | |
| ATLAS_BRANCH="${{ inputs.BEC_ATLAS_BRANCH || 'main' }}" | |
| echo "Deploying application to ${DEPLOYMENT_ENV} environment..." | |
| curl -X 'POST' \ | |
| "https://gitea.psi.ch/api/v1/repos/bec/bec_atlas_ci/actions/workflows/deploy.yml/dispatches?token=${{ secrets.CI_DEPLOY_GITEA }}" \ | |
| -H 'accept: application/json' \ | |
| -H 'Content-Type: application/json' \ | |
| -d "{ | |
| \"inputs\": { | |
| \"ATLAS_SERVER\": \"${DEPLOYMENT_ENV}\", | |
| \"BEC_ATLAS_BRANCH\": \"${ATLAS_BRANCH}\" | |
| }, | |
| \"ref\": \"refs/heads/main\" | |
| }" |