How aisflow/focalboard-ko works
Project Type and Purpose
• Focalboard is an open source, self‐hosted project management tool that can serve as an alternative to products like Trello, Notion, or Asana.
• It comes in two primary editions – a “Personal Desktop” (standalone desktop app for Windows, macOS, Linux) and a “Personal Server” (multi-user server deployment).
• The README clearly outlines deployment options (including Docker, cross-platform native desktop builds) along with developer and testing instructions.
File Structure and Key Components
• The repository is organized into multiple distinct areas:
• A “server” directory that contains Golang code (API endpoints, business logic, data models, services, SQL store implementations, migration scripts, WebSocket components, etc.). This represents the backend API and business logic layer.
• A “webapp” directory that houses a complete web client built with modern frontend tooling (ESLint, Cypress for testing, multiple React/TypeScript components, styles, assets, and i18n files). This is the client-facing SPA.
• “win-wpf”, “mac”, and “linux” directories indicate native desktop clients for each platform. They package the server (with an embedded SQLite store) to run locally as a personal desktop application.
• “docker” and “docker-testing” directories include Dockerfiles and docker-compose scripts, which illustrate how the system can be containerized.
• “import” folder contains various submodules (asana, jira, nextcloud-deck, notion, todoist, trello, etc.) that support data import from other popular project management or task-tracking tools.
• Additional directories like “docs”, “experiments”, and “website” provide documentation, developer guidance, and marketing/website content.
• There is clear separation of concerns with distinct folders for backend services, frontend interfaces, platform-specific app builds, and integrations.
Main Components
A. Backend Server (Golang):
• Components: API endpoints, authentication, business logic, WebSocket communication, data persistence modules (SQL store, migrations), and integrations (import services, telemetry, notifications).
• Subdirectories: “server/api”, “server/app”, “server/model”, “server/services”, “server/ws”, “server/utils”.
B. Frontend Web Application:
• Components: SPA application that interacts with the backend API, user interface components, client-side state management, and routing.
• Directory: “webapp” with its assets, components, and tests.
C. Desktop Clients:
• Three distinct builds are provided (Windows with win-wpf, macOS, and Linux).
• These apps package the server in a desktop context likely using an embedded database (SQLite).
D. Database / Data Store:
• Implemented via SQL store modules (under “server/services/store/sqlstore”) and migrations.
• Represents the persistence layer for both server and desktop deployments.
E. Integration / Import Services:
• Submodules under “import” allow syncing data from asana, jira, nextcloud, etc.
• These components interact with the backend to import data.
F. Docker and Deployment Infrastructure:
• Dockerfiles and Compose files (both in “docker” and “docker-testing”) show containerized builds, deployment strategies, and configuration details.
G. Documentation & Testing:
• “docs” and CI/CD workflows (in “.github/workflows” and “Makefile” scripts) support continuous integration and guidance for contributors.
Relationships and Data Flow
• The web client (in “webapp”) communicates with the backend server via REST API calls (and possibly via WebSockets from “server/ws”).
• Desktop apps also embed a version of the backend server to operate in a standalone mode with local data persistence.
• The backend exposes an API that serves data to both the web app and desktop apps.
• Import modules feed data into the system by interfacing with the backend’s import endpoints.
• Docker and CI/CD pipelines manage automated builds, tests, and deployments of both the server and web application.
• External integrations such as telemetry and notifications (under “server/services/telemetry” and “server/services/notify”) communicate with external services if needed.
Architectural Patterns / Design Principles
• Clear separation between client and server responsibilities (MVC or similar separation within the server).
• Use of micro-modules within the server (divided into API, app logic, services, models, and websockets) to encapsulate functionality.
• Multi-platform design: code is separated for desktop (native UI) and web app interfaces.
• Containerization for easier deployment and testing.
• Extensible design (via the “import” modules and plugin/delivery service structures).