Most Instal Doc tutorial on NAT VPS


Natvps.idDocument is a WIKI application and collaborative documentation that is Open-source. Docmost can be an alternative to notion or confluence, where you hold full control of your data.

This article discusses the steps to install docmost on NAT VPS using a docker, along with the Nginx configuration for Reverse-Proxy. This article uses Ubuntu 22.04 as a reference, but you can use other distributions such as Debian and Centos. Make sure the OS used supports the docker.

Port forwarding configuration

Considering we use grout, we need to add 2 Port Forwarding Configuration on the virtualizor panel (or other VPS panels according to the provider), namely Port Forwarding HTTP and HTTPS For the document domain.

For example, in this article will use a domain docmost.tutorial.mdinata.my.id to access Docmost. You are free to change the domain according to your choice. Record this port and domain, because we will use it again in the deploy process.

Don’t forget to add DNS Records to go to your NAT VPS public IP, like this:

Install Docker

We will use a docker and compile a docker for spread Document

First, install curly Using Orders:

apt update && apt install curl -y

Then, run manuscript Automatic installation from the docker by entering:

curl -fsSL get.docker.com | sh

Wait until the installation process is complete.

Install Docmost

First, create a new folder for documents.

mkdir docmost
cd docmost/

Download the Docker Compose configuration file from the official Docmost repository:

curl -O 

Then, open the file docker-compose.yml:

nano docker-compose.yml

Change the following variables:

  • Change APP_URL With your document domain, for example: https://docmost.tutorial.mdinata.my.id.
  • Change APP_SECRET with random text along 32 characters. You can use a website like https://www.random.org/strings/.

Other variables do not need to be changed.

Save the file.

Other configurations do not need to be changed, but you are free to change it if necessary.

Run Docmost:

docker compose up -d

Wait until the process spread finished. Deploy can first take a few minutes because it has to download all picture Docmost and database from the beginning.

Nginx Configuration (Reverse Proxy)

So that we can access the URL through a domain like docmost.tutorial.mdinata.my.idwe can use Reverse Proxy Like Nginx.

First, install Nginx through the command:

# Hapus Apache2 dan pendukungnya (biasanya terpasang secara bawaan di VPS OpenVZ)
apt purge apache2* -y

# Install NGINX
apt install nginx -y

Create a new host configuration specifically for docmost:

nano /etc/nginx/sites-available/docmost

Then stick the following configuration:

# 

server {
    listen 80;
    listen [::]:80;
    server_name docmost.tutorial.mdinata.my.id;

    location / {
        proxy_pass         
        proxy_http_version 1.1;
        proxy_set_header   Upgrade $http_upgrade;
        proxy_set_header   Connection "upgrade";
        proxy_set_header   Host $host;
        proxy_set_header   X-Real-IP $remote_addr;
        proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header   X-Forwarded-Proto $scheme;

        # Avoid timeouts during big uploads
        proxy_read_timeout 300;
        proxy_send_timeout 300;
    }
}

Change docmost.tutorial.mdinata.my.id with your domain.

Activate the configuration with:

ln -sf /etc/nginx/sites-available/docmost /etc/nginx/sites-enabled/docmost

# Restart NGINX
systemctl restart nginx

Produce SSL certificate (let’s encryption)

So that our domain can be accessed through HTTPS, we need to make a SSL certificate. We can use a free SSL certificate from Let’s Encrypt through Certbot.

Install Certbot and Nginx plugin use the command:

apt install python3-certbot python3-certbot-nginx

So, produce Certificate through Certbot with the command

certbot --nginx -d docmost.tutorial.mdinata.my.id

Change docmost.tutorial.mdinata.my.id with your domain.

Happy! Your current domain can be accessed via a safe connection https.

Access the docmost dashboard

Docmost can be accessed through your previous domain. Example: https://docmost.tutorial.mdinata.my.id.

Cover

Thus this article is about the steps to install Docmost on NAT VPS. If you are confused or doubtful, don’t hesitate to ask questions in the telegram group @ipv6indonesia. Thank You!



Game Center

Game News

Review Film
Rumus Matematika
Anime Batch
Berita Terkini
Berita Terkini
Berita Terkini
Berita Terkini
review anime

Gaming Center