A modern web application for tracking visited places (parks, restaurants, landmarks, etc.) with Google Maps integration, photo management, and visit history.
- Place Management - Add, edit, and organize places you've visited
- Google Maps Integration - Auto-fill place details from Google Maps URLs
- Visit Tracking - Record multiple visits per place with dates, temperatures, and notes
- Photo Gallery - Upload photos for each visit with lightbox viewing
- Distance Calculation - See driving distances from your home location
- Google Reviews - View ratings and reviews from Google
- Search & Filter - Find places by name, location, or country
- Dark Mode - Automatic theme based on system preferences
- Backend: Spring Boot 4.0, Java 25
- Database: MongoDB 8.0 with GridFS (photo storage)
- Frontend: Thymeleaf, htmx, Bootstrap 5.3
- Build: Gradle 9.2
- Testing: JUnit 6, Testcontainers
- Java 25+ (for local development)
- MongoDB 8.0+ (local or containerized)
- Google Maps API Key with these APIs enabled:
- Places API (New)
- Maps JavaScript API
- Distance Matrix API
The fastest way to get started - runs both the app and MongoDB in containers.
-
Clone the repository
git clone https://github.com/your-username/places-tracker.git cd places-tracker -
Configure environment
cp .env.example .env # Edit .env and add your GOOGLE_MAPS_API_KEY -
Start the application
./compose-up-standalone.sh
-
Access the app
Open https://localhost:8443/placestracker in your browser.
Accept the self-signed certificate warning (expected for local development).
-
Stop the application
./compose-down-standalone.sh
Run the app locally with a containerized MongoDB.
-
Clone and configure
git clone https://github.com/your-username/places-tracker.git cd places-tracker cp .env.example .env # Edit .env and add your GOOGLE_MAPS_API_KEY
-
Start MongoDB
./compose-up.sh
-
Run the application
# Set your API key export GOOGLE_MAPS_API_KEY=your_api_key_here # Run with Gradle ./gradlew bootRun
-
Access the app
-
Stop MongoDB when done
./compose-down.sh
Run everything locally without Docker.
-
Install and start MongoDB
# macOS brew install mongodb-community@8.0 brew services start mongodb-community@8.0 # Ubuntu # Follow: https://www.mongodb.com/docs/manual/tutorial/install-mongodb-on-ubuntu/
-
Clone and configure
git clone https://github.com/your-username/places-tracker.git cd places-tracker -
Run the application
export GOOGLE_MAPS_API_KEY=your_api_key_here ./gradlew bootRun -
Access the app
| Variable | Required | Default | Description |
|---|---|---|---|
GOOGLE_MAPS_API_KEY |
Yes | - | Google Cloud API key |
SPRING_MONGODB_URI |
No | mongodb://localhost:27017/placestracker |
MongoDB connection string |
CERT_PASSWORD |
No | placestracker-dev-cert |
SSL certificate password |
CERT_HOSTS |
No | localhost,placestracker.local |
SSL certificate hostnames |
JAVA_OPTS |
No | -Xms512m -Xmx1g |
JVM memory settings |
- Go to Google Cloud Console
- Create a new project or select an existing one
- Enable these APIs:
- Places API (New) - for place search and auto-fill
- Maps JavaScript API - for embedded maps
- Distance Matrix API - for driving distance calculations
- Create an API key under APIs & Services > Credentials
- (Recommended) Restrict the key to your domain/IP
Key configuration in src/main/resources/application.properties:
# Server
server.port=8443
server.servlet.context-path=/placestracker
# Photo upload limits
app.photo.max-size-mb=15
spring.servlet.multipart.max-request-size=100MB
# MongoDB
spring.mongodb.uri=${SPRING_MONGODB_URI:mongodb://localhost:27017/placestracker}# Run all tests (uses Testcontainers - requires Docker)
./gradlew test
# Run with verbose output
./gradlew test --info# Build JAR (skip tests for faster builds)
./gradlew bootJar -x test
# Build with tests
./gradlew build
# Output: build/libs/places-tracker-*.jarSpring Boot DevTools is included. Changes to templates and code trigger automatic restart when running with bootRun.
src/main/java/dk/placestracker/
├── PlacesTrackerApplication.java # Main entry point
├── controller/ # Web controllers
├── domain/ # Place, Visit, Review records
├── repository/ # MongoDB repositories
├── service/ # Business logic
└── util/ # Helper utilities
src/main/resources/
├── application.properties # Configuration
├── templates/ # Thymeleaf templates
└── static/ # CSS, JS, images
docker build -t placestracker:latest .docker run -d \
--name placestracker \
-p 8443:8443 \
-e GOOGLE_MAPS_API_KEY=your_key \
-e SPRING_MONGODB_URI=mongodb://host.docker.internal:27017/placestracker \
placestracker:latest| File | Description |
|---|---|
docker-compose.yml |
MongoDB only (for local development) |
docker-compose.standalone.yml |
Full stack (app + MongoDB) |
| Script | Description |
|---|---|
compose-up.sh |
Start MongoDB only |
compose-down.sh |
Stop MongoDB |
compose-up-standalone.sh |
Start full stack |
compose-down-standalone.sh |
Stop full stack |
build-and-run.sh |
Build and run locally |
- Click New Place
- Paste a Google Maps URL to auto-fill details, or enter manually
- Add visit information (date, temperature, notes)
- Upload photos for each visit
- Save
The app extracts place details from Google Maps URLs:
- Name, address, coordinates
- Ratings and reviews
- Place ID for linking back to Google
Just paste the URL in the Google Maps URL field and click Extract.
- Go to Settings
- Enter your home coordinates
- Distance from home will appear on place detail pages
MIT License - see LICENSE for details.
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request