spring-petclinic/.github/workflows/pipeline.yml
2025-02-03 10:00:47 +01:00

53 lines
1.4 KiB
YAML

name: CI/CD Pipeline with Monitoring
on:
push:
branches: [ pipeline-optimization ]
pull_request:
branches: [ pipeline-optimization ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
sudo apt update
sudo apt install -y python3-dev libffi-dev libssl-dev python3-yaml
- name: Install Cython and PyYAML (Fix build)
run: |
pip install --no-cache-dir cython # Fixes "cython_sources" error
pip install --no-cache-dir "pyyaml==5.4.1" # Force compatible pre-built version
- name: Install Docker Compose
run: |
pip install --no-cache-dir docker-compose
- name: Check Docker Compose version
run: |
docker-compose version || docker compose version
- name: Run tests
run: |
echo "Running tests..."
# Add test commands here
- name: Deploy application
run: |
echo "Deploying application..."
# Add deployment commands here
- name: Monitoring setup
run: |
echo "Setting up monitoring..."
# Add monitoring tools here (e.g., Prometheus, Grafana)