Skip to content

Commit f3b633d

Browse files
New service: Tracktor (#225)
* New service: Tracktor * Update README.md to enhance Tracktor description and features --------- Co-authored-by: Bart <57799908+crypt0rr@users.noreply.github.com>
1 parent 51f9a3e commit f3b633d

File tree

4 files changed

+125
-1
lines changed

4 files changed

+125
-1
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ If you would like to add a new config, you can use the [service-template](templa
118118
### 📊 Dashboards and Visualization
119119

120120
| 📊 Service | 📝 Description | 🔗 Link |
121-
| -------------- | ------------------------------------------------------------------------------------ | ---------------------------- |
121+
| -------------- | ------------------------------------------------------------------------------------ | ---------------------------- |
122122
| 🧭 **Glance** | A concise, customizable dashboard for self-hosted services and personal metrics. | [Details](services/glance) |
123123
| 🏠 **Homepage** | A modern, highly customizable homepage for organizing links and monitoring services. | [Details](services/homepage) |
124124

@@ -165,6 +165,7 @@ If you would like to add a new config, you can use the [service-template](templa
165165
| 🔔 **Gotify** | A simple server for sending and receiving messages in real-time. | [Details](services/gotify) |
166166
| 📣 **ntfy** | A simple HTTP-based pub/sub notification service for sending push notifications. | [Details](services/ntfy) |
167167
| 🚗 **LubeLogger** | Self-hosted vehicle maintenance tracker with private access. | [Details](services/lube-logger) |
168+
| 🚗 **Tracktor** | Self-hosted vehicle maintenance tracker. | [Details](services/tracktor) |
168169
| 📱 **Mini-QR** | A minimal, self-hosted QR code generator with a mobile-friendly UI. | [Details](services/miniqr) |
169170
| 🔐 **Hemmelig** | A self-hosted, zero-knowledge encrypted secret sharing platform with expiring secrets. | [Details](services/hemmelig) |
170171
| 📦 **Homebox** | A self-hosted home inventory and asset management system. | [Details](services/homebox) |

services/tracktor/.env

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#version=1.1
2+
#URL=https://github.com/tailscale-dev/ScaleTail
3+
#COMPOSE_PROJECT_NAME= # Optional: only use when running multiple deployments on the same infrastructure.
4+
5+
# Service Configuration
6+
SERVICE=tracktor # Service name (e.g., adguard). Used as hostname in Tailscale and for container naming (app-${SERVICE}).
7+
IMAGE_URL=ghcr.io/javedh-dev/tracktor:latest # Docker image URL from container registry (e.g., adguard/adguard-home).
8+
9+
# Network Configuration
10+
SERVICEPORT=3333 # Port to expose to local network. Uncomment the "ports:" section in compose.yaml to enable.
11+
DNS_SERVER=9.9.9.9 # Preferred DNS server for Tailscale. Uncomment the "dns:" section in compose.yaml to enable.
12+
13+
# Tailscale Configuration
14+
TS_AUTHKEY= # Auth key from https://tailscale.com/admin/authkeys. See: https://tailscale.com/kb/1085/auth-keys#generate-an-auth-key for instructions.
15+
TS_TAILNET= # Your Tailscale tailnet name (e.g., my-tailnet).
16+
# Optional Service variables
17+
# PUID=1000

services/tracktor/README.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Tracktor with Tailscale Sidecar Configuration
2+
3+
This Docker Compose configuration sets up **Tracktor** with a **Tailscale sidecar** container, enabling secure access to your self-hosted vehicle management interface over your private Tailscale network. With this setup, your Tracktor instance remains **private and accessible only from authorized devices on your Tailnet**, keeping sensitive vehicle data, documents, and analytics off the public internet.
4+
5+
## Tracktor
6+
7+
[**Tracktor**](https://github.com/javedh-dev/tracktor) is an open-source web application for comprehensive vehicle management. It helps you track multiple vehicles in one place, including fuel consumption, maintenance history, insurance, and regulatory documents with renewal dates.
8+
9+
Tracktor is under active development and may include breaking changes. Keep regular backups of your data and validate upgrades before relying on it for critical workflows.
10+
11+
## Key Features
12+
13+
- 🚗 **Vehicle Management** – Add, edit, and manage multiple vehicles, including different fuel types.
14+
-**Fuel Tracking** – Log fuel refills and monitor consumption and efficiency over time.
15+
- 🧰 **Maintenance Log** – Record and review maintenance history per vehicle.
16+
- 📄 **Document Tracking** – Track insurance, inspection, and regulatory documents with renewal dates.
17+
-**Reminders** – Set reminders for maintenance, renewals, and other vehicle events.
18+
- 📊 **Dashboard & Analytics** – Visualize key metrics and upcoming renewals.
19+
- 🔐 **User Authentication** – Username/password auth with session management.
20+
- 🎛️ **Feature Toggles** – Enable or disable features depending on your needs.
21+
22+
## Why Self-Host?
23+
24+
A vehicle management system often contains personal and operational data such as license plate numbers, VINs, service history, and document expiration dates. Hosting this data yourself ensures you retain full ownership, avoid third-party data exposure, and can integrate it cleanly into your homelab or internal tooling.
25+
26+
When combined with Tailscale, Tracktor becomes a private portal accessible only to authenticated devices on your Tailnet. This significantly reduces attack surface by avoiding public port exposure, while preserving the convenience of accessing your vehicle records from anywhere.
27+
28+
## Configuration Overview
29+
30+
In this deployment, a **Tailscale sidecar container** (for example `tailscale-tracktor`) runs the Tailscale client and joins your private Tailscale network. The main `tracktor` service uses:
31+
32+
```plain
33+
network_mode: service:tailscale-tracktor
34+
```
35+
36+
This configuration routes all inbound and outbound traffic through the Tailscale interface, ensuring that the Tracktor web UI is accessible **only via your Tailscale network**.

services/tracktor/compose.yaml

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
configs:
2+
ts-serve:
3+
content: |
4+
{"TCP":{"443":{"HTTPS":true}},
5+
"Web":{"$${TS_CERT_DOMAIN}:443":
6+
{"Handlers":{"/":
7+
{"Proxy":"http://127.0.0.1:3000"}}}},
8+
"AllowFunnel":{"$${TS_CERT_DOMAIN}:443":false}}
9+
10+
services:
11+
# Make sure you have updated/checked the .env file with the correct variables.
12+
# All the ${ xx } need to be defined there.
13+
# Tailscale Sidecar Configuration
14+
tailscale:
15+
image: tailscale/tailscale:latest # Image to be used
16+
container_name: tailscale-${SERVICE} # Name for local container management
17+
hostname: ${SERVICE} # Name used within your Tailscale environment
18+
environment:
19+
- TS_AUTHKEY=${TS_AUTHKEY}
20+
- TS_STATE_DIR=/var/lib/tailscale
21+
- TS_SERVE_CONFIG=/config/serve.json # Tailscale Serve configuration to expose the web interface on your local Tailnet - remove this line if not required
22+
- TS_USERSPACE=false
23+
- TS_ENABLE_HEALTH_CHECK=true # Enable healthcheck endpoint: "/healthz"
24+
- TS_LOCAL_ADDR_PORT=127.0.0.1:41234 # The <addr>:<port> for the healthz endpoint
25+
#- TS_ACCEPT_DNS=true # Uncomment when using MagicDNS
26+
- TS_AUTH_ONCE=true
27+
configs:
28+
- source: ts-serve
29+
target: /config/serve.json
30+
volumes:
31+
- ./config:/config # Config folder used to store Tailscale files - you may need to change the path
32+
- ./ts/state:/var/lib/tailscale # Tailscale requirement - you may need to change the path
33+
devices:
34+
- /dev/net/tun:/dev/net/tun # Network configuration for Tailscale to work
35+
cap_add:
36+
- net_admin # Tailscale requirement
37+
#ports:
38+
# - 0.0.0.0:${SERVICEPORT}:${SERVICEPORT} # Binding port ${SERVICE}PORT to the local network - may be removed if only exposure to your Tailnet is required
39+
# If any DNS issues arise, use your preferred DNS provider by uncommenting the config below
40+
#dns:
41+
# - ${DNS_SERVER}
42+
healthcheck:
43+
test: ["CMD", "wget", "--spider", "-q", "http://127.0.0.1:41234/healthz"] # Check Tailscale has a Tailnet IP and is operational
44+
interval: 1m # How often to perform the check
45+
timeout: 10s # Time to wait for the check to succeed
46+
retries: 3 # Number of retries before marking as unhealthy
47+
start_period: 10s # Time to wait before starting health checks
48+
restart: always
49+
50+
# ${SERVICE}
51+
application:
52+
image: ${IMAGE_URL} # Image to be used
53+
network_mode: service:tailscale # Sidecar configuration to route ${SERVICE} through Tailscale
54+
container_name: app-${SERVICE} # Name for local container management
55+
environment:
56+
- TRACKTOR_DEMO_MODE=false
57+
- FORCE_DATA_SEED=false
58+
- CORS_ORIGINS="https://${SERVICE}.${TS_TAILNET}.ts.net" # Adjust as needed for your setup
59+
volumes:
60+
- ./${SERVICE}-data:/data
61+
depends_on:
62+
tailscale:
63+
condition: service_healthy
64+
healthcheck:
65+
test: ["CMD", "pgrep", "-f", "node build"] # Check if ${SERVICE} process is running
66+
interval: 1m # How often to perform the check
67+
timeout: 10s # Time to wait for the check to succeed
68+
retries: 3 # Number of retries before marking as unhealthy
69+
start_period: 30s # Time to wait before starting health checks
70+
restart: always

0 commit comments

Comments
 (0)