Skip to content
Merged

v2 #129

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
5288380
Moved from npm to pnpm for package management
Dec 11, 2025
295d6b6
Migrating from seperate backend/frontend to sveltekit full stack app …
Dec 11, 2025
fe9d8a9
Using Chain of responsibility pattern for middlewares
Dec 12, 2025
061f43b
Cleanup middlewares
Dec 12, 2025
8732627
Removed extra controller layer
Dec 12, 2025
b1497ea
Fixed data seeding
Dec 12, 2025
799c16a
Remove dependency from environment based env
Dec 12, 2025
b4b55e6
Removed all shadcn components
Dec 13, 2025
8235376
Removed ssr and updated ui components
Dec 13, 2025
c1cb295
Cleanup
Dec 13, 2025
24b0736
Fixed warnings
Dec 13, 2025
85c0846
Fixed error for mileage calculation
Dec 13, 2025
47dcf58
Replaced common package APIResponse
Dec 13, 2025
b3397a3
Updated imports
Dec 13, 2025
f11a8bc
Fixed broken components
Dec 13, 2025
0f4e1bb
Fixed data table rendering issue
Dec 13, 2025
12a4822
Fixed Image Upload
Dec 13, 2025
133ca41
Showing image on edit page as well
Dec 13, 2025
aa345cc
Added user/password auth
Dec 13, 2025
b4c0d49
Added user/password authentication
Dec 13, 2025
2bfe728
Fixed auth check issue
Dec 13, 2025
cb35a03
Added migration script for user/password auth
Dec 13, 2025
128b664
Removed crypto dependency from frontend forms.
Dec 13, 2025
85f470a
Seeding demo user
Dec 13, 2025
3918742
Fixed auth to be single user
Dec 13, 2025
210b906
Added --host to preview
Dec 13, 2025
f6456f8
Created the new dockerfile
Dec 14, 2025
1cd6f8d
Removed tests and updated environment variables
Dec 14, 2025
9ae7958
updated gihub actions
Dec 14, 2025
8e163db
build: Upgrade Node.js to 24 and pnpm to 10 in CI workflow.
Dec 14, 2025
6473faf
FIxed linting issues
Dec 14, 2025
48790c8
refactor: remove yFormatter prop and related formatting helper import…
Dec 14, 2025
97f02f1
refactor: Separate client and server environment variables into disti…
Dec 14, 2025
b303e88
Fixed liniting issues
Dec 14, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
24 changes: 24 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Environment Configuration
NODE_ENV="dev" # Options: dev, test, production

# Database Configuration
DB_PATH="./tracktor.db"

# File Upload Configuration
UPLOADS_DIR="./uploads"

# Application Features
TRACKTOR_DEMO_MODE=false
FORCE_DATA_SEED=false
TRACKTOR_DISABLE_AUTH=false

# Security
AUTH_PIN="123456"

# CORS Configuration
CORS_ORIGINS="*"

# Logging Configuration
LOG_REQUESTS=true
LOG_LEVEL="info"
LOG_DIR="./logs"
22 changes: 13 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: CI

on:
push:
branches: [main, dev]
branches: [main]
pull_request:
branches: [main, dev]
branches: [dev]

jobs:
lint-check-test-build:
Expand All @@ -17,20 +17,24 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "22"
cache: "npm"
node-version: '24'

- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: '10'

- name: Install dependencies
run: npm ci
run: pnpm install --frozen-lockfile

- name: Run linting
run: npm run lint
run: pnpm run lint

- name: Type checking
run: npm run check
run: pnpm run check

- name: Run tests
run: npm run test
run: pnpm run test

- name: Build application
run: npm run build
run: pnpm run build
6 changes: 3 additions & 3 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ name: Docker Build and Push

on:
push:
branches: [main]
tags: ["*.*.*"]
branches: [main, dev]
tags: ['*.*.*']

env:
REGISTRY: ghcr.io
Expand Down Expand Up @@ -49,7 +49,7 @@ jobs:
uses: docker/build-push-action@v5
with:
context: .
file: ./scripts/docker/Dockerfile
file: ./Dockerfile
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
Expand Down
13 changes: 2 additions & 11 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,25 +1,14 @@
.ropeproject
node_modules

# Environment files
.env

# Build outputs
dist/
build/
.svelte-kit/

# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Database
*.db
*.sqlite
*.sqlite3

# OS generated files
.DS_Store
Expand All @@ -34,3 +23,5 @@ Thumbs.db
.vscode/
temp/
**/*.db-journal

uploads/
2 changes: 2 additions & 0 deletions .pnpmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
auto-install-peers=false
strict-peer-dependencies=false
File renamed without changes.
File renamed without changes.
46 changes: 46 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Stage 1: Build the application
FROM node:22-alpine AS builder

# Set working directory
WORKDIR /app

# Install pnpm
RUN npm install -g pnpm

# Copy package files
COPY package.json pnpm-lock.yaml ./

# Install dependencies
RUN pnpm install --frozen-lockfile

# Copy source code
COPY . .

# Build the application
RUN pnpm run build

# Prune development dependencies to keep the image small
RUN pnpm prune --prod

# Stage 2: Create the production image
FROM node:22-alpine

# Set working directory
WORKDIR /app

# Copy built artifacts from builder stage
COPY --from=builder /app/build ./build
COPY --from=builder /app/node_modules ./node_modules
COPY --from=builder /app/package.json ./package.json
COPY --from=builder /app/migrations ./migrations

# Expose the port the app runs on
EXPOSE 3000

# Set environment variables
ENV NODE_ENV=production
ENV HOST=0.0.0.0
ENV PORT=3000

# Start the application
CMD ["node", "build"]
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
- 🛠️ **Maintenance Log:** Record and view maintenance history for each vehicle.
- 📄 **Document Tracking:** Track insurance, pollution certificates, and other important documents.
- 📊 **Dashboard:** Visualize key metrics and upcoming renewals.
- 🔒 **User Authentication:** Secure access to your data.
- 🔒 **User Authentication:** Secure username/password authentication with session management.

## 🖼️ images

Expand Down Expand Up @@ -103,7 +103,7 @@ This project is licensed under the MIT License. See the [LICENSE](LICENSE) file

## 📊 Repository activity

![Activities](https://repobeats.axiom.co/api/embed/d41931a72a5373ee0d2073e72279862171468023.svg "Repobeats analytics image")
![Activities](https://repobeats.axiom.co/api/embed/d41931a72a5373ee0d2073e72279862171468023.svg 'Repobeats analytics image')

## ⭐ Star History

Expand Down
7 changes: 0 additions & 7 deletions app/backend/.gitignore

This file was deleted.

17 changes: 0 additions & 17 deletions app/backend/drizzle.config.js

This file was deleted.

45 changes: 0 additions & 45 deletions app/backend/eslint.config.js

This file was deleted.

5 changes: 0 additions & 5 deletions app/backend/index.ts

This file was deleted.

75 changes: 0 additions & 75 deletions app/backend/jest.config.js

This file was deleted.

Loading