2024-04-28 23:57:52 -06:00
# Contributing
Hey, thanks for your interest in contributing to Dokploy! We appreciate your help and taking your time to contribute.
2026-02-08 23:13:19 -06:00
Before you start, please first discuss the feature/bug you want to add with the owners and community via github issues.
2024-04-28 23:57:52 -06:00
We have a few guidelines to follow when contributing to this project:
- [Commit Convention ](#commit-convention )
- [Setup ](#setup )
- [Development ](#development )
- [Build ](#build )
- [Pull Request ](#pull-request )
2026-02-08 23:13:19 -06:00
- [Important Considerations ](#important-considerations-for-pull-requests )
2024-04-28 23:57:52 -06:00
## Commit Convention
2024-07-29 23:08:23 -06:00
Before you create a Pull Request, please make sure your commit message follows the [Conventional Commits ](https://www.conventionalcommits.org/en/v1.0.0/ ) specification.
2024-04-28 23:57:52 -06:00
### Commit Message Format
2024-07-29 23:08:23 -06:00
2024-04-28 23:57:52 -06:00
```
<type>[optional scope]: <description>
[optional body]
[optional footer(s)]
```
#### Type
2024-07-29 23:08:23 -06:00
2024-04-28 23:57:52 -06:00
Must be one of the following:
2024-07-29 23:08:23 -06:00
- **feat**: A new feature
- **fix**: A bug fix
- **docs**: Documentation only changes
- **style**: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc)
- **refactor**: A code change that neither fixes a bug nor adds a feature
- **perf**: A code change that improves performance
- **test**: Adding missing tests or correcting existing tests
- **build**: Changes that affect the build system or external dependencies (example scopes: gulp, broccoli, npm)
- **ci**: Changes to our CI configuration files and scripts (example scopes: Travis, Circle, BrowserStack, SauceLabs)
- **chore**: Other changes that don't modify `src` or `test` files
- **revert**: Reverts a previous commit
2024-04-28 23:57:52 -06:00
Example:
2024-07-29 23:08:23 -06:00
2024-04-28 23:57:52 -06:00
```
feat: add new feature
```
## Setup
2024-05-01 20:00:03 -06:00
Before you start, please make the clone based on the `canary` branch, since the `main` branch is the source of truth and should always reflect the latest stable release, also the PRs will be merged to the `canary` branch.
2026-02-18 11:19:04 -06:00
We use Node v24.4.0 and recommend this specific version. If you have nvm installed, you can run `nvm install 24.4.0 && nvm use` in the root directory.
2025-01-12 14:29:43 -06:00
2024-04-28 23:57:52 -06:00
``` bash
git clone https://github.com/dokploy/dokploy.git
cd dokploy
2024-05-01 00:04:20 -06:00
pnpm install
2024-07-29 23:08:23 -06:00
cp apps/dokploy/.env.example apps/dokploy/.env
2024-04-28 23:57:52 -06:00
```
2025-03-11 14:38:37 +03:00
## Requirements
2024-04-28 23:57:52 -06:00
2025-03-11 14:38:37 +03:00
- [Docker ](/GUIDES.md#docker )
2024-04-28 23:57:52 -06:00
2024-05-01 00:04:20 -06:00
### Setup
2024-05-01 01:29:35 -06:00
Run the command that will spin up all the required services and files.
2024-05-01 00:04:20 -06:00
``` bash
2024-07-29 23:08:23 -06:00
pnpm run dokploy:setup
2024-05-01 00:04:20 -06:00
```
2025-01-12 14:29:43 -06:00
Run this script
2024-10-25 00:21:12 -06:00
``` bash
2025-01-12 14:29:43 -06:00
pnpm run server:script
2024-10-25 00:21:12 -06:00
```
2024-05-01 00:04:20 -06:00
Now run the development server.
``` bash
2024-07-29 23:08:23 -06:00
pnpm run dokploy:dev
2024-05-01 00:04:20 -06:00
```
2024-04-28 23:57:52 -06:00
Go to http://localhost:3000 to see the development server
2025-08-03 17:50:29 +09:00
> [!NOTE]
> This project uses Biome. If your editor is configured to use another formatter such as Prettier, it's recommended to either change it to use Biome or turn it off.
2025-04-15 14:38:37 -07:00
2024-04-28 23:57:52 -06:00
## Build
``` bash
2024-07-29 23:08:23 -06:00
pnpm run dokploy:build
2024-04-28 23:57:52 -06:00
```
## Docker
To build the docker image
2024-07-29 23:08:23 -06:00
2024-04-28 23:57:52 -06:00
``` bash
2024-05-01 00:04:20 -06:00
pnpm run docker:build
2024-04-28 23:57:52 -06:00
```
To push the docker image
2024-07-29 23:08:23 -06:00
2024-04-28 23:57:52 -06:00
``` bash
2024-05-01 00:04:20 -06:00
pnpm run docker:push
2024-04-28 23:57:52 -06:00
```
## Password Reset
In the case you lost your password, you can reset it using the following command
``` bash
2024-05-11 16:58:55 +08:00
pnpm run reset-password
2024-04-28 23:57:52 -06:00
```
2025-08-03 17:50:29 +09:00
If you want to test the webhooks on development mode using localtunnel, make sure to install [`localtunnel` ](https://localtunnel.app/ )
2024-04-28 23:57:52 -06:00
``` bash
2025-08-03 17:50:29 +09:00
pnpm dlx localtunnel --port 3000
2024-04-28 23:57:52 -06:00
```
If you run into permission issues of docker run the following command
``` bash
sudo chown -R USERNAME dokploy or sudo chown -R $( whoami) ~/.docker
```
## Application deploy
In case you want to deploy the application on your machine and you selected nixpacks or buildpacks, you need to install first.
``` bash
# Install Nixpacks
curl -sSL https://nixpacks.com/install.sh -o install.sh \
&& chmod +x install.sh \
&& ./install.sh
```
2025-03-05 00:18:10 -06:00
``` bash
# Install Railpack
curl -sSL https://railpack.com/install.sh | sh
```
2024-04-28 23:57:52 -06:00
``` bash
# Install Buildpacks
2025-12-16 21:06:40 +00:00
curl -sSL "https://github.com/buildpacks/pack/releases/download/v0.39.1/pack-v0.39.1-linux.tgz" | tar -C /usr/local/bin/ --no-same-owner -xzv pack
2024-04-28 23:57:52 -06:00
```
## Pull Request
2025-08-03 13:21:02 -06:00
- The `canary` branch is the source of truth and should always reflect the latest stable release.
2024-04-28 23:57:52 -06:00
- Create a new branch for each feature or bug fix.
- Make sure to add tests for your changes.
- Make sure to update the documentation for any changes Go to the [docs.dokploy.com ](https://docs.dokploy.com ) website to see the changes.
- When creating a pull request, please provide a clear and concise description of the changes made.
- If you include a video or screenshot, would be awesome so we can see the changes in action.
- If your pull request fixes an open issue, please reference the issue in the pull request description.
- Once your pull request is merged, you will be automatically added as a contributor to the project.
2026-02-08 23:13:19 -06:00
### Important Considerations for Pull Requests
2025-08-03 13:21:02 -06:00
2026-02-08 23:13:19 -06:00
- **Testing is Mandatory:** All Pull Requests **must be tested ** before submission. You must verify that your changes work as expected in a local development environment (see [Setup ](#setup )). **Pull Requests that have not been tested will be closed. ** This policy ensures clean contributions and reduces the time maintainers spend reviewing untested or broken code.
2025-08-03 13:21:02 -06:00
- **Focus and Scope:** Each Pull Request should ideally address a single, well-defined problem or introduce one new feature. This greatly facilitates review and reduces the chances of introducing unintended side effects.
- **Avoid Unfocused Changes:** Please avoid submitting Pull Requests that contain only minor changes such as whitespace adjustments, IDE-generated formatting, or removal of unused variables, unless these are part of a larger, clearly defined refactor or a dedicated "cleanup" Pull Request that addresses a specific `good first issue` or maintenance task.
- **Issue Association:** For any significant change, it's highly recommended to open an issue first to discuss the proposed solution with the community and maintainers. This ensures alignment and avoids duplicated effort. If your PR resolves an existing issue, please link it in the description (e.g., `Fixes #123` , `Closes #456` ).
2024-05-11 16:58:55 +08:00
Thank you for your contribution!
2024-06-02 15:26:28 -06:00
## Templates
2025-03-11 01:36:20 -06:00
To add a new template, go to `https://github.com/Dokploy/templates` repository and read the README.md file.
2024-06-02 15:26:28 -06:00
2024-11-09 18:16:06 +08:00
### Recommendations
2024-07-29 23:08:23 -06:00
2024-06-02 15:26:28 -06:00
- Use the same name of the folder as the id of the template.
- The logo should be in the public folder.
2024-12-07 17:01:32 -05:00
- If you want to show a domain in the UI, please add the `_HOST` suffix at the end of the variable name.
2024-06-02 15:26:28 -06:00
- Test first on a vps or a server to make sure the template works.
2024-10-27 22:22:39 -06:00
## Docs & Website
2024-07-29 23:08:23 -06:00
2024-10-27 22:22:39 -06:00
To contribute to the Dokploy docs or website, please go to this [repository ](https://github.com/Dokploy/website ).