Tired of paying for AI API access? Want to keep your data secure? In this tutorial, I'll show you how to run Google's Gemma 3 AI model locally on your Mac using Docker Desktop's new Model Runner feature and integrate it with Spring Boot applications.
In just 15 minutes, you'll learn how to build a fully functional AI-powered Java application that runs completely on your own machine - no API keys, no data sharing, and zero monthly fees!
What You'll Learn:
• How to configure Docker Desktop's Model Runner feature
• Running Gemma 3 (Google's powerful open-source AI model) locally
• Setting up a Spring Boot application with Spring AI
• Connecting your Java app to the local AI model
• Sending prompts and receiving responses without cloud APIs
Video Chapters:
0:00 - Introduction
1:15 - Docker Model Runner Documentation
2:40 - Available Models Overview
3:25 - Docker Desktop Configuration
4:30 - Running Models in the Terminal
6:10 - Creating a Spring Boot Application
7:45 - Setting Up Properties
9:20 - Writing the Java Code
10:35 - Running the Application
11:30 - Conclusion
Want more developer tips like this? Hit the subscribe button and ring the notification bell to never miss an update! Check out more AI development tutorials on my channel.
🔗 Resources:
- Docker Model Runner Documentation: https://docs.docker.com/desktop/model-runner/
- Spring AI GitHub: https://github.com/spring-projects/spring-ai
- My GitHub Repo for this tutorial: https://github.com/danvega/docker-model-runner
💻 Running on: Docker Desktop 4.40+ on Mac with Apple Silicon
Let me know in the comments if you're using this approach and what models you're trying out!
👋🏻Connect with me:
Website: https://www.danvega.dev
Twitter: https://twitter.com/therealdanvega
Github: https://github.com/danvega
LinkedIn: https://www.linkedin.com/in/danvega
Newsletter: https://www.danvega.dev/newsletter
SUBSCRIBE TO MY CHANNEL: http://bit.ly/2re4GH0 ❤️