Getting started

Version 1 · Updated

Getting started

Run the stack, sign in, push a repository, get a graph and a review.

This runs the whole platform on your machine with Docker Compose, signs you in, and pushes a first repository.

1. Start the stack#

cd deploy/compose
cp .env.example .env        # dummy dev secrets and passwords; set POSTGRES_PORT if 5432 is taken
docker compose up -d --build --wait
cd ../..
scripts/dev-setup           # Keycloak service account; signs in admin, alice and bob once
scripts/demo-seed           # demo/invoices: a TypeScript app and a C# API, with a change to review
AddressWhat
http://127.0.0.1:3300The web app (use 127.0.0.1, not localhost: sign-in is configured for it)
http://127.0.0.1:3001The API
http://127.0.0.1:8080git over HTTP
ssh://git@127.0.0.1:2222git over SSH
http://127.0.0.1:8180Keycloak (sign-in)

The dev users are admin (a site admin), alice and bob. Their passwords are in deploy/compose/.env (DEV_ADMIN_PASSWORD and so on).

2. Sign in and look around#

Open the web app and choose Sign in at the bottom of the sidebar. As admin, open demo/invoices:

  • Code: browse files at any branch.
  • Changes → Add invoice creation: the seeded change's Graph review. It has findings (rule violations with links to the line), change maps, and the API diagram of a new endpoint called from TypeScript and served by C#.
  • Graph: the code graph of main, its architecture and its personal-data flow.

3. Push your own code#

Create a repository from the Repositories page, then push with one of:

A token over HTTP. Create a token under Tokens (in the account menu) and use it as the git password:

git remote add origin http://127.0.0.1:8080/alice/my-repo.git
git push -u origin main      # username: anything; password: the token

An SSH key. Add ~/.ssh/id_ed25519.pub under SSH keys, check the host key fingerprint shown there, then:

git remote add origin ssh://git@127.0.0.1:2222/alice/my-repo.git
git push -u origin main

The CLI (see CLI):

cd cli && go build -o bscope ./cmd/bscope
./bscope auth login            # approve in the browser
./bscope auth setup-git        # plain git now uses your token
./bscope repo create my-repo

main is protected by default. The first push creates it; after that, the push guard checks every push (see Push guard).

4. Get a graph and a review#

  • Graph of main: protected branches are indexed on every push. Open Graph to watch the build, then explore the graph.
  • Repos that need dependencies: a TypeScript or C# repository that needs them installed to type-check gets setup commands under Settings (for example pnpm install, dotnet restore).
  • A review: push a branch, open a change, and its graph review runs. It runs again on every push to the branch.

Next#