<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/remote-debugging-spring-ai-docker-model-runner-issue-from-intellij-idea-dohnst4rv" -->

---
title: Remote Debugging Spring AI + Docker Model Runner Issue...
description: A walkthrough demonstrates debugging a Spring AI application backed by Docker Model Runner when both the app and models run inside Docker containers rather...
canonical: https://daily.dev/posts/remote-debugging-spring-ai-docker-model-runner-issue-from-intellij-idea-dohnst4rv
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Remote Debugging Spring AI + Docker Model Runner Issue From IntelliJ IDEA | daily.dev
og:description: A walkthrough demonstrates debugging a Spring AI application backed by Docker Model Runner when both the app and models run inside Docker containers rather...
og:url: https://daily.dev/posts/remote-debugging-spring-ai-docker-model-runner-issue-from-intellij-idea-dohnst4rv
og:image: https://api.daily.dev/og/posts/DOhnSt4rV.png
og:image:alt: Remote Debugging Spring AI + Docker Model Runner Issue From IntelliJ IDEA
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Remote Debugging Spring AI + Docker Model Runner Issue From IntelliJ IDEA

**[SivaLabs \(YouTube\)](https://daily.dev/sources/sivalabs-youtube)** · 14 min read · 0 upvotes · 0 comments

## Summary

A walkthrough demonstrates debugging a Spring AI application backed by Docker Model Runner when both the app and models run inside Docker containers rather than from the IDE. The presenter shows how enabling JAVA_TOOL_OPTIONS debug flags in Docker Compose and using IntelliJ IDEA's Remote JVM Debug configuration lets you attach a breakpoint to a containerized app. Using this technique, the root cause of a 404 error is traced to a duplicated /v1 path segment: the Docker Model Runner base URL already includes /v1/engines and Spring AI's default chat completions path also prepends /v1, causing a broken URL. The fix is overriding the chat completion path in an application-docker.properties file to drop the redundant /v1 segment.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://www.youtube.com/watch?v=wwaBx6yohMg>

## Questions this post answers

### Why does my Spring AI app get a 404 error when talking to Docker Model Runner only inside Docker containers, but works fine locally?

The 404 happens because both the Docker Model Runner base URL and the Spring AI default chat completions path include /v1, creating a duplicated /v1/v1 segment in the final request URL. The Docker Model Runner endpoint ends in /engines/v1, while Spring AI's OpenAI-compatible client appends /v1/chat/completions by default, so the two overlap only when running against that runner in containers.

_Developers wiring Spring AI to Docker Model Runner track fixes like this URL path conflict on daily.dev._

### How do I attach IntelliJ IDEA's debugger to a Spring Boot application running inside a Docker container?

Add debug flags to JAVA_TOOL_OPTIONS in the Docker Compose file (specifying a debug port such as 5005) and expose that same port on the host. Then in IntelliJ IDEA, create a new 'Remote JVM Debug' run configuration pointing to that host and port, apply it, and start debugging to attach and hit breakpoints inside the containerized app.

_Java developers debugging containerized services can follow techniques like this shared on daily.dev._

### How do I fix a duplicated /v1 path when using Spring AI with an OpenAI-compatible base URL that already includes /v1?

Create a profile-specific properties file (for example application-docker.properties) and explicitly override the chat completion path to just /chat/completions instead of the default /v1/chat/completions, since the base URL already ends in /v1. Enabling that profile lets the override load automatically and removes the redundant path segment causing the 404.

_Anyone configuring OpenAI-compatible endpoints can find fixes like this path override on daily.dev._

## Similar posts on daily.dev

- [Spring Boot Debugging – Now Remote](https://daily.dev/posts/spring-boot-debugging-now-remote-a1g7mxjih) · JetBrains · 18 upvotes · 0 comments
- [OpenWebUI \+ Model Runner: Zero-Config Local AI](https://daily.dev/posts/openwebui-model-runner-zero-config-local-ai-c9aayqtjl) · Docker · 98 upvotes · 2 comments
- [Transform your AI coding agent into a deterministic Java Spring expert](https://daily.dev/posts/transform-your-ai-coding-agent-into-a-deterministic-java-spring-expert-n8wcjz7q9) · The New Stack · 0 upvotes · 0 comments

---

Tags: [#devtools](https://daily.dev/tags/devtools), [#java](https://daily.dev/tags/java), [#spring-ai](https://daily.dev/tags/spring-ai)

[View this post on daily.dev](https://daily.dev/posts/remote-debugging-spring-ai-docker-model-runner-issue-from-intellij-idea-dohnst4rv)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Remote Debugging Spring AI + Docker Model Runner Issue From IntelliJ IDEA","url":"https://daily.dev/posts/remote-debugging-spring-ai-docker-model-runner-issue-from-intellij-idea-dohnst4rv","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/remote-debugging-spring-ai-docker-model-runner-issue-from-intellij-idea-dohnst4rv"},"datePublished":"2026-09-27T07:26:41.658Z","dateModified":"2026-09-27T07:53:19.935Z","description":"A walkthrough demonstrates debugging a Spring AI application backed by Docker Model Runner when both the app and models run inside Docker containers rather...","image":"https://i.ytimg.com/vi/wwaBx6yohMg/sddefault.jpg","thumbnailUrl":"https://i.ytimg.com/vi/wwaBx6yohMg/sddefault.jpg","isAccessibleForFree":true,"articleSection":"SivaLabs (YouTube)","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"SivaLabs (YouTube)","logo":"https://media.daily.dev/image/upload/s--8ATVo4an--/f_auto,q_auto/v1790493987/logos/sivalabs-youtube?_a=BAMAMicg0","url":"https://daily.dev/sources/sivalabs-youtube"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/remote-debugging-spring-ai-docker-model-runner-issue-from-intellij-idea-dohnst4rv","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"devtools,java,spring-ai","timeRequired":"PT14M","video":{"@type":"VideoObject","name":"Remote Debugging Spring AI + Docker Model Runner Issue From IntelliJ IDEA","description":"A walkthrough demonstrates debugging a Spring AI application backed by Docker Model Runner when both the app and models run inside Docker containers rather...","thumbnailUrl":"https://i.ytimg.com/vi/wwaBx6yohMg/sddefault.jpg","uploadDate":"2026-09-27T07:26:41.658Z","duration":"PT14M","url":"https://api.daily.dev/r/DOhnSt4rV","embedUrl":"https://www.youtube.com/embed/wwaBx6yohMg"}}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"SivaLabs (YouTube)","item":"https://daily.dev/sources/sivalabs-youtube"},{"@type":"ListItem","position":3,"name":"Remote Debugging Spring AI + Docker Model Runner Issue From IntelliJ IDEA"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/remote-debugging-spring-ai-docker-model-runner-issue-from-intellij-idea-dohnst4rv#faq","mainEntity":[{"@type":"Question","name":"Why does my Spring AI app get a 404 error when talking to Docker Model Runner only inside Docker containers, but works fine locally?","acceptedAnswer":{"@type":"Answer","text":"The 404 happens because both the Docker Model Runner base URL and the Spring AI default chat completions path include /v1, creating a duplicated /v1/v1 segment in the final request URL. The Docker Model Runner endpoint ends in /engines/v1, while Spring AI's OpenAI-compatible client appends /v1/chat/completions by default, so the two overlap only when running against that runner in containers. Developers wiring Spring AI to Docker Model Runner track fixes like this URL path conflict on daily.dev."}},{"@type":"Question","name":"How do I attach IntelliJ IDEA's debugger to a Spring Boot application running inside a Docker container?","acceptedAnswer":{"@type":"Answer","text":"Add debug flags to JAVA_TOOL_OPTIONS in the Docker Compose file (specifying a debug port such as 5005) and expose that same port on the host. Then in IntelliJ IDEA, create a new 'Remote JVM Debug' run configuration pointing to that host and port, apply it, and start debugging to attach and hit breakpoints inside the containerized app. Java developers debugging containerized services can follow techniques like this shared on daily.dev."}},{"@type":"Question","name":"How do I fix a duplicated /v1 path when using Spring AI with an OpenAI-compatible base URL that already includes /v1?","acceptedAnswer":{"@type":"Answer","text":"Create a profile-specific properties file (for example application-docker.properties) and explicitly override the chat completion path to just /chat/completions instead of the default /v1/chat/completions, since the base URL already ends in /v1. Enabling that profile lets the override load automatically and removes the redundant path segment causing the 404. Anyone configuring OpenAI-compatible endpoints can find fixes like this path override on daily.dev."}}]}
```

