Initial DevOpsDash — FastAPI + Alpine.js dashboard for DevOpsMCP
Some checks failed
Build and push DevOpsDash / build (push) Has been cancelled
Some checks failed
Build and push DevOpsDash / build (push) Has been cancelled
- Taskz kanban board (create/edit tasks, findings, status/priority) - Worklog timeline + standup summary (proxied from DevOpsMCP MCP API) - Knowledge browser (ADRs, memories, knowledge catalog files) - FastAPI backend reading same Redis as DevOpsMCP - Read-only bind-mount for DevOpsMCP data directory (/data) - Nomad job spec (dash.i80.dk, Traefik TLS, host volume read-only) - Gitea Actions CI → registry.i80.dk/gitea/devops-dash:latest
This commit is contained in:
39
app/routers/worklog.py
Normal file
39
app/routers/worklog.py
Normal file
@@ -0,0 +1,39 @@
|
||||
"""Worklog router — proxies worklog/standup calls to DevOpsMCP."""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
from typing import Optional
|
||||
|
||||
from fastapi import APIRouter, HTTPException
|
||||
|
||||
from app import mcp_client
|
||||
|
||||
router = APIRouter(prefix="/api/v1", tags=["worklog"])
|
||||
|
||||
|
||||
@router.get("/worklog")
|
||||
async def api_worklog(
|
||||
context: str = "egmont",
|
||||
days: int = 7,
|
||||
group_by: str = "repo",
|
||||
since_date: Optional[str] = None,
|
||||
until_date: Optional[str] = None,
|
||||
):
|
||||
try:
|
||||
return await mcp_client.get_worklog(
|
||||
context=context,
|
||||
days=days,
|
||||
group_by=group_by,
|
||||
since_date=since_date,
|
||||
until_date=until_date,
|
||||
)
|
||||
except Exception as exc:
|
||||
raise HTTPException(status_code=502, detail=f"DevOpsMCP error: {exc}") from exc
|
||||
|
||||
|
||||
@router.get("/standup")
|
||||
async def api_standup(days: int = 2, context: str = "egmont"):
|
||||
try:
|
||||
return await mcp_client.get_standup(days=days, context=context)
|
||||
except Exception as exc:
|
||||
raise HTTPException(status_code=502, detail=f"DevOpsMCP error: {exc}") from exc
|
||||
Reference in New Issue
Block a user