chore: update environment configuration and enhance Prisma integration
Some checks failed
Lint and Check Types / validations (push) Failing after 47s

- Added MINIO_PORT to .env.example for Minio configuration.
- Updated package.json to include a script for Prisma generation.
- Modified turbo.json to ensure db:generate task is executed during build and dev processes.
- Updated CI workflow to run Prisma generate step.
- Adjusted imports in the API to reference the generated Prisma client correctly.
- Added .gitignore entry for Prisma client directory.
This commit is contained in:
Juan Sebastián Montoya 2025-05-06 18:36:47 -05:00
parent bb4deff66b
commit c7911953df
10 changed files with 20 additions and 8 deletions

3
apps/api/.gitignore vendored
View file

@ -56,3 +56,6 @@ profile-*
profile*
*clinic*
*flamegraph*
# prisma
prisma/client

View file

@ -6,6 +6,7 @@
generator client {
provider = "prisma-client-js"
output = "./client"
}
datasource db {

View file

@ -3,7 +3,7 @@ import dotenv from 'dotenv';
import path from 'path';
const rootDir = path.resolve(process.cwd(), '../../');
dotenv.config({ path: `${rootDir}/.env.local` });
dotenv.config({ path: `${rootDir}/.env` });
const schema = z
.object({

View file

@ -4,7 +4,7 @@ import fastifyCookie from '@fastify/cookie';
import fastifyCors from '@fastify/cors';
import mercurius from 'mercurius';
import mercuriusCodegen from 'mercurius-codegen';
import { PrismaClient } from '@prisma/client';
import { PrismaClient } from '../prisma/client';
import config from './config';
import { resolvers } from './resolvers';
import schema from './schema';

View file

@ -2,7 +2,7 @@ import jwt from 'jsonwebtoken';
import { v4 as uuidv4 } from 'uuid';
import crypto from 'crypto';
import { TokenConfig } from '../config';
import { PrismaClient } from '@prisma/client';
import { PrismaClient } from '../../prisma/client';
import { MemcService } from './memc.service';
type TransactionClient = Omit<

View file

@ -1,4 +1,4 @@
import { PrismaClient } from '@prisma/client';
import type { PrismaClient } from '../prisma/client';
import {
MinioService,
TokenService,