Description

This page runs Udash locally, then publishes a report to it from your own Updatecli runs. Nothing is authenticated, so do not expose this setup to anyone else.

Requirement

  1. Docker and Docker Compose

  2. Updatecli, see Installation

1. Create the files

Three files in one directory:

.
├── docker-compose.yaml
├── udash
│   └── config.yaml
└── udash-front
    └── config.json
docker-compose.yaml
services:
  db:
    image: postgres:18@sha256:5a5a84b19854a9ffaa54082c166ff4ec27473a361e496e5ea167f298f2da9722
    restart: always
    environment:
      - POSTGRES_USER=udash
      - POSTGRES_PASSWORD=password
      - POSTGRES_DB=udash
    expose:
      - 5432

  server:
    image: ghcr.io/updatecli/udash:v0.20.0@sha256:e208c1b4e94ca6cd0951eafcc1e79b1a58444f9057b995369886164289c2f4c2
    command: server start
    restart: always
    environment:
      - GIN_MODE=release
    volumes:
      - "./udash/config.yaml:/home/udash/.udash/config.yaml"
    expose:
      - 8080
    labels:
      - "traefik.enable=true"
      - "traefik.http.routers.server.rule=PathPrefix(`/api/`)"
      - "traefik.http.routers.server.service=server"
      - "traefik.http.services.server.loadbalancer.server.port=8080"

  front:
    image: ghcr.io/updatecli/udash-front:v0.28.0@sha256:d94a0ac05acd1f5cf9a0af3f5cffca38d5aac238036a76cad2ca599a0d24a9be
    restart: always
    volumes:
      - "./udash-front/config.json:/usr/share/nginx/html/config.json"
    expose:
      - 80
    labels:
      - "traefik.enable=true"
      - "traefik.http.routers.front.rule=PathPrefix(`/`)"
      - "traefik.http.routers.front.service=front"
      - "traefik.http.services.front.loadbalancer.server.port=80"

  traefik:
    image: traefik:v3.7@sha256:24841fe2de7304c149343d877d2923b4c8800a38ba015dea9174c23b20e344a0
    command:
      - "--providers.docker=true"
      - "--providers.docker.exposedbydefault=false"
      - "--entrypoints.web.address=:80"
    ports:
      - "80:80"
    volumes:
      - "/var/run/docker.sock:/var/run/docker.sock:ro"
udash/config.yaml
server:
  auth:
    # No authentication: anyone reaching this instance can read and write reports.
    # Fine on a laptop, never on anything reachable from outside.
    mode: "none"

database:
  uri: postgres://udash:password@db:5432/udash?sslmode=disable
  migrationdisabled: false
udash-front/config.json
{
  "AUTH_ENABLED": false,
  "API_BASE_URL": "/api",
  "APP_BASE_PATH": "/",
  "MAX_HISTORY_DAYS": 30
}

2. Start Udash

docker compose up -d

Open http://localhost. If the page does not load, http://localhost/api/ping tells you whether the API is up.

Note

The server may restart a few times on the first start, while PostgreSQL gets ready. It recovers on its own within a few seconds.

3. Point Updatecli at it

updatecli udash login "http://localhost" --experimental

The instance has no authentication, so the command does not ask for a token. It only records the endpoint.

4. Publish a report

Run Updatecli as usual, with --experimental added:

updatecli diff --experimental

The run ends with one link per pipeline:

UDASH - EXPERIMENTAL
=====================

Publishing report to Udash
my pipeline:
	=> "http://localhost/pipeline/reports/8f2b1c94-...."
Warning

Without --experimental, nothing is published and nothing warns you. See the "Experimental features" page.

Refresh http://localhost and the report is there.

If you have no manifest at hand, a published policy works too. Put this updatecli-compose.yaml in a repository you care about:

updatecli-compose.yaml
policies:
  - name: Discover what could be updated here
    policy: ghcr.io/updatecli/policies/autodiscovery/all:0.7.0@sha256:09bd79160f4ecda4d8323b25815a733d39334c22544aaa6ac5859f0d3ef9fa79

and run updatecli compose diff --experimental. Pulling a policy may require docker login ghcr.io first.

Cleaning up

docker compose down --volumes

Go further