Update README #1
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: CI/CD Pipeline | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| build-users-service: | |
| name: Build Users Service (Java) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up JDK 21 | |
| uses: actions/setup-java@v4 | |
| with: | |
| java-version: '21' | |
| distribution: 'temurin' | |
| - name: Build with Maven | |
| run: | | |
| cd services/users-java | |
| mvn clean package -DskipTests | |
| - name: Test with Maven | |
| run: | | |
| cd services/users-java | |
| mvn test | |
| - name: Docker Build | |
| run: | | |
| cd services/users-java | |
| docker build -t lmra-users-service:latest . | |
| build-tickets-service: | |
| name: Build Tickets Service (C#) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up .NET 8 | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '8.0.x' | |
| - name: Restore dependencies | |
| run: dotnet restore services/tickets-dotnet/TicketsService.csproj | |
| - name: Build | |
| run: dotnet build services/tickets-dotnet/TicketsService.csproj --no-restore | |
| - name: Test | |
| run: dotnet test services/tickets-dotnet/TicketsService.csproj --no-build | |
| - name: Docker Build | |
| run: | | |
| cd services/tickets-dotnet | |
| docker build -t lmra-tickets-service:latest . | |
| build-ai-gateway: | |
| name: Build AI Gateway (Node.js) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| cache-dependency-path: services/ai-gateway-node/package-lock.json | |
| - name: Install dependencies | |
| run: | | |
| cd services/ai-gateway-node | |
| npm ci | |
| - name: Build | |
| run: | | |
| cd services/ai-gateway-node | |
| npm run build | |
| - name: Docker Build | |
| run: | | |
| cd services/ai-gateway-node | |
| docker build -t lmra-ai-gateway:latest . | |
| build-web: | |
| name: Build Web Frontend | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| cache-dependency-path: web/nextjs/package-lock.json | |
| - name: Install dependencies | |
| run: | | |
| cd web/nextjs | |
| npm ci | |
| - name: Lint | |
| run: | | |
| cd web/nextjs | |
| npm run lint | |
| - name: Build | |
| run: | | |
| cd web/nextjs | |
| npm run build | |
| - name: Docker Build | |
| run: | | |
| cd web/nextjs | |
| docker build -t lmra-web:latest . | |
| integration-test: | |
| name: Integration Tests | |
| runs-on: ubuntu-latest | |
| needs: [build-users-service, build-tickets-service, build-ai-gateway] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Run docker-compose | |
| run: docker-compose up -d | |
| - name: Wait for services | |
| run: | | |
| sleep 30 | |
| docker-compose ps | |
| - name: Health checks | |
| run: | | |
| curl -f http://localhost:8080/health | |
| curl -f http://localhost:8081/health | |
| curl -f http://localhost:8082/health | |
| curl -f http://localhost:3000 | |