Files
documenso/apps/docs/content/docs/developers/local-development/manual.mdx
T
2026-05-14 15:07:10 +10:00

135 lines
3.0 KiB
Plaintext

---
title: Manual Setup
description: Manually set up Documenso on your machine for local development.
---
import { Callout } from 'fumadocs-ui/components/callout';
import { Step, Steps } from 'fumadocs-ui/components/steps';
# Manual Setup
Follow these steps to set up Documenso on your local machine:
{/* prettier-ignore */}
<Steps>
<Step>
### Fork Documenso
Fork the [Documenso repository](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/about-forks) to your GitHub account.
</Step>
<Step>
### Clone repository
After forking the repository, clone it to your local device by using the following command:
```bash
git clone https://github.com/<your-username>/documenso
```
</Step>
<Step>
### Install dependencies
Run `npm i` in the root directory to install the dependencies required for the project.
</Step>
<Step>
### Set up environment variables
Set up the following environment variables in the `.env` file:
```bash
NEXTAUTH_SECRET
NEXT_PUBLIC_WEBAPP_URL
NEXT_PRIVATE_DATABASE_URL
NEXT_PRIVATE_DIRECT_DATABASE_URL
NEXT_PRIVATE_SMTP_FROM_NAME
NEXT_PRIVATE_SMTP_FROM_ADDRESS
```
Alternatively, you can run `cp .env.example .env` to get started with our handpicked defaults.
<Callout type="info">
See the [Environment Variables](/docs/self-hosting/configuration/environment) page for more
information.
</Callout>
</Step>
<Step>
### Create database schema
Create the database schema by running the following command:
```bash
npm run prisma:migrate-dev
```
</Step>
<Step>
### Optional: seed the database
Seed the database with test data by running the following command:
```bash
npm run prisma:seed -w @documenso/prisma
```
</Step>
<Step>
### Optional: configure job provider
The default local job provider does not support scheduled jobs required for document reminders.
See the [Background Jobs](/docs/self-hosting/configuration/background-jobs) page for more information.
</Step>
<Step>
### Start the application
Run `npm run dev` in the root directory to start the application.
</Step>
<Step>
### Access the application
Access the Documenso application by visiting `http://localhost:3000` in your web browser.
</Step>
</Steps>
<Callout type="info">
Optional: Create your signing certificate. To generate your own using these steps and a Linux
Terminal or Windows Subsystem for Linux (WSL), see **[Create your signing
certificate](/docs/developers/local-development/signing-certificate)**.
</Callout>
## Running Scripts with Environment Variables
If a package script does not automatically load your `.env` and `.env.local` files, wrap it with the `with:env` script:
```bash
npm run with:env -- npm run myscript
```
The same works for `npx` when running bin scripts:
```bash
npm run with:env -- npx myscript
```
## See Also
- [Developer Quickstart](/docs/developers/local-development/quickstart) - Quick Docker-based setup
- [Signing Certificate](/docs/developers/local-development/signing-certificate) - Create a signing certificate