# yaml-language-server: $schema=https://schema.zeabur.app/template.json
apiVersion: zeabur.com/v1
kind: Template
metadata:
    name: Consul
spec:
    description: |
        Consul is a service networking platform by HashiCorp for service discovery, health checking, KV store, and multi-datacenter support. Includes a built-in web UI for browsing services, nodes, KV data, and ACL management. Single binary with embedded Raft storage — no external database required.
    coverImage: https://raw.githubusercontent.com/hashicorp/consul/main/.doc/screenshot.png
    icon: https://avatars.githubusercontent.com/u/761456
    variables:
        - key: PUBLIC_DOMAIN
          type: DOMAIN
          name: Domain
          description: The domain to access Consul UI
    tags:
        - Tool
        - DevOps
    readme: |
        # Consul

        A service networking platform by HashiCorp providing service discovery, health checking, distributed KV store, and multi-datacenter federation. Ships as a single binary with embedded Raft storage.

        ## What You Can Do After Deployment

        1. **Visit your domain** — the Consul web UI loads immediately, no login required in dev mode
        2. **Browse services** — view all registered services and their health status
        3. **Explore nodes** — inspect node metadata, health checks, and coordinates
        4. **Use the KV store** — create, read, update, and delete key-value pairs directly from the UI
        5. **Register services** — use the HTTP API to register services: `curl -X PUT -d '{"Name":"web","Port":8080}' https://YOUR_DOMAIN/v1/agent/service/register`
        6. **Query DNS** — Consul provides DNS interface for service discovery
        7. **Health checking** — define HTTP, TCP, script, or TTL-based health checks

        ## Key Features

        - Service discovery with DNS and HTTP interfaces
        - Distributed KV store with blocking queries
        - Health checking for services and nodes
        - Multi-datacenter federation
        - ACL system for access control
        - Prepared queries for advanced service routing
        - Snapshot and restore for disaster recovery

        ## License

        BUSL-1.1 — [GitHub](https://github.com/hashicorp/consul)
    services:
        - name: consul
          icon: https://avatars.githubusercontent.com/u/761456
          template: PREBUILT_V2
          spec:
            source:
                image: hashicorp/consul:1.22.6
                command:
                    - consul
                    - agent
                    - -dev
                    - -client=0.0.0.0
                    - -ui
            ports:
                - id: web
                  port: 8500
                  type: HTTP
            volumes:
                - id: consul-data
                  dir: /consul/data
            env:
                TZ:
                    default: UTC
            healthCheck:
                type: HTTP
                port: web
                http:
                    path: /v1/status/leader
          domainKey: PUBLIC_DOMAIN
localization:
    es-ES:
        description: |
            Consul es una plataforma de red de servicios de HashiCorp para descubrimiento de servicios, verificacion de salud, almacen KV distribuido y soporte multi-datacenter. Incluye interfaz web, sin base de datos externa necesaria.
        variables:
            - key: PUBLIC_DOMAIN
              type: STRING
              name: Dominio
              description: El dominio para acceder a Consul UI
        readme: |
            # Consul

            Plataforma de red de servicios de HashiCorp. Descubrimiento de servicios, verificacion de salud, almacen KV distribuido y federacion multi-datacenter.

            ## Que puedes hacer despues del despliegue

            1. **Visita tu dominio** — la interfaz web de Consul se carga directamente (sin login en modo desarrollo)
            2. **Explora servicios** — revisa servicios registrados y su estado
            3. **Explora nodos** — inspecciona metadatos, verificaciones de salud y coordenadas
            4. **Almacen KV** — crea, lee, actualiza y elimina pares clave-valor desde la UI
            5. **Registra servicios** — usa la API HTTP para registrar servicios
            6. **Consultas DNS** — interfaz DNS para descubrimiento de servicios

            ## Licencia

            BUSL-1.1 — [GitHub](https://github.com/hashicorp/consul)
    id-ID:
        description: |
            Consul adalah platform jaringan layanan dari HashiCorp untuk service discovery, health checking, KV store terdistribusi, dan dukungan multi-datacenter. Dilengkapi web UI bawaan, tanpa perlu database eksternal.
        variables:
            - key: PUBLIC_DOMAIN
              type: STRING
              name: Domain
              description: Domain untuk mengakses Consul UI
        readme: |
            # Consul

            Platform jaringan layanan dari HashiCorp. Service discovery, health checking, KV store terdistribusi, dan federasi multi-datacenter.

            ## Apa yang bisa dilakukan setelah deploy

            1. **Buka domain** — Web UI Consul langsung tampil (mode development tanpa login)
            2. **Jelajahi layanan** — lihat semua layanan terdaftar dan status kesehatannya
            3. **Jelajahi node** — periksa metadata node, health check, dan koordinat
            4. **KV store** — buat, baca, perbarui, dan hapus pasangan key-value langsung dari UI
            5. **Daftarkan layanan** — gunakan HTTP API untuk mendaftarkan layanan
            6. **Query DNS** — antarmuka DNS untuk service discovery

            ## Lisensi

            BUSL-1.1 — [GitHub](https://github.com/hashicorp/consul)
    ja-JP:
        description: |
            Consul は HashiCorp のサービスネットワーキングプラットフォームです。サービスディスカバリ、ヘルスチェック、分散 KV ストア、マルチデータセンター対応を提供。Web UI 内蔵、外部データベース不要。
        variables:
            - key: PUBLIC_DOMAIN
              type: STRING
              name: ドメイン
              description: Consul UI にアクセスするためのドメイン
        readme: |
            # Consul

            HashiCorp のサービスネットワーキングプラットフォーム。サービスディスカバリ、ヘルスチェック、分散 KV ストア、マルチデータセンター対応。

            ## デプロイ後にできること

            1. **ドメインにアクセス** — Consul Web UI がすぐに表示されます（開発モードではログイン不要）
            2. **サービスの閲覧** — 登録済みサービスとヘルスステータスの確認
            3. **ノードの探索** — ノードメタデータ、ヘルスチェック、座標の確認
            4. **KV ストア** — UI から直接キー・バリューの作成、読み取り、更新、削除
            5. **サービス登録** — HTTP API でサービスを登録
            6. **DNS クエリ** — DNS インターフェースでサービスディスカバリ

            ## ライセンス

            BUSL-1.1 — [GitHub](https://github.com/hashicorp/consul)
    ko-KR:
        description: |
            Consul은 HashiCorp의 서비스 네트워킹 플랫폼으로, 서비스 디스커버리, 헬스 체크, 분산 KV 스토어, 멀티 데이터센터를 지원합니다. Web UI 내장, 외부 데이터베이스 불필요.
        variables:
            - key: PUBLIC_DOMAIN
              type: STRING
              name: 도메인
              description: Consul UI에 접속할 도메인
        readme: |
            # Consul

            HashiCorp의 서비스 네트워킹 플랫폼. 서비스 디스커버리, 헬스 체크, 분산 KV 스토어, 멀티 데이터센터 연합.

            ## 배포 후 할 수 있는 것

            1. **도메인 접속** — Consul Web UI가 바로 로드됩니다 (개발 모드에서는 로그인 불필요)
            2. **서비스 탐색** — 등록된 서비스와 상태 확인
            3. **노드 탐색** — 노드 메타데이터, 헬스 체크, 좌표 확인
            4. **KV 스토어** — UI에서 직접 키-값 쌍 생성, 읽기, 수정, 삭제
            5. **서비스 등록** — HTTP API로 서비스 등록
            6. **DNS 쿼리** — DNS 인터페이스로 서비스 디스커버리

            ## 라이선스

            BUSL-1.1 — [GitHub](https://github.com/hashicorp/consul)
    th-TH:
        description: |
            Consul เป็นแพลตฟอร์มเครือข่ายบริการจาก HashiCorp สำหรับ service discovery, health checking, KV store แบบกระจาย และรองรับ multi-datacenter มี Web UI ในตัว ไม่ต้องการฐานข้อมูลภายนอก
        variables:
            - key: PUBLIC_DOMAIN
              type: STRING
              name: โดเมน
              description: โดเมนสำหรับเข้าถึง Consul UI
        readme: |
            # Consul

            แพลตฟอร์มเครือข่ายบริการจาก HashiCorp สำหรับ service discovery, health checking, KV store แบบกระจาย และ multi-datacenter federation

            ## สิ่งที่ทำได้หลังจากติดตั้ง

            1. **เข้าสู่โดเมน** — Web UI ของ Consul โหลดทันที (โหมด development ไม่ต้องเข้าสู่ระบบ)
            2. **สำรวจบริการ** — ดูบริการที่ลงทะเบียนทั้งหมดและสถานะ
            3. **สำรวจโหนด** — ตรวจสอบ metadata ของโหนด, health check และพิกัด
            4. **KV store** — สร้าง อ่าน อัปเดต และลบ key-value pairs จาก UI โดยตรง
            5. **ลงทะเบียนบริการ** — ใช้ HTTP API ลงทะเบียนบริการ
            6. **DNS query** — อินเทอร์เฟซ DNS สำหรับ service discovery

            ## สัญญาอนุญาต

            BUSL-1.1 — [GitHub](https://github.com/hashicorp/consul)
    zh-CN:
        description: |
            Consul 是 HashiCorp 的服务网络平台，提供服务发现、健康检查、分布式 KV 存储与多数据中心支持。内置 Web UI 可浏览服务、节点与 KV 数据。单一二进制文件，内嵌 Raft 存储，无需外部数据库。
        variables:
            - key: PUBLIC_DOMAIN
              type: STRING
              name: 域名
              description: 访问 Consul UI 的域名
        readme: |
            # Consul

            HashiCorp 的服务网络平台，提供服务发现、健康检查、分布式 KV 存储与多数据中心联邦。单一二进制文件，内嵌 Raft 存储。

            ## 部署后可以做什么

            1. **打开域名** — Consul Web UI 直接加载，开发模式无需登录
            2. **浏览服务** — 查看所有已注册的服务及健康状态
            3. **探索节点** — 检查节点元数据、健康检查与坐标
            4. **使用 KV 存储** — 直接在 UI 中创建、读取、更新和删除键值对
            5. **注册服务** — 通过 HTTP API 注册服务
            6. **DNS 查询** — Consul 提供 DNS 接口进行服务发现

            ## 授权

            BUSL-1.1 — [GitHub](https://github.com/hashicorp/consul)
    zh-TW:
        description: |
            Consul 是 HashiCorp 的服務網路平台，提供服務發現、健康檢查、分散式 KV 儲存與多資料中心支援。內建 Web UI 可瀏覽服務、節點與 KV 資料。單一執行檔，內嵌 Raft 儲存，不需要外部資料庫。
        variables:
            - key: PUBLIC_DOMAIN
              type: STRING
              name: 網域
              description: 存取 Consul UI 的網域
        readme: |
            # Consul

            HashiCorp 的服務網路平台，提供服務發現、健康檢查、分散式 KV 儲存與多資料中心聯邦。單一執行檔，內嵌 Raft 儲存。

            ## 部署後可以做什麼

            1. **開啟網域** — Consul Web UI 直接載入，開發模式無需登入
            2. **瀏覽服務** — 查看所有已註冊的服務及健康狀態
            3. **探索節點** — 檢視節點的後設資料、健康檢查與座標
            4. **使用 KV 儲存** — 直接在 UI 中建立、讀取、更新和刪除鍵值對
            5. **註冊服務** — 透過 HTTP API 註冊服務
            6. **DNS 查詢** — Consul 提供 DNS 介面進行服務發現
            7. **健康檢查** — 定義 HTTP、TCP、Script 或 TTL 類型的健康檢查

            ## 主要功能

            - 透過 DNS 和 HTTP 介面進行服務發現
            - 分散式 KV 儲存，支援阻塞查詢
            - 服務與節點的健康檢查
            - 多資料中心聯邦
            - ACL 存取控制系統
            - 快照備份與還原

            ## 授權

            BUSL-1.1 — [GitHub](https://github.com/hashicorp/consul)
