Initial implementation of mcq — document reading queue
Single-binary service: push raw markdown via REST/gRPC API, read rendered HTML through mobile-friendly web UI. MCIAS auth on all endpoints, SQLite storage, goldmark rendering with GFM and syntax highlighting. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
20
internal/grpcserver/admin.go
Normal file
20
internal/grpcserver/admin.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package grpcserver
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
pb "git.wntrmute.dev/mc/mcq/gen/mcq/v1"
|
||||
"git.wntrmute.dev/mc/mcq/internal/db"
|
||||
)
|
||||
|
||||
type adminService struct {
|
||||
pb.UnimplementedAdminServiceServer
|
||||
db *db.DB
|
||||
}
|
||||
|
||||
func (s *adminService) Health(_ context.Context, _ *pb.HealthRequest) (*pb.HealthResponse, error) {
|
||||
if err := s.db.Ping(); err != nil {
|
||||
return &pb.HealthResponse{Status: "unhealthy"}, nil
|
||||
}
|
||||
return &pb.HealthResponse{Status: "ok"}, nil
|
||||
}
|
||||
Reference in New Issue
Block a user