Secure authentication with Keycloak

In modern enterprise applications, the login is far more than just an access point – it is the core element for security, user-friendliness and integration capability.

Our internal tool “Tedras”, which was developed for conducting and documenting evaluation drives, has so far only been used Microsoft Access ID (formerly Azure Active Directory) for login. As the system increasingly attracted interest from external partners and customers, we had to expand our authentication concept: A second, multi-tenant login was required without compromising security or ease of use.

Our choice fell on keycloak, an open-source solution for Identity & Access Management that stands out for its flexibility, standards compliance and easy integration.

Our architecture at a glance

The system consists of three central components:

– iOS app (Swift, SwiftUI): Recording of evaluation drives with video, voice commentary and GPS data

– Backend (Golang, REST, PostgreSQL): Storage and management of all sessions, photos and videos

– Frontend (React, nginx): Visualization and analysis of the recorded driving data

The services run in containerized Docker and are orchestrated via Kubernetes.

Keycloak was integrated as the central identity provider for authentication.

Key technical aspects of the integration:

– OIDC flows: Both authentication methods – Entra ID and Keycloak – are based on the OpenID Connect standard, which allows for a clean separation and easy extensibility.

– Role and rights management: Keycloak allows for granular definition of user groups, roles, and scopes.

– Token validation in the backend: The Go backend checks access tokens via the Keycloak JWKS interface and grants access only to approved resources.

– Multi-tenancy: A separate realm can be set up in Keycloak for each customer, allowing for separate user management and branding.

Why Keycloak?

We didn't want an in-house development or a makeshift solution. Developing our own OIDC-based authentication service is anything but trivial – especially when enterprise-level security requirements have to be met.

Such a service must correctly implement token flows, securely handle refresh mechanisms, regularly rotate certificates, support multi-realm structures, and remain GDPR-compliant. Errors in these areas can quickly lead to critical security vulnerabilities.

Instead of taking this complex path ourselves, we deliberately opted for Keycloak – a proven open-source platform that:

– standards-based (OIDC, SAML, OAuth2) works

– proven in large companies and projects

– remains easy to configure and deploy

– no license costs incurred

– integrates seamlessly into existing DevOps pipelines

This allowed us to concentrate on the actual product development and not have to reinvent the wheel.

How-To: Deploy Keycloak in Kubernetes

A major advantage of Keycloak is its straightforward deployment. The only requirements are a Kubernetes cluster with kubectl access, Helm (at least v3), and an Ingress controller (e.g., Traefik or NGINX).

Step 1: Add Helm repository

helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update

Step 2: Create a template for Values.yaml

To see all configurable values, you can export the chart's default configuration:

helm show values bitnami/keycloak > values.yaml

This file contains all the parameters that you can adjust to your environment – ​​from database credentials to Ingress settings and resource limits.

Step 3: Important adjustments in the values.yaml file

For a simple, yet production-like basic installation, the following areas in particular should be adapted:

auth:
  adminUser: admin
  adminPassword: "SuperSecret123"

service:
  type: ClusterIP
  port: 8080

ingress:
  enabled: true
  ingressClassName: traefik
  hostname: keycloak.example.com
  path: /auth
  pathType: Prefix
  tls: false

postgresql:
  enabled: true
  auth:
    username: bn_keycloak
    password: "PostgresPass123"
    database: bitnami_keycloak

Step 4: Start deployment

Once the values ​​are adjusted, a single command is sufficient:

helm install keycloak bitnami/keycloak -f values.yaml --namespace keycloak --create-namespace

After a few minutes, a complete Keycloak instance is running – including database, Ingress configuration and optional TLS support.

Step 5: First registration

You can now open your Keycloak instance in your browser:

http://keycloak.example.com/auth

Next, you log in with the configured admin user, replace the default administrator, and create your first realms, clients, and user groups.

Step 6: Extensions & Automation

Optional extensions such as:

– Identity Brokering

– Custom Themes

– Realm Templates

– automated backups

Configure directly via Helm parameters or the REST API. This quickly transforms a simple basic installation into a productive IAM system that can be fully integrated into modern CI/CD pipelines.

Our Conclusion

By integrating Keycloak, we have created an authentication architecture that combines both internal security and external scalability. This allows our "Tedras" system to be used efficiently not only internally but also at customer sites, without requiring new user management or complex IT approvals.

The experience gained from this project shows that open-source solutions like Keycloak can be excellently integrated into existing cloud and DevOps landscapes.

