Skip to content

Updated building instructions (mvn -> gradle) #43

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 8, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion configuration/serialization-serde.md
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ If selected serde couldn't be applied (exception was thrown), then fallback (Str

You can implement your own serde and register it in kafbat-ui application. To do so:

1. Add `serde-api` dependency (should be downloadable via maven central)
1. Add `serde-api` dependency, [link to maven central](https://central.sonatype.com/artifact/io.kafbat.ui/serde-api)
2. Implement `io.kafbat.ui.serde.api.Serde` interface. See javadoc for implementation requirements.
3. Pack your serde into uber jar, or provide directory with no-dependency jar and it's dependencies jars

Expand Down
39 changes: 15 additions & 24 deletions development/building/with-docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,38 +6,29 @@ Once you installed the prerequisites and cloned the repository, run the followin

### Step 1 : Build

> Skip the maven tests as they might not be successful

* Build a docker image with the app

```
./mvnw clean install -Pprod
```

* if you need to build the frontend module, go to
* frontend-build-documentation
* In case you want to build `api` module by skipping the tests

```
./mvnw clean install -Dmaven.test.skip=true -Pprod
./gradlew clean build \
# -x skips goals, in this cases tests. Tests take time, run them separately if needed.
-x test \
# building an app without frontend part could be useful for developing frontend or for using the app like an API client
-Pinclude-frontend=true \
# skip building a docker image if you only need a jar
-Pbuild-docker-images=true \
# version will be displayed in UI and used for tagging docker image. You can remove it.
-Pversion=<version>
```

* To build only the `api` module you can use this command:

```
./mvnw -f api/pom.xml clean install -Pprod -DskipUIBuild=true
```

If this step is successful, it should create a docker image named `ghcr.io/kafbat/kafka-ui` with `latest` tag on your local machine except macOS M1.

A successful build should produce a docker image named `ghcr.io/kafbat/kafka-ui` with whatever version you've supplied.
### Step 2 : Run

**Using Docker Compose**

* Start the app using docker image built in step 1 along with Kafka clusters:

```
docker-compose -f ./documentation/compose/kafbat-ui.yaml up -d
docker-compose -f ./.dev/dev.yaml up -d
```

**Using Spring Boot Run**
Expand All @@ -51,20 +42,20 @@ docker-compose -f ./documentation/compose/kafka-clusters-only.yaml up -d
* Then start the app.

```
./mvnw spring-boot:run -Pprod
./gradlew bootRun -x test

# or

./mvnw spring-boot:run -Pprod -Dspring.config.location=file:///path/to/conf.yaml
./gradlew bootRun -x test -Dspring.config.location=file:///path/to/conf.yaml
```

**Running in kubernetes**

* Using Helm Charts

```
helm repo add kafbat-ui https://kafbat.github.io/helm-charts
helm install kafka-ui kafka-ui/kafka-ui
helm repo add kafbat https://ui.charts.kafbat.io
helm install kafbat-ui kafbat/kafka-ui
```

To read more please follow to chart documentation.
Expand Down
2 changes: 1 addition & 1 deletion development/building/without-docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ java -Dspring.config.additional-location=<path-to-application-local.yml> --add-o

> _**NOTE:**_ If you want to get kafbat-ui up and running locally quickly without building the jar file manually, then just follow Running Without Docker Quickly

> Comment out `docker-maven-plugin` plugin in `api` module `pom.xml`
Proceed with building instructions from [[with-docker]] and disable/remove `build-docker-images` flag.

* Command to build the jar

Expand Down