Configuration

Rakiba is configured via a single rakiba.edn file in the root directory. This file defines your entire stack - server, frontend framework, database, authentication, and optional features.

Overview

The rakiba.edn file lives at the Rakiba root, not inside each project. All projects generated from the same Rakiba installation share the same configuration. After modifying rakiba.edn, run bb sync my-project to update your project’s lib space.

Core Dependencies

These libraries are always included in every Rakiba project. You don’t need to configure them:

LibraryPurposeDocumentation
TelemereStructured logging with beautiful ANSI-colored outputGitHub
ReititFast data-driven routing for RingGitHub
MalliData validation and specification schemasGitHub

Configuration Options

All available configuration keys and their options:

KeyTypeOptionsDescription
:state-managementkeyword:mount, :integrantLifecycle management for stateful components
:serverkeyword:jetty, :undertow, :http-kit, :aleph, :immutantHTTP server adapter
:frontendkeyword/nil:re-frame, :uix, :fulcro, nilFrontend framework (nil for API-only)
:databasevector:sql, :datascript, :datomic-proDatabase adapters (can include multiple)
:authvector:google, :github, :email-passwordAuthentication providers
:integrationsvector:email, :storageExternal integrations (email, S3, etc.)
:featuresvector:websockets, :clj-reload, :admin-uiOptional features to enable
:mobilevector:react-nativeMobile platform support
:aimap{:tool :opencode} or {:tool :claude}AI tooling configuration

Full Reference Example

A complete rakiba.edn with all options shown:

;; rakiba.edn
{;; State lifecycle management (required)
 :state-management :mount     ; or :integrant

 ;; Server adapter (required)
 :server :jetty               ; :jetty, :undertow, :http-kit, :aleph, :immutant

 ;; Frontend framework (use nil for API-only projects)
 :frontend :fulcro            ; :re-frame, :uix, :fulcro, or nil

 ;; Database adapters
 :database
 [;;:sql              ; next-jdbc + honeysql (combined)
  ;;:datascript       ; in-memory datalog
  ;;:datomic-pro      ; Datomic with Peer API
  ]

 ;; Authentication providers
 :auth
 [;;:google           ; Sign in with Google
  ;;:github           ; Sign in with GitHub
  ;;:email-password   ; Traditional email/password
  ]

 ;; External integrations
 :integrations
 [;;:email            ; Email sending
  ;;:storage          ; File uploads (S3, local)
  ]

 ;; Optional features
 :features
 [;;:websockets       ; real-time (via Sente)
  ;;:clj-reload       ; fast reloading
  ;;:admin-ui         ; admin dashboard
  ]

 ;; Mobile support
 :mobile
 [;;:react-native     ; iOS/Android
  ]

 ;; AI tooling
 :ai {:tool :opencode}}       ; :opencode or :claude

Configuration Examples

Minimal Configuration

The simplest possible configuration for a basic web app:

{:state-management :mount
 :server :jetty
 :frontend :re-frame}

API-Only Backend

For backend services without a ClojureScript frontend:

{:state-management :mount
 :server :http-kit
 :frontend nil
 :database [:sql]
 :auth [:email-password]}

Full-Stack with Real-time

A complete setup with WebSockets and database:

{:state-management :integrant
 :server :http-kit
 :frontend :re-frame
 :database [:sql]
 :auth [:google :github]
 :features [:websockets :clj-reload]
 :ai {:tool :opencode}}

Syncing After Changes

When you modify rakiba.edn, your existing projects need to be updated to reflect the changes. Run the sync command to update a project’s lib space:

# From the rakiba root directory
bb sync my-project

The sync command updates the src/rakiba/lib/ directory with new framework code based on your configuration. Your application code in src/app/ is never touched.

Note: If you’ve customized any files in lib space, they’ll be backed up as .bak files before being overwritten.

Next Steps

  • Commands - Learn all available bb commands
  • Frontend - Detailed frontend framework comparison
  • Servers - Server options and benchmarks