Are you planning to securely integrate external partners or customers into your system? Or are you considering how to combine multiple login providers within an existing architecture?
Talk to us – we are happy to share our experiences from integrating Keycloak, Entra ID & Co.

Interested in training?

Our Environmental management policy

The environmental policy of EVOMOTIV is aimed at controlling, regulating and minimising the impact of business and human activities on the environment. This is achieved through a variety of measures and initiatives:


1. Resource efficiency and conservation: EVOMOTIV focuses on economical use of energy and water. Standby modes are avoided and energy-saving IT devices are used.

2. Raising awareness among employees: Through lock screens, e-learning and tips on
In-house events raise employees’ awareness of environmental issues.

3. Promoting biodiversity: EVOMOTIV expands green spaces and builds refuges for insects, such as flower meadows, green roofs and bee hotels.

4. Sustainable food: EVOMOTIV focuses on local, seasonal and fairly traded food and relies on reusable tableware.

5. Paperless office: EVOMOTIV aims to work completely paperless.

6. Use of renewably produced fuels: Until the fleet is fully electrified, the focus will be on fuels obtained from renewable energy sources.

7. Electrification of the fleet: EVOMOTIV plans to electrify its fleet to reduce CO2 emissions.

8. Ecologically produced merchandise: EVOMOTIV buys environmentally friendly gifts for employees and customers.

9. Reduction of data waste: EVOMOTIV is committed to reducing data waste in order to minimize the environmental impact of digital waste.

EVOMOTIV is committed to continuously improving environmental performance through business practices and strategies and to actively contributing to environmental protection, with the clear aim of promoting sustainable development.

social commitment

Our central sustainability motive is to make a positive contribution to people and the environment. Under the principle
<< Inspire people, develop values >> we are involved in a variety of ways directly in the region of our locations in order to promote a variety of charitable projects.

sponsoring

A selection of the organizations that are particularly close to our hearts:

Donation

Our social commitment is reflected in our support of various non-profit organizations. Our colleagues are actively involved, for example through actions such as “Cycling for a good cause“. Through such initiatives we collect donations, which we donate to, for example Children's Hospice Munich as well as the support association Helping Hands . We also take part in campaigns such as: Christmas in a shoe boxto make a sustainable contribution to social issues.

Our climate strategy

Lorem ipsum dolor sit amet, consetetur sadipscing elitr,

Subscribe to our newsletter

Our Locations

EVOMOTIV GmbH
In Bühl 16/1
D – 71287 Flacht
Tel: 0711/32 06 74-0
stuttgart@evomotiv.de

for directions

1 of 5
EVOMOTIV ULM GmbH Location Friedrichshafen Albrechtstrasse 8 D- 88045 Friedrichshafen Tel: 07541 7300 130 friedrichshafen@evomotiv.de 2 of 5

EVOMOTIV ULM GmbH
Hörvelsinger Weg 62/2
D – 89081 Ulm
Tel: 0731/708 09 84-00
ulm@evomotiv.de

for directions

3 of 5

EVOMOTIV GmbH
Munich location
Mies-van-der-Rohe-Strasse 6
D – 80807 Munich
Tel: 089/95 45 92 53-0

muenchen@evomotiv.de

for directions

4 of 5

EVOMOTIV GmbH
Ingolstadt location
Münchener Strasse 19
D- 85123 Karlskron-Brautlach
Tel: 089/95 45 92 53-0

ingolstadt@evomotiv.de

for directions

5 of 5

EVOMOTIV GmbH

Stuttgart location
In Bühl 16/1
D - 71287 Flacht

Melanie Pramann
stuttgart@evomotiv.de
Tel: 0711/32 06 74-0
For directions

EVOMOTIV GmbH

Munich location
Mies-van-der-Rohe-Strasse 6
D - 80807 Munich

Kryschan Schwirzinger
muenchen@evomotiv.de
Tel: 089/95 45 92 53-0
For directions

EVOMOTIV ULM GMBH

Ulm location
Hörvelsinger Weg 62/2
D-89081 Ulm

Kathrin Eckel
ulm@evomotiv.de
Tel: 0731/70 80 98 4-00
For directions

EVOMOTIV ULM GmbH

Friedrichshafen location
Albrechtstrasse 8
D - 88045 Friedrichshafen

Matthias Knott
friedrichshafen@evomotiv.de
Tel: 07541/73 00 13-0
For directions

EVOMOTIV GmbH

Ingolstadt location
Münchener Str.19
D - 85123 Karlskron-Brautlach

Kryschan Schwirzinger
ingolstadt@evomotiv.de
Tel: 089/95 45 92 53-0
For directions