{"id":26593714,"url":"https://github.com/igorkrupenja/nestjs-starter","last_synced_at":"2026-04-08T18:31:42.873Z","repository":{"id":281495487,"uuid":"945453707","full_name":"IgorKrupenja/nestjs-starter","owner":"IgorKrupenja","description":"A simple NestJS starter with Prisma, Postgres — and 100% test coverage 🚀","archived":false,"fork":false,"pushed_at":"2025-03-23T11:28:33.000Z","size":518,"stargazers_count":1,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-23T12:26:05.720Z","etag":null,"topics":["backend","nestjs","nodejs","prisma","vitest"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/IgorKrupenja.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-03-09T13:14:08.000Z","updated_at":"2025-03-09T19:03:24.000Z","dependencies_parsed_at":"2025-03-09T14:34:37.543Z","dependency_job_id":null,"html_url":"https://github.com/IgorKrupenja/nestjs-starter","commit_stats":null,"previous_names":["igorkrupenja/nestjs-starter"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IgorKrupenja%2Fnestjs-starter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IgorKrupenja%2Fnestjs-starter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IgorKrupenja%2Fnestjs-starter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/IgorKrupenja%2Fnestjs-starter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/IgorKrupenja","download_url":"https://codeload.github.com/IgorKrupenja/nestjs-starter/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245120143,"owners_count":20563863,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["backend","nestjs","nodejs","prisma","vitest"],"created_at":"2025-03-23T15:20:03.837Z","updated_at":"2026-04-08T18:31:42.862Z","avatar_url":"https://github.com/IgorKrupenja.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NestJS starter\n\n## Description\n\nNestJS starter project. Uses Postgres and Prisma ORM.\n\n## Set up the project\n\nThis project requires a Node.js version specified in the `package.json` file. If you do not have it, the easiest option is to install [nvm](https://github.com/nvm-sh/nvm#installing-and-updating).\n\nRun the following commands **or just the `./setup.sh` that will do this automatically** (and will also install `nvm` if it's missing). This script is especially useful if you are not a Node developer and do not have all the tools ready.\n\n```bash\n# Install the correct Node version\nnvm install\n# Install the correct pnpm version\ncorepack enable pnpm\ncorepack install\n# Install dependencies\npnpm install\n# Start DB\ndocker compose up db -d --wait\n# Prepare Prisma\npnpm exec prisma migrate dev\npnpm exec prisma generate\npnpm exec prisma db seed\n```\n\n## Environment Variables\n\nEnvironment-specific configuration files are located in the `config/` folder:\n\n- `config/development.env` - Local development settings (with values)\n- `config/production.env` - Production template (variable names only, values set via environment)\n- `config/test.env` - Test environment settings (with values)\n\nThe application automatically loads the appropriate config file based on the `NODE_ENV` environment variable.\n\n| Variable                    | Description                                                          | Required | Default Value    | Recommended Production Value               |\n| --------------------------- | -------------------------------------------------------------------- | -------- | ---------------- | ------------------------------------------ |\n| `DATABASE_URL`              | PostgreSQL connection string                                         | ✅ Yes   |                  |                                            |\n| `LOGGER_LOG_LEVELS`         | Comma-separated log levels (log, error, warn, debug, verbose, fatal) |          | `error,warn,log` | `error,warn,log`                           |\n| `LOGGER_COLORS`             | Enable colored console output                                        |          | `false`          | `false`                                    |\n| `API_DOCUMENTATION_ENABLED` | Enable Swagger API documentation                                     |          | `false`          | `false`                                    |\n| `API_CORS_ORIGIN`           | CORS allowed origins (can be comma-separated list)                   |          | (empty string)   | Configure based on your frontend domain(s) |\n\n## Run the project\n\n```bash\npnpm run dev\n```\n\n## Run tests\n\n### Unit tests\n\n```bash\n# Unit tests in watch mode\npnpm run test\n\n# Unit tests (run once)\npnpm run test:run\n\n# Test coverage\npnpm run test:cov\n```\n\n### E2E tests\n\n```bash\n# Set up test database (starts container + runs migrations)\npnpm run test:e2e:setup\n\n# E2E tests in watch mode\npnpm run test:e2e\n\n# E2E tests (run once)\npnpm run test:e2e:run\n```\n\n**Note:** E2E tests use a separate PostgreSQL database (port 5433) for complete isolation from development data (port 5432).\n\n## Lint\n\n```bash\npnpm run lint\n```\n\n## Format\n\n```bash\npnpm run format\n```\n\n## Swagger Documentation\n\nAutomatically generated API documentation can be found\nat [http://localhost:3000/documentation](http://localhost:3000/documentation)\n\n## Client Types\n\nRun `pnpm generate-client-types` to regenerate `client/index.d.ts` from the OpenAPI spec.\n\n## Testing Docker image\n\n**You should NEVER use this to run locally**. This is only for testing the Docker image.\n\n```bash\ndocker build -t nestjs-starter . --no-cache\n\ndocker run \\\n    -p 3000:3000 \\\n    -e DATABASE_URL=\"postgresql://postgres:postgres@host.docker.internal:5432/nestjs_starter?schema=starter\" \\\n    nestjs-starter\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Figorkrupenja%2Fnestjs-starter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Figorkrupenja%2Fnestjs-starter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Figorkrupenja%2Fnestjs-starter/lists"}