Skip to content

feat(member): add distinct filter values for all searchable fields #79

feat(member): add distinct filter values for all searchable fields

feat(member): add distinct filter values for all searchable fields #79

Workflow file for this run

name: CI/CD
on:
push:
branches: [main]
concurrency:
group: deploy-production
cancel-in-progress: false
jobs:
lint:
runs-on: ubuntu-latest
permissions:
checks: write
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.12"
cache: "pip"
cache-dependency-path: pyproject.toml
- run: cp .env.example .env
- run: pip install -e ".[dev]" pyright
- run: pyright src/
test:
runs-on: ubuntu-latest
permissions:
checks: write
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.12"
cache: "pip"
cache-dependency-path: pyproject.toml
- run: cp .env.example .env
- run: pip install -e ".[dev]"
- run: pytest -v --junitxml=test-results.xml || [ $? -eq 5 ]
- uses: EnricoMi/publish-unit-test-result-action@v2.23.0
if: always()
with:
files: test-results.xml
deploy:
needs: [lint, test]
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout credentials
uses: actions/checkout@v6
with:
repository: BCSDLab/bcsdlab-credentials
ssh-key: ${{ secrets.CONFIG_REPO_PEM_KEY }}
path: credentials
persist-credentials: false
- name: Upload credentials to server
uses: appleboy/scp-action@v1
with:
host: ${{ secrets.SERVER_HOST }}
username: ${{ secrets.SERVER_USER }}
key: ${{ secrets.SERVER_SSH_KEY }}
port: ${{ secrets.SERVER_PORT }}
source: "credentials/bcsd-api/backend/*"
target: "~/BCSD_API"
strip_components: 3
- name: Clean up credentials from runner
if: always()
run: rm -rf credentials
- name: Deploy
uses: appleboy/ssh-action@v1
with:
host: ${{ secrets.SERVER_HOST }}
username: ${{ secrets.SERVER_USER }}
key: ${{ secrets.SERVER_SSH_KEY }}
port: ${{ secrets.SERVER_PORT }}
script: |
cd ~/BCSD_API
git fetch origin main
git reset --hard origin/main
bash infra/scripts/deploy.sh