feat: Update docs related #1
Workflow file for this run
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
| # ============================================================================= | |
| # TelemetryFlow Uptime - Release Workflow | |
| # ============================================================================= | |
| # | |
| # TelemetryFlow Uptime - Full-Stack Monorepo (Backend + Frontend) | |
| # Copyright (c) 2024-2026 Telemetri Data Indonesia. All rights reserved. | |
| # | |
| # Produces: | |
| # - Docker images (Docker Hub + GHCR) | |
| # - Source code archives (tar.gz, zip) | |
| # - GitHub Release with checksums | |
| # | |
| # ============================================================================= | |
| name: Release - TelemetryFlow Uptime | |
| on: | |
| push: | |
| tags: | |
| - "v*.*.*" | |
| workflow_dispatch: | |
| inputs: | |
| version: | |
| description: "Version to release (e.g., 1.4.0)" | |
| required: true | |
| default: "1.4.0" | |
| prerelease: | |
| description: "Mark as pre-release" | |
| required: false | |
| type: boolean | |
| default: false | |
| env: | |
| NODE_VERSION: "22" | |
| PNPM_VERSION: "10.24.0" | |
| PRODUCT_NAME: TelemetryFlow Uptime | |
| VENDOR: Telemetri Data Indonesia | |
| MAINTAINER: support@telemetryflow.id | |
| DESCRIPTION: Full-stack Uptime Monitoring, Status Page, IAM & Alerting platform for TelemetryFlow. | |
| LICENSE: Apache-2.0 | |
| HOMEPAGE: https://telemetryflow.id | |
| REGISTRY_DOCKER: docker.io | |
| IMAGE_BACKEND: telemetryflow/telemetryflow-uptime | |
| IMAGE_FRONTEND: telemetryflow/telemetryflow-uptime-viz | |
| permissions: | |
| contents: write | |
| jobs: | |
| prepare: | |
| name: Prepare Release | |
| runs-on: ubuntu-latest | |
| outputs: | |
| version: ${{ steps.version.outputs.version }} | |
| commit: ${{ steps.version.outputs.commit }} | |
| branch: ${{ steps.version.outputs.branch }} | |
| build_time: ${{ steps.version.outputs.build_time }} | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Determine version | |
| id: version | |
| run: | | |
| if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then | |
| VERSION="${{ github.event.inputs.version }}" | |
| else | |
| VERSION="${GITHUB_REF#refs/tags/v}" | |
| fi | |
| echo "version=${VERSION}" >> $GITHUB_OUTPUT | |
| echo "commit=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT | |
| echo "branch=$(git rev-parse --abbrev-ref HEAD)" >> $GITHUB_OUTPUT | |
| echo "build_time=$(date -u '+%Y-%m-%dT%H:%M:%SZ')" >> $GITHUB_OUTPUT | |
| # =========================================================================== | |
| # Build Docker Images | |
| # =========================================================================== | |
| build-docker: | |
| name: Build Docker Images | |
| runs-on: ubuntu-latest | |
| needs: prepare | |
| strategy: | |
| matrix: | |
| include: | |
| - dockerfile: Dockerfile.backend | |
| image_env: IMAGE_BACKEND | |
| component: uptime-backend | |
| description: NestJS backend for TelemetryFlow Uptime | |
| - dockerfile: Dockerfile.frontend | |
| image_env: IMAGE_FRONTEND | |
| component: uptime-viz | |
| description: Vue 3 frontend for TelemetryFlow Uptime | |
| steps: | |
| - name: Free up disk space | |
| run: | | |
| sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/ghc | |
| sudo rm -rf /opt/hostedtoolcache/CodeQL /usr/local/share/boost /usr/share/swift | |
| sudo apt-get clean | |
| docker system prune -af --volumes || true | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up QEMU | |
| uses: docker/setup-qemu-action@v4 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Login to Docker Hub | |
| if: vars.DOCKERHUB_USERNAME != '' | |
| uses: docker/login-action@v3 | |
| with: | |
| registry: ${{ env.REGISTRY_DOCKER }} | |
| username: ${{ vars.DOCKERHUB_USERNAME }} | |
| password: ${{ secrets.DOCKERHUB_TOKEN }} | |
| - name: Docker meta | |
| id: meta | |
| uses: docker/metadata-action@v5 | |
| with: | |
| images: | | |
| ${{ env.REGISTRY_DOCKER }}/${{ env[matrix.image_env] }} | |
| flavor: | | |
| latest=false | |
| tags: | | |
| type=semver,pattern={{version}} | |
| type=semver,pattern={{major}}.{{minor}} | |
| type=semver,pattern={{major}} | |
| type=raw,value=${{ needs.prepare.outputs.version }},enable=${{ github.event_name == 'workflow_dispatch' }} | |
| type=raw,value=latest,enable=true | |
| labels: | | |
| org.opencontainers.image.title=${{ env.PRODUCT_NAME }} | |
| org.opencontainers.image.description=${{ matrix.description }} | |
| org.opencontainers.image.vendor=TelemetryFlow | |
| org.opencontainers.image.licenses=${{ env.LICENSE }} | |
| org.opencontainers.image.url=${{ env.HOMEPAGE }} | |
| io.telemetryflow.product=${{ env.PRODUCT_NAME }} | |
| io.telemetryflow.component=${{ matrix.component }} | |
| - name: Build and push Docker image | |
| uses: docker/build-push-action@v7 | |
| with: | |
| context: . | |
| file: ./${{ matrix.dockerfile }} | |
| platforms: linux/amd64,linux/arm64 | |
| push: true | |
| tags: ${{ steps.meta.outputs.tags }} | |
| labels: ${{ steps.meta.outputs.labels }} | |
| build-args: | | |
| VERSION=${{ needs.prepare.outputs.version }} | |
| GIT_COMMIT=${{ needs.prepare.outputs.commit }} | |
| GIT_BRANCH=${{ needs.prepare.outputs.branch }} | |
| BUILD_TIME=${{ needs.prepare.outputs.build_time }} | |
| cache-from: type=gha,scope=${{ matrix.component }} | |
| cache-to: type=gha,scope=${{ matrix.component }},mode=max | |
| provenance: true | |
| sbom: true | |
| # =========================================================================== | |
| # Create Source Archives | |
| # =========================================================================== | |
| build-source: | |
| name: Create Source Archives | |
| runs-on: ubuntu-latest | |
| needs: prepare | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: ${{ env.NODE_VERSION }} | |
| - name: Install pnpm | |
| uses: pnpm/action-setup@v6 | |
| with: | |
| version: ${{ env.PNPM_VERSION }} | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Build monorepo | |
| run: pnpm build | |
| - name: Create source archive | |
| env: | |
| VERSION: ${{ needs.prepare.outputs.version }} | |
| run: | | |
| ARCHIVE_NAME="telemetryflow-uptime-${VERSION}-source" | |
| mkdir -p "${ARCHIVE_NAME}" | |
| cp -r backend/dist "${ARCHIVE_NAME}/backend-dist/" | |
| cp -r frontend/dist "${ARCHIVE_NAME}/frontend-dist/" | |
| cp -r backend/src "${ARCHIVE_NAME}/backend-src/" | |
| cp -r frontend/src "${ARCHIVE_NAME}/frontend-src/" | |
| cp -r config "${ARCHIVE_NAME}/" | |
| cp -r docs "${ARCHIVE_NAME}/" | |
| cp -r scripts "${ARCHIVE_NAME}/" | |
| cp -r .github "${ARCHIVE_NAME}/" | |
| cp backend/package.json "${ARCHIVE_NAME}/backend-package.json" | |
| cp frontend/package.json "${ARCHIVE_NAME}/frontend-package.json" | |
| cp package.json pnpm-lock.yaml pnpm-workspace.yaml turbo.json "${ARCHIVE_NAME}/" | |
| cp tsconfig.json .env.example docker-compose.yml Dockerfile "${ARCHIVE_NAME}/" 2>/dev/null || true | |
| cp README.md LICENSE CHANGELOG.md CONTRIBUTING.md SECURITY.md "${ARCHIVE_NAME}/" 2>/dev/null || true | |
| cat > "${ARCHIVE_NAME}/install.sh" << 'EOF' | |
| #!/bin/bash | |
| set -e | |
| echo "Installing TelemetryFlow Uptime..." | |
| if ! command -v node &> /dev/null; then | |
| echo "Error: Node.js 22+ is required." | |
| exit 1 | |
| fi | |
| if ! command -v pnpm &> /dev/null; then | |
| npm install -g pnpm | |
| fi | |
| pnpm install --frozen-lockfile | |
| if [ ! -f ".env" ]; then | |
| cp .env.example .env | |
| node scripts/generate-secrets.js --env >> .env | |
| fi | |
| echo "" | |
| echo "Next steps:" | |
| echo "1. Edit .env with your database settings" | |
| echo "2. docker-compose --profile uptime up -d" | |
| echo "3. pnpm db:fresh" | |
| echo "4. pnpm dev" | |
| EOF | |
| chmod +x "${ARCHIVE_NAME}/install.sh" | |
| tar -czf "${ARCHIVE_NAME}.tar.gz" "${ARCHIVE_NAME}" | |
| zip -r "${ARCHIVE_NAME}.zip" "${ARCHIVE_NAME}" | |
| - name: Upload source artifacts | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: source-archives | |
| path: | | |
| telemetryflow-uptime-*.tar.gz | |
| telemetryflow-uptime-*.zip | |
| retention-days: 1 | |
| # =========================================================================== | |
| # Create GitHub Release | |
| # =========================================================================== | |
| release: | |
| name: Create Release | |
| runs-on: ubuntu-latest | |
| needs: | |
| - prepare | |
| - build-docker | |
| - build-source | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Download source archives | |
| uses: actions/download-artifact@v7 | |
| with: | |
| name: source-archives | |
| path: release/ | |
| - name: Generate checksums | |
| run: | | |
| cd release | |
| sha256sum * > checksums-sha256.txt | |
| cat checksums-sha256.txt | |
| - name: Create tag if not exists (workflow_dispatch) | |
| if: github.event_name == 'workflow_dispatch' | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| TAG_NAME="v${{ needs.prepare.outputs.version }}" | |
| if ! git rev-parse "$TAG_NAME" >/dev/null 2>&1; then | |
| git tag -a "$TAG_NAME" -m "Release $TAG_NAME" | |
| git push origin "$TAG_NAME" | |
| fi | |
| - name: Create Release | |
| uses: softprops/action-gh-release@v3 | |
| with: | |
| name: "${{ env.PRODUCT_NAME }} v${{ needs.prepare.outputs.version }}" | |
| tag_name: "v${{ needs.prepare.outputs.version }}" | |
| draft: false | |
| prerelease: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.prerelease == 'true' }} | |
| generate_release_notes: true | |
| files: | | |
| release/* | |
| body: | | |
| ## ${{ env.PRODUCT_NAME }} v${{ needs.prepare.outputs.version }} | |
| ### Core Features | |
| - **15 Modules**: IAM, Auth, SSO, API Keys, Audit, Tenancy, Alerting, Query, LLM, Notification, Data Masking, Cache, Retention, Uptime Monitoring, Status Pages | |
| - **Full-Stack Monorepo**: NestJS backend + Vue 3 frontend | |
| - **5-Tier RBAC**: Super Admin, Administrator, Developer, Viewer, Demo | |
| - **Multi-tenant**: Tenant → Organization → Workspace hierarchy | |
| - **DDD + CQRS**: Clean architecture with domain-driven design | |
| - **AI Assistant**: Multi-provider LLM support | |
| - **Alerting Engine**: TFQL-based alert rules | |
| - **Retention Policies**: Configurable data retention management | |
| ### Technology Stack | |
| | Component | Technology | | |
| |-----------|-----------| | |
| | Backend | NestJS 11.x + TypeScript 5.9 | | |
| | Frontend | Vue 3 + Vite | | |
| | Databases | PostgreSQL 16 + ClickHouse | | |
| | Cache | Redis 7 | | |
| | Messaging | NATS JetStream | | |
| | Queues | BullMQ | | |
| ### Docker Images | |
| ```bash | |
| # Backend | |
| docker pull telemetryflow/telemetryflow-uptime:${{ needs.prepare.outputs.version }} | |
| docker pull telemetryflow/telemetryflow-uptime:latest | |
| # Frontend | |
| docker pull telemetryflow/telemetryflow-uptime-viz:${{ needs.prepare.outputs.version }} | |
| docker pull telemetryflow/telemetryflow-uptime-viz:latest | |
| ``` | |
| ### Quick Start | |
| ```bash | |
| # Using Docker Compose | |
| docker-compose --profile uptime up -d | |
| # From source | |
| pnpm install | |
| cp .env.example .env | |
| pnpm db:fresh | |
| pnpm dev | |
| ``` | |
| ### Default Users | |
| | Email | Password | Role | | |
| |-------|----------|------| | |
| | superadmin.telemetryflow@telemetryflow.id | SuperAdmin@123456 | Super Administrator | | |
| | administrator.telemetryflow@telemetryflow.id | Admin@123456 | Administrator | | |
| | developer.telemetryflow@telemetryflow.id | Developer@123456 | Developer | | |
| | viewer.telemetryflow@telemetryflow.id | Viewer@123456 | Viewer | | |
| | demo.telemetryflow@telemetryflow.id | Demo@123456 | Demo | | |
| ### API Documentation | |
| Swagger UI: `http://localhost:3000/api` | |
| # =========================================================================== | |
| # Summary | |
| # =========================================================================== | |
| summary: | |
| name: Release Summary | |
| runs-on: ubuntu-latest | |
| needs: | |
| - prepare | |
| - build-docker | |
| - build-source | |
| - release | |
| if: always() | |
| steps: | |
| - name: Summary | |
| run: | | |
| echo "## ${{ env.PRODUCT_NAME }} - Release Summary" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "| Item | Value |" >> $GITHUB_STEP_SUMMARY | |
| echo "|------|-------|" >> $GITHUB_STEP_SUMMARY | |
| echo "| **Version** | v${{ needs.prepare.outputs.version }} |" >> $GITHUB_STEP_SUMMARY | |
| echo "| **Commit** | ${{ needs.prepare.outputs.commit }} |" >> $GITHUB_STEP_SUMMARY | |
| echo "| **Branch** | ${{ needs.prepare.outputs.branch }} |" >> $GITHUB_STEP_SUMMARY | |
| echo "| **Build Time** | ${{ needs.prepare.outputs.build_time }} |" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "### Build Status" >> $GITHUB_STEP_SUMMARY | |
| echo "| Type | Status |" >> $GITHUB_STEP_SUMMARY | |
| echo "|------|--------|" >> $GITHUB_STEP_SUMMARY | |
| echo "| Docker Images | ${{ needs.build-docker.result }} |" >> $GITHUB_STEP_SUMMARY | |
| echo "| Source Archives | ${{ needs.build-source.result }} |" >> $GITHUB_STEP_SUMMARY | |
| echo "| GitHub Release | ${{ needs.release.result }} |" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "### Docker Images" >> $GITHUB_STEP_SUMMARY | |
| echo "- \`telemetryflow/telemetryflow-uptime:${{ needs.prepare.outputs.version }}\`" >> $GITHUB_STEP_SUMMARY | |
| echo "- \`telemetryflow/telemetryflow-uptime-viz:${{ needs.prepare.outputs.version }}\`" >> $GITHUB_STEP_SUMMARY |