Skip to content

Commit bc03a0c

Browse files
committed
feat: implement auth, jwt, and user modules
1 parent 9c83bba commit bc03a0c

File tree

24 files changed

+482
-90
lines changed

24 files changed

+482
-90
lines changed

.env-example

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,7 @@ LANGCHAIN_CALLBACKS_BACKGROUND=true
44

55
GOOGLE_GENAI_API_KEY=
66

7-
REDIS_ENDPOINT_URI=localhost:6379
8-
REDIS_PASSWORD=redis@dev
7+
REDIS_ENDPOINT_URI=redis://127.0.0.1:6379
8+
REDIS_PASSWORD=
9+
10+
DATABASE_URL="postgres://postgres:devPassword@localhost:5432/app_db?schema=public"

.vscode/settings.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"cSpell.words": [
3+
"dataprovider",
34
"dataproviders",
45
"gemini",
56
"nodenext",

docker-compose.yaml

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
version: '3.8'
2-
31
services:
42
app:
3+
container_name: genai_app
54
build:
65
context: .
76
dockerfile: Dockerfile
@@ -12,29 +11,31 @@ services:
1211
volumes:
1312
- ./src:/usr/workspace/app/src
1413
- pnpm_store:/pnpm/.pnpm-store
15-
command: sh -c "pnpm install && pnpm dev"
14+
command: sh -c "pnpm install && npx prisma generate && pnpm dev"
1615

1716
postgres:
17+
container_name: genai_app_postgres
1818
image: bitnami/postgresql:latest
1919
ports:
2020
- '5432:5432'
2121
environment:
22-
- POSTGRES_USER=docker
23-
- POSTGRES_PASSWORD=docker
24-
- POSTGRES_DB=rag_app
22+
- POSTGRES_USER=genaiapp
23+
- POSTGRES_PASSWORD=password
24+
- POSTGRES_DB=genaiapp_db
2525
volumes:
26-
- 'rag_app_postgres_data:/bitnami/postgresql'
26+
- 'genai_app_postgres_data:/bitnami/postgresql'
2727

2828
redis:
29+
container_name: genai_app_redis
2930
image: bitnami/redis:latest
3031
ports:
3132
- '6379:6379'
3233
environment:
3334
- ALLOW_EMPTY_PASSWORD=yes
3435
volumes:
35-
- 'rag_app_redis_data:/bitnami/redis/data'
36+
- 'genai_app_redis_data:/bitnami/redis/data'
3637

3738
volumes:
3839
pnpm_store:
39-
rag_app_redis_data:
40-
rag_app_postgres_data:
40+
genai_app_redis_data:
41+
genai_app_postgres_data:

package.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,11 @@
2020
"@langchain/core": "^0.3.3",
2121
"@langchain/google-genai": "^0.1.0",
2222
"@langchain/redis": "^0.1.0",
23+
"@prisma/client": "5.20.0",
2324
"@types/redis": "^4.0.11",
2425
"dotenv": "^16.4.5",
2526
"express": "^4.21.0",
27+
"jsonwebtoken": "^9.0.2",
2628
"langchain": "^0.3.2",
2729
"multer": "1.4.5-lts.1",
2830
"pdf-parse": "^1.1.1",
@@ -31,10 +33,12 @@
3133
"devDependencies": {
3234
"@types/cors": "^2.8.17",
3335
"@types/express": "^4.17.21",
36+
"@types/jsonwebtoken": "^9.0.7",
3437
"@types/multer": "^1.4.12",
3538
"@types/node": "^22.5.5",
3639
"cors": "^2.8.5",
3740
"nodemon": "^3.1.4",
41+
"prisma": "^5.20.0",
3842
"ts-node": "^10.9.2",
3943
"tslib": "^2.7.0",
4044
"tsx": "^4.19.1",

0 commit comments

Comments
 (0)