Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
b6fd174
updated concurrently dependency to version 8.2.2 in package.json and …
Baibhab23 Nov 21, 2026
ff2b256
Chore: restore concurrently v10 with Node 22, add .nvmrc
Baibhab23 Nov 22, 2026
9053bcb
Chore: revert .nvmrc and package-lock.json changes
Baibhab23 Nov 23, 2026
da10fee
updatec README.md to enhance project documentation and clarify envir…
Baibhab23 Nov 23, 2026
5e4d8c2
Docs: update UI Docker build to use env-file and document full stack
Baibhab23 Nov 23, 2026
6677fd6
Chore: revert docker-compose.yml changes
Baibhab23 Nov 23, 2026
2378c9e
Chore: add .nvmrc for Node 22 to pipeline-ui
Baibhab23 Nov 23, 2026
72695f5
Feat: Dockerfile accepts ENV_FILE build arg for env-file-based builds
Baibhab23 Nov 23, 2026
cb70d84
Added running-containers.md for full stack and monitoring setup
Baibhab23 Dec 1, 2026
a01db01
updated running-containers.md and README.md
Baibhab23 Dec 1, 2026
f2614fa
improved README
Baibhab23 Dec 2, 2026
20fc35e
updated Dockerfile to properly load environment variables from specif…
Baibhab23 Dec 2, 2026
b3f24be
Added mock API setup and updated documentation for UI with mock server
Baibhab23 Dec 2, 2026
d1258db
Fix: add required fields to OpenAPI spec and wire ts-nocheck into Doc…
Baibhab23 Dec 2, 2026
d21429c
updated Docker Compose to include mock services and adjust profiles …
Baibhab23 Dec 2, 2026
b2c3f54
updated environment variable defaults in docker-compose.yml for bette…
Baibhab23 Dec 2, 2026
b7f3ff8
updated required fields in Pipeline and PipelineBuild schemas
Baibhab23 Dec 2, 2026
562bd89
removed ts-nocheck generation from client code build process
Baibhab23 Dec 2, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Comment thread
Baibhab23 marked this conversation as resolved.
Resolved
Original file line number Diff line number Diff line change
@@ -1,30 +1,39 @@
# Run backend containers
# Run containers

## App stack only
## Full stack (app + UI)

From project root, build and start the application and database:
From project root, build and start the full application stack — backend, database, Keycloak, feature flags, and the UI:
```bash
docker build -t pipeline-app .
docker compose --env-file .env.local up -d
docker compose --env-file .env.local up --build -d
```

