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
efc78de
feat: refactor Dockerfiles and pyproject.toml for improved dependency…
a-klos Sep 8, 2025
4479baf
fix: update log_cli parameter in pytest configuration to use boolean …
a-klos Sep 8, 2025
2192a84
Refactor dependencies in pyproject.toml:
a-klos Sep 9, 2025
58de48e
refactor: project dependencies and configurations across services
a-klos Sep 10, 2025
9138352
refactor: dependencies in pyproject.toml and poetry.lock
a-klos Sep 10, 2025
a5b8302
refactor: Add local dependencies for rag-core-api and rag-core-lib in…
a-klos Sep 10, 2025
5ed3069
refactor: Update README for development and production modes; enhance…
a-klos Sep 10, 2025
ba5b13b
chore: merge main
a-klos Oct 7, 2025
8d2530a
chore: update lock file
a-klos Oct 7, 2025
934a638
refactor: reorganize cleanup steps and user configuration in Dockerfiles
a-klos Oct 7, 2025
b035d17
Update services/admin-backend/Dockerfile.dev
a-klos Oct 7, 2025
9c0da53
Update services/document-extractor/pyproject.toml
a-klos Oct 7, 2025
7eea608
fix: correct file copy command for extractor-api-lib source in Docker…
a-klos Oct 7, 2025
d057974
Merge branch 'refactor/prod-and-dev-Dockerfiles' of github.com:stacki…
a-klos Oct 7, 2025
3d640aa
fix(admin-api-lib): resolve G200 logging violations by using logger.e…
a-klos Oct 8, 2025
8e841af
fix: update docstrings for clarity in uploader classes and methods
a-klos Oct 8, 2025
c257c21
fix: enhance docstrings for clarity and improve logging practices acr…
a-klos Oct 8, 2025
47bdf3d
fix: improve error logging and enhance docstrings across multiple mod…
a-klos Oct 8, 2025
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
7 changes: 4 additions & 3 deletions .github/workflows/lint-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ jobs:

- name: Build Docker image
run: |
docker build -t $IMAGE_NAME --build-arg dev=1 -f services/${{ matrix.service }}/Dockerfile .
docker build -t $IMAGE_NAME -f services/${{ matrix.service }}/Dockerfile.dev .

- name: Run linting
run: |
Expand All @@ -104,15 +104,16 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4

- name: Set Docker Image Names
- name: Set Docker Image Name
run: |
echo "LINT_IMAGE_NAME=${{ matrix.library }}-lint:${{ needs.sanitize-branch-name.outputs.sanitized_ref }}-${{ github.run_number }}" >> $GITHUB_ENV
echo "TEST_IMAGE_NAME=${{ matrix.library }}-test:${{ needs.sanitize-branch-name.outputs.sanitized_ref }}-${{ github.run_number }}" >> $GITHUB_ENV
shell: bash

- name: Build lint image
run: |
docker build -t $LINT_IMAGE_NAME --build-arg TEST=0 -f libs/Dockerfile libs
docker build -t $LINT_IMAGE_NAME --build-arg DIRECTORY=${{ matrix.library }} --build-arg TEST=0 -f libs/Dockerfile libs


- name: Run linting
run: |
Expand Down
6 changes: 0 additions & 6 deletions .github/workflows/semantic-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,27 +90,21 @@ jobs:
- name: rag-backend
dockerfile: services/rag-backend/Dockerfile
image: rag-backend
build-args: "dev=0"
- name: admin-backend
dockerfile: services/admin-backend/Dockerfile
image: admin-backend
build-args: "dev=0"
- name: document-extractor
dockerfile: services/document-extractor/Dockerfile
image: document-extractor
build-args: "dev=0"
- name: mcp-server
dockerfile: services/mcp-server/Dockerfile
image: mcp-server
build-args: "dev=0"
- name: frontend
dockerfile: services/frontend/apps/chat-app/Dockerfile
image: frontend
build-args: ""
- name: admin-frontend
dockerfile: services/frontend/apps/admin-app/Dockerfile
image: admin-frontend
build-args: ""
steps:
- name: debug-job-inputs
run: |
Expand Down
42 changes: 39 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -225,19 +225,47 @@ cd infrastructure/rag;helm dependency update; cd ../..

After the initial build of the helm chart *Tilt* is able to update the files.

##### Development vs Production Mode

The template supports two deployment modes for local development:

- **Production Mode** (default): Uses production Dockerfiles with local library dependencies for realistic testing
- **Development Mode**: Uses development Dockerfiles with live code updates for fast iteration

The following will tear up the microservices in *k3d*.
For the following steps, it is assumed your current working directory is the root of the git-repository.

**Production Mode (default):**

```shell
tilt up
```

**Development Mode:**

```shell
tilt up -- --dev=true
```

##### Docker File Structure

Each service now has separate Docker files optimized for different use cases:

- `Dockerfile`: Production-optimized builds with multi-stage architecture and security hardening
- `Dockerfile.dev`: Development-optimized builds with faster build times and development tools

The Tilt configuration automatically selects the appropriate Dockerfile based on the mode:

- Production mode uses `Dockerfile` with local library dependencies (`prod-local` group)
- Development mode uses `Dockerfile.dev` with live code updates and development dependencies

Environment variables are loaded from `.env` file in the root of this git-repository.

The *Tilt* UI is available at [http://localhost:10350/](http://localhost:10350/)

If you want to access *Qdrant* etc. just click the resource in the UI. In the upper corner will be the link, to access the resource.

##### Debugging
> 📝 NOTE: For frontend live updates with Tilt see [Frontend live updates with Tilt](./services/frontend/README.md#live-updates-with-tilt)

To enable debugging, start tilt with the following command:
Expand All @@ -246,6 +274,12 @@ To enable debugging, start tilt with the following command:
tilt up -- --debug=true
```

It is recommended to combine debugging with development mode:

```shell
tilt up -- --debug=true --dev=true
```

The backend will wait until your debugger is connected before it will fully start.
The debugger used is `debugpy` which is compatible with VS Code.
To connect the debugger, you can use the following `launch.json`:
Expand Down Expand Up @@ -370,10 +404,12 @@ A detailed explanation of, how to access a service via ingress, can be found in
### 2.1 Server provisioning

The RAG template requires *at least*:
- A Kubernetes Cluster
- S3 ObjectStorage

- A Kubernetes Cluster
- S3 ObjectStorage

Provided is an example Terraform script, using the [STACKIT Terrraform Provider](https://registry.terraform.io/providers/stackitcloud/stackit/latest/docs):

```terraform
resource "stackit_ske_project" "rag-ske" {
project_id = var.stackit_project_id
Expand Down Expand Up @@ -431,8 +467,8 @@ Further requirements for the server can be found in the [infrastructure README](

A detailed description regarding the configuration of Langfuse can be found in the [infrastructure README](./infrastructure/README.md).


## 3. Build and Test

The example `Tiltfile` provides a triggered linting and testing.
The linting-settings can be changed in the `services/rag-backend/pyproject.toml` file under section `tool.flake8`.

Expand Down
Loading
Loading