FFDB Docs

Quickstart

Install a verified packaged release, bootstrap a project, and make one authenticated parameterized query.

Install the local evaluation profile

This signed release starts FFDB, PostgreSQL, MinIO, Mailpit, the workers, and the compiled gateway on one loopback-only host. It is the fastest path to a working local instance; use the Docker or systemd installation guide for customization and internet production.

Terminalsh
curl -fsSLo ffdb-install.sh \
  https://github.com/Forever-Frameworks-LLC/ffdb/releases/latest/download/install.sh
less ffdb-install.sh
sudo sh ffdb-install.sh --profile single-host --start --require-signature

Verify the gateway

Port 5173 is the compiled nginx gateway, not a Vite development server. It serves the production portal and proxies API requests to Axum on the private Compose network; the packaged profile does not publish Axum port 8080 to the host.

Terminalsh
sudo ffdb-host status
curl --fail http://127.0.0.1:5173/readyz
# Open http://127.0.0.1:5173/app/ in a trusted browser

Create the owner and first project

The installer writes independent secrets to the root-only /etc/ffdb/single-host.env file and never prints them. Copy the one-time bootstrap token into a protected file, then use the portal to create the owner, choose the instance mode, create an organization, and create a project.

  • Open http://127.0.0.1:5173/app/ and paste the protected token.
  • Create the first owner and select private, team, Stripe BYO, or Stripe Connect operation.
  • Create an organization and project, then copy the project ID.
Copy the one-time tokensh
sudo sh -c 'umask 077; sed -n "s/^FFDB_BOOTSTRAP_TOKEN=//p" \
  /etc/ffdb/single-host.env > /root/ffdb-bootstrap-token'

Connect an application

Install the version-matched client, replace the project ID, sign in an end user, and issue the first parameterized query.

Terminalsh
npm install @ffdb/client@0.3.0
src/ffdb.tsts
import { BrowserSessionStore, FFDBClient } from "@ffdb/client";

export const ffdb = new FFDBClient({
  baseUrl: "https://ffdb.example.com",
  projectId: "your-project-id",
  sessionStore: new BrowserSessionStore(
    window.sessionStorage,
    "my-app.ffdb-session",
  ),
});
First queryts
const result = await ffdb.query({
  sql: "select id, title from documents where title like ?1 order by title",
  parameters: [{ type: "text", value: search + "%" }],
  options: { max_rows: 100 },
});

for (const row of result.rows) {
  console.log(row[0], row[1]);
}