This spins up all services defined in `docker-compose.yml` including `pipeline-ui` (served at http://localhost:3000).

## App stack + monitoring

Starts the app stack together with the full monitoring stack (Grafana, Loki, Prometheus, Alloy). All services start in dependency order automatically:
Runs the full stack (as above) and adds the monitoring stack (Grafana, Loki, Prometheus, Alloy) on top of it:
```bash
docker build -t pipeline-app .
docker compose --env-file .env.local \
-f docker-compose.yml \
-f monitoring/docker-compose-monitoring.yml \
-f monitoring/docker-compose-monitoring-integration.yml \
up -d
up --build -d
Comment thread
Baibhab23 marked this conversation as resolved.
Resolved
```

Monitoring UIs available at:
- Grafana: http://localhost:3000
- Grafana: http://localhost:3001
- Alloy: http://localhost:12345
- Prometheus: http://localhost:9090

## UI with mock API (no backend)

Runs only the UI and a Prism mock server — no database, Keycloak, or backend required:
```bash
docker compose -f docker-compose-mock.yml up --build -d
```

The UI is served at http://localhost:3000. API calls are handled by the Prism mock at http://localhost:4010, driven by the OpenAPI spec. Authentication uses a local mock user instead of Keycloak.

## Stopping

```bash
Expand Down
2 changes: 1 addition & 1 deletion autobuild-docs/setup/dev-env-setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Ensure you have atleast JAVA 17, Node 22 and Apache Maven 3.9 installed and conf
npm ci
```
See [Local Backend Execution](./backend/local-backend-execution.md) for running the application locally.
See [Running Backend Container](./backend/running-backend-containers.md) for running containerized backend with db.
See [Running Containers](./backend/running-containers.md) for running the full containerized stack.

For the ease of local development install [VS Code](https://code.visualstudio.com/) and the following extensions,
1. [JAVA Extension Pack](https://marketplace.visualstudio.com/items?itemName=vscjava.vscode-java-pack)
Expand Down
59 changes: 48 additions & 11 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,14 @@ networks:
services:
mysql-db:
image: mysql:8.0
profiles:
- full
container_name: mysql-db
environment:
MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWORD}
MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWORD:-}
MYSQL_DATABASE: pipeline
MYSQL_USER: ${DB_USERNAME}
MYSQL_PASSWORD: ${DB_PASSWORD}
MYSQL_USER: ${DB_USERNAME:-}
MYSQL_PASSWORD: ${DB_PASSWORD:-}
ports:
- "3306:3306"
volumes:
Expand All @@ -28,14 +30,16 @@ services:
retries: 10
auth-service:
image: quay.io/keycloak/keycloak:26.2.5
profiles:
- full
container_name: auth-service
environment:
KEYCLOAK_ADMIN: admin
KEYCLOAK_ADMIN_PASSWORD: admin
KC_DB: ${DB}
KC_DB_URL: ${DB_URL}
KC_DB_USERNAME: ${DB_USERNAME}
KC_DB_PASSWORD: ${DB_PASSWORD}
KC_DB: ${DB:-}
KC_DB_URL: ${DB_URL:-}
KC_DB_USERNAME: ${DB_USERNAME:-}
KC_DB_PASSWORD: ${DB_PASSWORD:-}
KC_HOSTNAME: http://localhost:8180
KC_HOSTNAME_STRICT: false
KC_HEALTH_ENABLED: true
Expand All @@ -59,6 +63,8 @@ services:
condition: service_healthy
flagd:
image: ghcr.io/open-feature/flagd:latest
profiles:
- full
container_name: flagd
command: start --uri file:./etc/flagd/feature-flags.json
volumes:
Expand All @@ -71,13 +77,15 @@ services:
build:
context: .
dockerfile: pipeline/Dockerfile
profiles:
- full
image: pipeline-app
container_name: pipeline-app
environment:
SPRING_PROFILES_ACTIVE: demo
DB_URL: ${DB_URL}
DB_USER: ${DB_USERNAME}
DB_PASSWORD: ${DB_PASSWORD}
DB_URL: ${DB_URL:-}
DB_USER: ${DB_USERNAME:-}
DB_PASSWORD: ${DB_PASSWORD:-}
AUTH_HOST: auth-service
AUTH_PORT: 8080
OTEL_SERVICE_NAME: pipeline-app
Expand All @@ -96,6 +104,18 @@ services:
condition: service_healthy
flagd:
condition: service_started
mock-api:
image: stoplight/prism:5
profiles:
- mock
command: mock /spec/pipeline-service.yaml -h 0.0.0.0 --dynamic --multiprocess=false
volumes:
- ./apis/openapi-spec/pipeline-service.yaml:/spec/pipeline-service.yaml
ports:
- "4010:4010"
networks:
- app

pipeline-ui:
build:
context: .
Expand All @@ -106,11 +126,28 @@ services:
VITE_KC_URL: http://localhost:8180
VITE_KC_REALM: SpringBootRealm
VITE_KC_CLIENTID: pipeline-app
profiles:
- full
image: pipeline-ui
ports:
- "3000:3000"
- "3001:3000"
networks:
- app
depends_on:
pipeline-app:
condition: service_started

pipeline-ui-mock:
build:
context: .
dockerfile: pipeline-ui/Dockerfile
args:
ENV_FILE: .env.local-with-mock
profiles:
- mock
ports:
- "3001:3000"
networks:
- app
depends_on:
- mock-api
2 changes: 1 addition & 1 deletion monitoring/docker-compose-monitoring.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ services:
- GF_AUTH_BASIC_ENABLED=false
- GF_INSTALL_PLUGINS=grafana-lokiexplore-app
ports:
- 3000:3000/tcp
- 3001:3000/tcp
volumes:
- ${MONITORING_STACK_DIR:-.}/grafana/datasource.yml:/etc/grafana/provisioning/datasources/datasources.yml
- grafana_data:/var/lib/grafana
Expand Down
2 changes: 2 additions & 0 deletions pipeline-ui/.dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ node_modules/
dist/
coverage/
.env.*
!.env.local-e2e
!.env.local-with-mock
Comment thread
Baibhab23 marked this conversation as resolved.
Resolved
test/
*.md
.git
Expand Down
5 changes: 0 additions & 5 deletions pipeline-ui/.env.local

This file was deleted.

8 changes: 7 additions & 1 deletion pipeline-ui/.env.local-e2e
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,10 @@ VITE_API_BASE_URL=http://localhost:8080/api/v1
VITE_IDP=keycloak
VITE_KC_URL=http://localhost:8180
VITE_KC_REALM=SpringBootRealm
VITE_KC_CLIENTID=pipeline-app
VITE_KC_CLIENTID=pipeline-app

DB=mysql
DB_URL=jdbc:mysql://mysql-db:3306/pipeline?useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=UTC
DB_USERNAME=testuser
DB_PASSWORD=testpass
DB_ROOT_PASSWORD=root
1 change: 1 addition & 0 deletions pipeline-ui/.env.local-with-mock
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
VITE_ENV=local
VITE_API_BASE_URL=http://127.0.0.1:4010
VITE_IDP=mock
VITE_MOCK_USER=dummy
VITE_MOCK_USER_EMAIL=dummy@dummy.com
1 change: 1 addition & 0 deletions pipeline-ui/.nvmrc
Comment thread
Baibhab23 marked this conversation as resolved.
Resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
22
10 changes: 9 additions & 1 deletion pipeline-ui/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ COPY pipeline-ui/tailwind.config.js pipeline-ui/postcss.config.js ./
COPY pipeline-ui/openapitools.json .
COPY apis/openapi-spec /apis/openapi-spec
RUN npm run generate:client-code
# Copy all env files so they are available as an optional override.
# Pass --build-arg ENV_FILE=.env.local-e2e to use a specific env file;
# omit it to fall back to the defaults below.
COPY pipeline-ui/.env* ./
ARG ENV_FILE
ARG VITE_API_BASE_URL=http://localhost:8080/api/v1
ARG VITE_IDP=keycloak
ARG VITE_KC_URL=http://localhost:8180
Expand All @@ -25,7 +30,10 @@ ENV VITE_IDP=${VITE_IDP}
ENV VITE_KC_URL=${VITE_KC_URL}
ENV VITE_KC_REALM=${VITE_KC_REALM}
ENV VITE_KC_CLIENTID=${VITE_KC_CLIENTID}
RUN npm run build
RUN if [ -n "$ENV_FILE" ] && [ -f "$ENV_FILE" ]; then \
grep -v '^#' "$ENV_FILE" | grep -v '^VITE_ENV' > /tmp/.env.filtered; \
set -a && . /tmp/.env.filtered && set +a && rm /tmp/.env.filtered; \
fi && npm run build

#
# Serve stage
Expand Down
74 changes: 26 additions & 48 deletions pipeline-ui/README.md
Original file line number Diff line number Diff line change
@@ -1,72 +1,50 @@
# React + TypeScript + Vite
# Pipeline UI

This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
React + TypeScript + Vite frontend for the AutoBuild pipeline service.

Currently, two official plugins are available:
## Prerequisites

- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react) uses [Babel](https://babeljs.io/) (or [oxc](https://oxc.rs) when used in [rolldown-vite](https://vite.dev/guide/rolldown)) for Fast Refresh
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
- Node.js 22 (see [.nvmrc](.nvmrc))
- npm

## React Compiler
## Getting Started

The React Compiler is currently not compatible with SWC. See [this issue](https://github.com/vitejs/vite-plugin-react/issues/428) for tracking the progress.
> **Prerequisite:** Java must be installed — the API client generator (`openapi-generator-cli`) requires a JVM to run.

## Expanding the ESLint configuration
```bash
npm install
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Resolved
npm run generate:clean-client-code
```

If you are developing a production application, we recommend updating the configuration to enable type-aware lint rules:
## Running Locally

```js
export default defineConfig([
globalIgnores(['dist']),
{
files: ['**/*.{ts,tsx}'],
extends: [
// Other configs...
| Command | Description |
|---|---|
| `npm run local-e2e` | Vite dev server using `.env.local-e2e` (connects to real local backend + Keycloak) |
| `npm run local-with-mock` | Vite dev server with mocked API (no backend required) |
| `npm run production` | Build + preview with production settings |

// Remove tseslint.configs.recommended and replace with this
tseslint.configs.recommendedTypeChecked,
// Alternatively, use this for stricter rules
tseslint.configs.strictTypeChecked,
// Optionally, add this for stylistic rules
tseslint.configs.stylisticTypeChecked,
## Environment Files

// Other configs...
],
languageOptions: {
parserOptions: {
project: ['./tsconfig.node.json', './tsconfig.app.json'],
tsconfigRootDir: import.meta.dirname,
},
// other options...
},
},
])
```
| File | Mode | Purpose |
|---|---|---|
| `.env.local-e2e` | `local-e2e` | Local end-to-end testing against a locally running backend and Keycloak |
| `.env.local-with-mock` | `local-with-mock` | Local development with a mocked OpenAPI server (no real backend) |

You can also install [eslint-plugin-react-x](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-x) and [eslint-plugin-react-dom](https://github.com/Rel1cx/eslint-react/tree/main/packages/plugins/eslint-plugin-react-dom) for React-specific lint rules:
## ESLint

```js
// eslint.config.js
import reactX from 'eslint-plugin-react-x'
import reactDom from 'eslint-plugin-react-dom'
For type-aware lint rules in production applications, update `eslint.config.js` to extend `tseslint.configs.recommendedTypeChecked` and set `parserOptions.project`:

```js
export default defineConfig([
globalIgnores(['dist']),
{
files: ['**/*.{ts,tsx}'],
extends: [
// Other configs...
// Enable lint rules for React
reactX.configs['recommended-typescript'],
// Enable lint rules for React DOM
reactDom.configs.recommended,
],
extends: [tseslint.configs.recommendedTypeChecked],
languageOptions: {
parserOptions: {
project: ['./tsconfig.node.json', './tsconfig.app.json'],
tsconfigRootDir: import.meta.dirname,
},
// other options...
},
},
])
Expand Down
Loading