Link to the doc (#695)

This commit is contained in:
Sung 2025-10-19 01:01:26 -07:00 committed by GitHub
commit 41f25514f0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 22 additions and 122 deletions

View file

@ -51,8 +51,8 @@ services:
restart: unless-stopped
```
Or see the [guide](https://github.com/dnote/dnote/blob/master/SELF_HOSTING.md) for binary installation and configuration options.
Or see the [guide](https://www.getdnote.com/docs/server/manual) for binary installation.
## Documentation
See the [Dnote wiki](https://github.com/dnote/dnote/wiki) for full documentation.
See the [Dnote doc](https://www.getdnote.com/docs).

View file

@ -1,8 +1,33 @@
# Self-Hosting Dnote Server
For Docker installation, see [the Docker guide](https://github.com/dnote/dnote/blob/master/host/docker/README.md).
Please see the [doc](https://www.getdnote.com/docs/server) for more.
## Quick Start
## Docker Installation
1. Install [Docker](https://docs.docker.com/install/).
2. Install Docker [Compose plugin](https://docs.docker.com/compose/install/linux/).
3. Download the [compose.yml](https://raw.githubusercontent.com/dnote/dnote/master/host/docker/compose.yml) file by running:
```
curl https://raw.githubusercontent.com/dnote/dnote/master/host/docker/compose.yml > compose.yml
```
4. Run the following to download the images and run the containers
```
docker compose pull
docker compose up -d
```
Visit http://localhost:3001 in your browser to see Dnote running.
### Supported platform
Currently, the official Docker image for Dnote supports Linux running AMD64 CPU architecture.
If you run ARM64, please install Dnote server by downloading a binary distribution (see below).
## Manual Installation
Download from [releases](https://github.com/dnote/dnote/releases), extract, and run:
@ -15,98 +40,3 @@ dnote-server start --webUrl=https://your.server
You're up and running. Database: `~/.local/share/dnote/server.db` (customize with `--dbPath`). Run `dnote-server start --help` for options.
Set `apiEndpoint: https://your.server/api` in `~/.config/dnote/dnoterc` to connect your CLI to the server.
## Optional guide
### Nginx
Create `/etc/nginx/sites-enabled/dnote`:
```
server {
server_name my-dnote-server.com;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $host;
proxy_pass http://127.0.0.1:3001;
}
}
```
Replace `my-dnote-server.com` with your domain, then reload:
```bash
sudo service nginx reload
```
### Apache2
Enable `mod_proxy`, then create `/etc/apache2/sites-available/dnote.conf`:
```
<VirtualHost *:80>
ServerName notes.example.com
ProxyRequests Off
ProxyPreserveHost On
ProxyPass / http://127.0.0.1:3001/ keepalive=On
ProxyPassReverse / http://127.0.0.1:3001/
RequestHeader set X-Forwarded-HTTPS "0"
</VirtualHost>
```
Enable and restart:
```bash
a2ensite dnote
sudo service apache2 restart
```
### TLS
Use LetsEncrypt to obtain a certificate and configure HTTPS in your reverse proxy.
### systemd Daemon
Create `/etc/systemd/system/dnote.service`:
```
[Unit]
Description=Starts the dnote server
Requires=network.target
After=network.target
[Service]
Type=simple
User=$user
Restart=always
RestartSec=3
WorkingDirectory=/home/$user
ExecStart=/usr/local/bin/dnote-server start --webUrl=$WebURL
[Install]
WantedBy=multi-user.target
```
Replace `$user` and `$WebURL`. Add `--dbPath` to `ExecStart` if you want a custom database location.
Enable and start:
```bash
sudo systemctl daemon-reload
sudo systemctl enable dnote
sudo systemctl start dnote
```
### Email Support
If you want emails, add these environment variables:
- `SmtpHost` - SMTP hostname
- `SmtpPort` - SMTP port
- `SmtpUsername` - SMTP username
- `SmtpPassword` - SMTP password
For systemd, add as `Environment=` lines in the service file.

View file

@ -1,30 +0,0 @@
# Dnote Docker Image
The official Dnote docker image.
## Installing Dnote Server Using Docker
1. Install [Docker](https://docs.docker.com/install/).
2. Install Docker [Compose plugin](https://docs.docker.com/compose/install/linux/).
3. Download the [compose.yml](https://raw.githubusercontent.com/dnote/dnote/master/host/docker/compose.yml) file by running:
```
curl https://raw.githubusercontent.com/dnote/dnote/master/host/docker/compose.yml > compose.yml
```
4. Run the following to download the images and run the containers
```
docker compose pull
docker compose up -d
```
Visit http://localhost:3001 in your browser to see Dnote running.
Please see [the installation guide](https://github.com/dnote/dnote/blob/master/SELF_HOSTING.md) for further configuration.
## Supported platform
Currently, the official Docker image for Dnote supports Linux running AMD64 CPU architecture.
If you run ARM64, please install Dnote server by downloading a binary distribution by following [the guide](https://github.com/dnote/dnote/blob/master/SELF_HOSTING.md).