revert(api-docs): remove all visual customization from api-docs #5
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: Docker Build and Publish — API Docs | |
| on: | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - "apps/api-docs/**" | |
| - "libs/flowdrop/api/**" | |
| - ".github/workflows/docker-publish-api-docs.yml" | |
| env: | |
| REGISTRY: ghcr.io | |
| IMAGE_NAME: flowdrop-io/flowdrop-api-docs | |
| jobs: | |
| build-and-push: | |
| name: Build Docker image | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| packages: write | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Log in to Container Registry | |
| uses: docker/login-action@v3 | |
| with: | |
| registry: ${{ env.REGISTRY }} | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Extract image metadata | |
| id: meta | |
| uses: docker/metadata-action@v5 | |
| with: | |
| images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} | |
| tags: | | |
| type=sha,prefix=sha- | |
| type=raw,value=latest,enable={{is_default_branch}} | |
| - name: Build and push | |
| # Build context is repo root — Dockerfile copies libs/flowdrop/api/ at build time | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| file: apps/api-docs/Dockerfile | |
| push: true | |
| tags: ${{ steps.meta.outputs.tags }} | |
| labels: ${{ steps.meta.outputs.labels }} | |
| cache-from: type=gha | |
| cache-to: type=gha,mode=max | |
| trigger-deploy: | |
| name: Trigger GitLab deployment | |
| needs: build-and-push | |
| runs-on: ubuntu-latest | |
| if: success() && github.ref == 'refs/heads/main' | |
| steps: | |
| - name: Trigger GitLab pipeline | |
| run: | | |
| curl --fail -X POST \ | |
| "https://source.factorial.io/api/v4/projects/1074/trigger/pipeline" \ | |
| -F "token=${{ secrets.GITLAB_TRIGGER_TOKEN }}" \ | |
| -F "ref=main" |