Skip to content
This repository was archived by the owner on Oct 30, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
105 commits
Select commit Hold shift + click to select a range
c0140af
Prototype app
jerzytab Sep 8, 2025
b39e9ff
Adding statistics & better car positioning
jerzytab Sep 8, 2025
def6e38
Engine change + base initialized project
NoKrecik Sep 10, 2025
3ca52f6
Added Vehicle base (not working) and fixed physics not updating
NoKrecik Sep 10, 2025
a2eedf4
Fixed initial wheels misalignment
NoKrecik Sep 10, 2025
faec14b
Added 'drei' controls to enviroment
NoKrecik Sep 11, 2025
738a9fc
Hooked up controls to the car
NoKrecik Sep 11, 2025
5456b2b
Added bunch of additional car settings
NoKrecik Sep 11, 2025
fd334df
Fixed wheel axle, cause im sztupid
NoKrecik Sep 11, 2025
41b3c3a
Tweaked vehicle settings and it works
NoKrecik Sep 11, 2025
bad8b6f
Merge remote-tracking branch 'origin/engine-change' into development
jerzytab Sep 11, 2025
522779a
Added ResourceLoader for preloading assets
NoKrecik Sep 11, 2025
f402dc4
Added simple camera to car
NoKrecik Sep 11, 2025
f939fee
Added some balls
NoKrecik Sep 11, 2025
6380f75
Improved camera smoothness
NoKrecik Sep 12, 2025
05ccd95
Added Model object, for easier model loading
NoKrecik Sep 12, 2025
5c86b03
Added model to the car, still janky but will do
NoKrecik Sep 12, 2025
b786647
Added map model, it's sick
NoKrecik Sep 12, 2025
0bb7ab7
Added colliders debugger
NoKrecik Sep 13, 2025
9f01c95
Cleaned up console prints
NoKrecik Sep 13, 2025
4a3d516
Added stats
NoKrecik Sep 15, 2025
0ddb0c2
Added sky
jerzytab Sep 15, 2025
741b519
Merge branch 'development' of https://github.com/The-Scripts/drive-th…
NoKrecik Sep 15, 2025
0b3b735
Set Damping
lukasz-stepien-dev Sep 15, 2025
7cc6f3a
Added delta
NoKrecik Sep 15, 2025
a916db3
Update README.md
jerzytab Sep 15, 2025
9db7669
Disable Caching in Nginx
jerzytab Sep 15, 2025
17b9e7a
Added collider generator for the map and created GameMap object
NoKrecik Sep 15, 2025
e52837b
Added car reverse
NoKrecik Sep 18, 2025
ff8ae3f
Added wheels models, and fixed same models loading bug
NoKrecik Sep 18, 2025
ea41a88
Wheels almost rotate correctly
NoKrecik Sep 18, 2025
b72906c
Connecting to the map via websocket
jerzytab Sep 18, 2025
3d5c444
Locked fps
jerzytab Sep 19, 2025
decb9ab
Set physics world to fixed 60 fps
NoKrecik Sep 19, 2025
abf210d
Added car deceleration
NoKrecik Sep 19, 2025
f250433
Fixed car not reversing bug
NoKrecik Sep 19, 2025
1a864ce
Chat
jerzytab Sep 19, 2025
003ae9d
Added car flip on 'r' key
NoKrecik Sep 19, 2025
242816c
Set physics world to fixed 60 fps
NoKrecik Sep 21, 2025
b29c2a9
Fixed vehicle physics update mismatch (causing car flipping on accele…
NoKrecik Sep 21, 2025
18c03d7
Added websocket to chat
jerzytab Sep 21, 2025
dd2e0c6
Added node server to docker
jerzytab Sep 21, 2025
6ae3993
Fixed chat
jerzytab Sep 22, 2025
626bdb8
Installed Jest & example tests
jerzytab Sep 22, 2025
953d251
Merge branch 'development' of https://github.com/The-Scripts/drive-th…
jerzytab Sep 22, 2025
d46cc4e
Merge branch 'development' into vehicle-improvements
NoKrecik Sep 22, 2025
255e999
Merge pull request #2 from The-Scripts/vehicle-improvements
NoKrecik Sep 22, 2025
d2d6624
Lep
NoKrecik Sep 22, 2025
5bf0618
Nowa płytka
NoKrecik Sep 22, 2025
7a604f2
Klejik
NoKrecik Sep 22, 2025
be5f4cb
Java
lukasz-stepien-dev Sep 22, 2025
d69442d
Update README.md
jerzytab Sep 22, 2025
94654c0
Add Brand, Category, Shop, User Entity
lukasz-stepien-dev Sep 23, 2025
474735a
Added Product Entity, Many To One products.category_fk:categories.id …
lukasz-stepien-dev Sep 24, 2025
a4b70b0
Replaced all args constructor with @AllArgsConstructor
lukasz-stepien-dev Sep 24, 2025
1af1a41
Added Brand, Category, Product, Shop, User repository
lukasz-stepien-dev Sep 24, 2025
8a4fdf4
Renamed repositories, changed extending CrudRepository instead of Jpa…
lukasz-stepien-dev Sep 24, 2025
7aff600
Now you can get product by shop or brand by API
lukasz-stepien-dev Sep 24, 2025
8d61875
Change path to get all products
lukasz-stepien-dev Sep 24, 2025
31aa7d7
Added product assets
NoKrecik Sep 25, 2025
85bc70b
Nwm
NoKrecik Sep 25, 2025
a22e3d4
preparation for tests
lukasz-stepien-dev Sep 25, 2025
f4fc2fb
Change port server to 5000
lukasz-stepien-dev Sep 25, 2025
9f88f27
Added Spawner base
NoKrecik Sep 26, 2025
9fbcc3d
Spawners now work
NoKrecik Sep 26, 2025
15f69ee
Added Spring Boot Starter Actuator
lukasz-stepien-dev Sep 28, 2025
462de04
Merge pull request #3 from The-Scripts/product-spawners
NoKrecik Sep 29, 2025
602bf0c
Quick fix
NoKrecik Sep 29, 2025
1a64ebc
Dozerized Spring Boot
jerzytab Sep 29, 2025
b2190be
Oinked README.md
NoKrecik Sep 29, 2025
9fd194a
Merge branch 'java' of https://github.com/The-Scripts/drive-thru into…
jerzytab Sep 29, 2025
a90986a
Merge remote-tracking branch 'origin/java' into development
jerzytab Sep 29, 2025
7d1df00
Revised README with table of contents and updates
jerzytab Sep 29, 2025
d5e3e39
Added trailing in /api/products/
lukasz-stepien-dev Sep 30, 2025
05aeab0
Removed trailing in /api/products/
lukasz-stepien-dev Sep 30, 2025
99482c4
Improved car physics?
NoKrecik Oct 2, 2025
43ea470
Added config files for testing API in Intelij
lukasz-stepien-dev Oct 3, 2025
8013ab6
Added profiles production, integration (fot integration tests), and u…
lukasz-stepien-dev Oct 6, 2025
3975f4e
Add qodana and integration tests
lukasz-stepien-dev Oct 6, 2025
96b2a64
Add pom.xml
lukasz-stepien-dev Oct 6, 2025
bd78e54
Updated pom.xml and ci.yml
lukasz-stepien-dev Oct 6, 2025
37bfdf7
Change branch name in ci.yml
lukasz-stepien-dev Oct 6, 2025
46a4104
Added report format
lukasz-stepien-dev Oct 6, 2025
ede31c2
give permissions to ci.yml
lukasz-stepien-dev Oct 6, 2025
543b37a
Sensors now detect collisions
NoKrecik Oct 6, 2025
53ee5f8
Merge branch 'development' of https://github.com/The-Scripts/drive-th…
NoKrecik Oct 6, 2025
fad7077
fix integration test
lukasz-stepien-dev Oct 6, 2025
a790edf
aaaaaaaa
lukasz-stepien-dev Oct 6, 2025
8a69078
Add qodana to java folder
lukasz-stepien-dev Oct 6, 2025
cb5a6c5
change maven compiler
lukasz-stepien-dev Oct 6, 2025
926b7c4
change pom.ml in java folder
lukasz-stepien-dev Oct 6, 2025
867779a
change java version in qodana
lukasz-stepien-dev Oct 6, 2025
eaaf8a1
add lombok annotation processor
lukasz-stepien-dev Oct 6, 2025
c3f6a46
Merge pull request #4 from The-Scripts/add-profiles-spring-boot
lukasz-stepien-dev Oct 6, 2025
d1f8da8
Make integration tests for products by shop and by brand
lukasz-stepien-dev Oct 6, 2025
28d52e6
WebConfig for Spring Boot
lukasz-stepien-dev Oct 7, 2025
35480a2
Added collisions group
NoKrecik Oct 13, 2025
376b804
Added pigz
NoKrecik Oct 13, 2025
fe56197
Update README.md
NoKrecik Oct 13, 2025
e4267d5
Reapir API & CROS error
jerzytab Oct 13, 2025
f292ef2
Merge branch 'development' of https://github.com/The-Scripts/drive-th…
jerzytab Oct 13, 2025
8932787
not fix
lukasz-stepien-dev Oct 13, 2025
c0c5c52
Added dependencies for tests
lukasz-stepien-dev Oct 13, 2025
9f97eaf
change pom.xml
lukasz-stepien-dev Oct 13, 2025
519681f
Add motto section to README
lukasz-stepien-dev Oct 27, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 57 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Java CI with Maven

on:
push:
branches: [ main, master, development ]
pull_request:
branches: [ main, master, development ]

permissions:
contents: read
actions: read
checks: write

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
cache: maven

- name: Build with Maven
run: mvn -B clean compile

- name: Run tests
run: mvn -B test
continue-on-error: true

- name: Publish Test Report
uses: dorny/test-reporter@v1
if: always()
with:
name: Maven Tests
path: '**/surefire-reports/TEST-*.xml'
reporter: java-junit
fail-on-error: true

- name: Upload test results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results
path: |
**/surefire-reports/*.xml
**/surefire-reports/*.txt

- name: Package application
if: success()
run: mvn -B package -DskipTests

54 changes: 54 additions & 0 deletions .github/workflows/qodana_code_quality.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
#-------------------------------------------------------------------------------#
# Discover all capabilities of Qodana in our documentation #
# https://www.jetbrains.com/help/qodana/about-qodana.html #
#-------------------------------------------------------------------------------#

name: Qodana Code Quality
on:
workflow_dispatch:
pull_request:
push:
branches:
- main
- master
- development

jobs:
qodana:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
checks: write
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0

- name: Set up JDK 25
uses: actions/setup-java@v4
with:
java-version: '25'
distribution: 'temurin'
cache: maven

- name: Build project with Maven
run: mvn -B clean compile -DskipTests

- name: 'Qodana Scan'
uses: JetBrains/qodana-action@v2025.2
env:
QODANA_TOKEN: ${{ secrets.QODANA_TOKEN }}
with:
# In pr-mode: 'true' Qodana checks only changed files
pr-mode: false
use-caches: true
post-pr-comment: true
use-annotations: true
# Upload Qodana results (SARIF, other artifacts, logs) as an artifact to the job
upload-result: true
# quick-fixes available in Ultimate and Ultimate Plus plans
push-fixes: 'none'
args: |
--baseline,qodana.sarif.json
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
data/
logs/
84 changes: 75 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,47 @@
# Drive Thru

This repository contains a Docker-based development setup for a React.js application. It includes services for:
- NGINX (web server)
- React
- Node.js
## 📑 Table of Contents
- [⚙️ Requirements](#️-requirements)
- [📖 Docs](#-docs)
- [🐳 Containers](#-containers)
- [🚀 Quick Start](#-quick-start)
- [1. Clone the repository](#1-clone-the-repository)
- [2. Install dependencies](#2-install-dependencies)
- [3. Start the application](#3-start-the-application)
- [4. Access the app](#4-access-the-app)
- [5. Other commands](#5-other-commands)
- [💭 Our Motto](#-our-motto)
- [📁 Project Structure](#-project-structure)
- [📸 Screenshots](#-screenshots)

---

## ⚙️ Requirements
- [Docker](https://www.docker.com/get-started) (latest version)
- [Docker Compose](https://docs.docker.com/compose/install/) (latest version)

## 📖 Docs
- [Tree.js](https://threejs.org/)
- [Rapier](https://rapier.rs/docs/)
- [Fiber.js](https://r3f.docs.pmnd.rs/getting-started/introduction)
- [Node](https://nodejs.org/docs/latest/api/)
- [WebSocket](https://developer.mozilla.org/en-US/docs/Web/API/WebSocket)
- [Jest](https://jestjs.io/docs/getting-started)
- [Spring Boot](https://spring.io/projects/spring-boot)
- [MySQL](https://dev.mysql.com/doc/)
- [Redis](https://redis.io/docs/latest/)
---

## 🐳 Containers
This repository contains a Docker-based development setup for a React.js application. It includes services for:
- NGINX (web server)
- React
- Node.js
- Java
- MySQL
- Redis
- npm

## 🚀 Quick Start
### 1. Clone the repository
```bash
Expand All @@ -18,9 +50,13 @@ cd drive-thru
```

### 2. Install dependencies
```bash
Build docker-compose:
```bash
docker-compose build
docker-compose run --rm npm install
```
Install node.js:
```bash
docker-compose run --rm npm install
```

### 3. Start the application
Expand All @@ -29,7 +65,15 @@ To run the application, you can choose one of the following:
```bash
docker-compose up react
```
- Run both NGINX and React.js app:
- Run only Node.js server:
```bash
docker-compose up node
```
- Run Java server + MySQL:
```bash
docker-compose up java
```
- Run the entire app:
```bash
docker-compose up server
````
Expand All @@ -38,7 +82,7 @@ docker-compose up server
> Visit the NGINX proxy: http://localhost:8000
---

### 4. Other commands
### 5. Other commands
```bash
> Install dependencies: docker-compose run --rm npm install {dependencies}
> Stop containers: docker-compose stop
Expand All @@ -50,6 +94,28 @@ docker-compose up server
.
├── dockerfiles/ # Custom Dockerfiles (nginx, node)
├── nginx/ # NGINX configuration
├── env/ # ENV
├── src/ # React.js application
| └── Drive Thru Java/ # Spring Boot Backend
| └── src/
| └── CoreComponents/ #
| └── CoreHelpers/ #
| └── EnviromentPresets/ #
| └── Objects/ #
| └── Ui/ #
| └── App.jsx # Application React file
| └── main.jsx # Main React file
| └── server.js #
└── docker-compose.yaml # Main Docker orchestration file
```

```
## 💭 Our Motto
<img width="2500" height="1080" alt="More doing than talking" src="https://github.com/user-attachments/assets/3821f825-69c7-4cfe-b1a9-d5f4455d8812" />


## 📸 Screenshots
<img width="1115" height="795" alt="image" src="https://github.com/user-attachments/assets/c14ebe0c-0443-417e-822c-3f79b7152f22" />

<img width="1711" height="797" alt="image" src="https://github.com/user-attachments/assets/87419bd1-441b-4bfd-a60f-40e340e788af" />

![pat](https://czechmovie.com/cdn/shop/articles/pat_a_mat_a.jpg?v=1684742662)
41 changes: 38 additions & 3 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
version: "3.8"

services:
server:
container_name: server
Expand All @@ -13,6 +11,8 @@ services:
- ./nginx/nginx.conf:/etc/nginx/conf.d/default.conf:ro
depends_on:
- react
- node
- java
react:
container_name: react
build:
Expand All @@ -23,10 +23,45 @@ services:
command: ["npm", "run", "dev", "--", "--host", "--port", "3000"]
ports:
- "3000:3000"
node:
container_name: node
build:
context: .
dockerfile: dockerfiles/node.dockerfile
command: ["node", "server.js", "--port", "4444"]
ports:
- "4444:4444"
java:
container_name: java
build:
context: .
dockerfile: dockerfiles/java.dockerfile
env_file:
- ./env/spring.env
ports:
- "5000:5000"
depends_on:
mysql:
condition: service_healthy

mysql:
container_name: mysql
image: mysql:8.0
env_file:
- ./env/mysql.env
ports:
- "3306:3306"
volumes:
- ./data/mysql:/var/lib/mysql
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
interval: 5s
timeout: 5s
retries: 10
npm:
container_name: npm
image: node:22-slim
working_dir: /app
entrypoint: ["npm"]
volumes:
- ./src:/app
- ./src:/app
17 changes: 17 additions & 0 deletions dockerfiles/java.dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
FROM maven:3.9.5-eclipse-temurin-21 AS build

WORKDIR /app/project

COPY ["src/Drive Thru Java/pom.xml", "./"]
COPY ["src/Drive Thru Java/.mvn", "./.mvn"]
COPY ["src/Drive Thru Java/src", "./src"]

RUN mvn clean package -DskipTests

FROM eclipse-temurin:21-jdk-jammy

WORKDIR /app

COPY --from=build /app/project/target/*.jar app.jar

ENTRYPOINT ["java", "-jar", "app.jar"]
4 changes: 4 additions & 0 deletions env/mysql.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
MYSQL_ROOT_PASSWORD=toor
MYSQL_DATABASE=drive_thru
MYSQL_USER=driveuser
MYSQL_PASSWORD=drivepass
8 changes: 8 additions & 0 deletions env/spring.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
SPRING_DATASOURCE_URL=jdbc:mysql://mysql:3306/drive_thru
SPRING_DATASOURCE_USERNAME=driveuser
SPRING_DATASOURCE_PASSWORD=drivepass
SPRING_JPA_HIBERNATE_DDL_AUTO=update
SPRING_JPA_SHOW_SQL=true
SPRING_JPA_DATABASE_PLATFORM=org.hibernate.dialect.MySQLDialect
SERVER_PORT=5000
SPRING_PROFILES_ACTIVE=dev
26 changes: 26 additions & 0 deletions nginx/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,38 @@
listen 80;
server_name localhost;

location /assets/ {
alias /app/public/assets/;
add_header Cache-Control "public, max-age=3600";
}

location /api/ {
proxy_pass http://java:5000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;

add_header Cache-Control "no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0";
add_header Pragma "no-cache";
add_header Expires 0;
proxy_no_cache 1;
proxy_cache_bypass 1;
}

location / {
proxy_pass http://react:3000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;

add_header Cache-Control "no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0";
add_header Pragma "no-cache";
add_header Expires 0;
proxy_no_cache 1;
proxy_cache_bypass 1;
}
}
Loading