Deploying ToolJet on Cloud VPS: Building Low-Code Internal Admin Tools with Multi-Database Connectivity
Introduction to Modern Internal Tooling
In today's fast-paced digital economy, businesses generate and rely on vast amounts of data spread across various platforms and databases. Engineering and operations teams frequently require custom internal tools—such as admin panels, customer support dashboards, and data pipelines—to manage these assets. However, building these applications from scratch using traditional frontend frameworks can be a significant drain on development resources.
This is where ToolJet enters the framework. ToolJet is an open-source, low-code platform that enables teams to build internal tools rapidly using a drag-and-drop visual builder. By deploying ToolJet on your own Cloud VPS (Virtual Private Server), you retain full data sovereignty, reduce licensing costs, and gain the flexibility to connect securely to multiple databases simultaneously. This guide provides a comprehensive, production-grade walkthrough for deploying ToolJet on a Cloud VPS and configuring it for multi-database enterprise environments.
Why Choose ToolJet on Cloud VPS for Internal Applications?
Before diving into the technical implementation, it is crucial to understand the strategic advantages of hosting ToolJet on a dedicated Cloud VPS compared to utilizing SaaS alternatives:
- Data Sovereignty and Security: Internal tools often handle sensitive customer data, financial records, or proprietary business logic. Running ToolJet on your private VPS ensures that data never leaves your infrastructure perimeter, helping you comply with strict regulatory frameworks like GDPR or local data protection laws.
- Cost Efficiency: SaaS low-code platforms often charge per user, which can become prohibitively expensive as your organization grows. A Cloud VPS incurs a predictable, fixed monthly cost regardless of how many internal users access the platform.
- High Performance and Low Latency: Hosting ToolJet geographically close to your primary production databases reduces network latency, resulting in faster query executions and a snappier user experience for your operational teams.
- Extensive Multi-Database Connectivity: ToolJet natively supports a massive array of data sources, including PostgreSQL, MySQL, MongoDB, Redis, and Elasticsearch, alongside REST and GraphQL APIs.
Prerequisites and System Architecture
To ensure a smooth installation process, your Cloud VPS should meet the following minimum hardware and software specifications:
- Operating System: Ubuntu 22.04 LTS or Ubuntu 24.04 LTS (Clean installation recommended).
- Hardware Specifications: Minimum 2 vCPUs, 4GB RAM, and 40GB SSD storage. For production environments with high concurrent user traffic, consider upgrading to 4 vCPUs and 8GB RAM.
- Domain Name: A registered domain or subdomain (e.g.,
tooljet.yourcompany.com) with A/AAAA records pointed to your VPS public IP address. - Installed Software: Docker Engine (v20.10+) and Docker Compose (v2.0+).
Step-by-Step Deployment Guide
Step 1: Preparing the Server and Installing Docker
First, log into your Cloud VPS via SSH and update the system packages to their latest versions to patch security vulnerabilities:
sudo apt update && sudo apt upgrade -yNext, install the required dependencies and the Docker engine. Docker simplifies the deployment process by encapsulating ToolJet and its microservices into isolated, easily manageable containers:
sudo apt install -y curl apt-transport-https ca-certificates lsb-release software-properties-common
# Add Docker’s official GPG key
curl -fsSL [https://download.docker.com/linux/ubuntu/gpg](https://download.docker.com/linux/ubuntu/gpg) | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
# Set up the stable repository
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] [https://download.docker.com/linux/ubuntu](https://download.docker.com/linux/ubuntu) $(lsb_release -cs) stable" | sudo tee /etc/list.d/docker.list > /dev/null
# Install Docker Engine
sudo apt update && sudo apt install -y docker-ce docker-ce-cli containerd.ioVerify that Docker is active and configured to launch automatically upon system boot:
sudo systemctl enable docker
sudo systemctl status dockerStep 2: Configuring the ToolJet Deployment Environment
Create a dedicated directory for your ToolJet deployment to keep your configuration files organized:
mkdir ~/tooljet-deployment && cd ~/tooljet-deploymentToolJet requires an external environment file to manage application secrets, database credentials, and server variables. Create a .env file using your preferred text editor:
nano .envPopulate the file with the following variables, ensuring you replace the placeholder values with secure, randomly generated strings:
# ToolJet Server Configuration
TOOLJET_HOST=[https://tooljet.yourcompany.com](https://tooljet.yourcompany.com)
LOCKBOX_MASTER_KEY=your_secure_generated_lockbox_master_key_here
SECRET_KEY_BASE=your_secure_generated_secret_key_base_here
# Internal Database Configuration (For ToolJet metadata storage)
ORM_LOGGING=error
PG_DB=tooljet_metadata
PG_USER=tooljet_admin
PG_PASSWORD=your_super_secure_db_password_here
PG_HOST=postgres
PG_PORT=5432Note: You can generate highly secure, random keys forLOCKBOX_MASTER_KEYandSECRET_KEY_BASEusing the command openssl rand -hex 64 in your terminal. Never expose these keys publicly.
Step 3: Creating the Docker Compose Specification
Now, create the docker-compose.yml file that orchestrates the ToolJet server, the frontend architecture, and the internal PostgreSQL metadata database:
nano docker-compose.ymlInsert the following configuration into the file:
version: '3.8'
services:
postgres:
image: postgres:15-alpine
container_name: tooljet_postgres
restart: always
environment:
POSTGRES_DB: ${PG_DB}
POSTGRES_USER: ${PG_USER}
POSTGRES_PASSWORD: ${PG_PASSWORD}
volumes:
- tooljet_db_data:/var/lib/postgresql/data
ports:
- "127.0.0.1:5432:5432"
server:
image: tooljet/tooljet-server:latest
container_name: tooljet_server
restart: always
ports:
- "3000:3000"
env_file:
- .env
depends_on:
- postgres
volumes:
- tooljet_server_plugins:/tooljet/plugins
volumes:
tooljet_db_data:
tooljet_server_plugins:Save and exit the editor. Execute the following command to pull the images and launch the containers in detached mode:
sudo docker compose up -dSecuring Traffic with Nginx and Let's Encrypt SSL
Running web services over unencrypted HTTP exposes credentials and sensitive query payloads to potential interception. To secure the connection, configure Nginx as a reverse proxy coupled with a free Let's Encrypt SSL certificate.
Step 1: Install Nginx and Certbot
sudo apt install -y nginx certbot python3-certbot-nginxStep 2: Configure the Nginx Virtual Host
Create a configuration file for your ToolJet domain:
sudo nano /etc/nginx/sites-available/tooljetAdd the following server block configuration:
server {
listen 80;
server_name tooljet.yourcompany.com;
location / {
proxy_pass [http://127.0.0.1:3000](http://127.0.0.1:3000);
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;
# WebSockets support for real-time operations
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}
}Enable the site and restart Nginx to apply changes:
sudo ln -s /etc/nginx/sites-available/tooljet /etc/nginx/sites-enabled/
sudo systemctl restart nginxStep 3: Provision the SSL Certificate
Run Certbot to automatically obtain and configure the SSL certificate:
sudo certbot --nginx -d tooljet.yourcompany.comFollow the interactive prompts to complete the process and select the option to automatically redirect all HTTP traffic to HTTPS.
Connecting Multi-Database Architecture Within ToolJet
With ToolJet successfully deployed and secured, navigate to [https://tooljet.yourcompany.com](https://tooljet.yourcompany.com) via your web browser to complete the initial admin account setup. Once logged into the primary dashboard, you can leverage ToolJet’s core strength: connecting disjointed databases to build unified operations interfaces.
Integrating a Production PostgreSQL Cluster
- Navigate to the Data Sources tab on the left-hand sidebar of your workspace.
- Select PostgreSQL from the list of available relational databases.
- Enter your connection parameters: Host IP, Port (usually 5432), Database Name, Username, and Password.
- If your database is hosted externally, ensure your Cloud VPS IP is explicitly whitelisted in the remote database’s
pg_hba.conffile and cloud firewall rules. - Click Test Connection to validate settings, followed by Save.
Integrating an Analytical MongoDB Instance
Often, operational tools need to cross-reference structured relational data with unstructured document data. To add a secondary MongoDB source:
- Click on Add Data Source and choose MongoDB.
- Input your standard Connection String (URI format) or specify host attributes independently.
- Enable SSL/TLS if connecting to managed cluster solutions like MongoDB Atlas.
- Save the connection. You can now build single dashboards where a user action triggers a PostgreSQL lookup alongside a MongoDB update query.
Building a Custom Drag-and-Drop Admin Interface
Once your databases are linked, building an interface takes only minutes. ToolJet offers an expansive collection of pre-built UI components including tables, forms, charts, containers, and rich text editors.
Step 1: Layout Design
Drag a Table component onto the center canvas to display data records. On the right-hand panel, use the component configurations to adjust row heights, column sorting capabilities, and pagination details.
Step 2: Query Creation
At the bottom of the App Builder interface, open the Query Panel. Create a new query linked to your PostgreSQL database. For example:
SELECT id, first_name, last_name, email, account_status FROM users WHERE account_status = 'pending';Set this query to execute automatically when the application loads. Link the query output to the Table component by setting its data field property to {{queries.postgresql_query_name.data}}.
Step 3: Action Handlers and Multi-Database Workflows
Drag a Form component alongside the table to handle record modifications or approvals. You can configure a button within the form to run an update query on MongoDB when clicked, simultaneously logging an audit trail in your PostgreSQL database. This highlights the true capability of modern enterprise low-code systems: native multi-destination writebacks from a single client action.
Conclusion and Best Practices for Management
Deploying ToolJet on a Cloud VPS empowers your business to build robust internal operations software efficiently, cleanly, and securely. To maximize application uptime and reliability over the long term, ensure you implement these production workflows:
- Automated Database Backups: Set up daily cron jobs on your Cloud VPS to dump your PostgreSQL metadata volumes to off-site object storage.
- Resource Monitoring: Utilize tools like Prometheus or basic system monitoring tools provided by your VPS provider to track CPU usage and memory spikes.
- Access Control: Enforce strict RBAC (Role-Based Access Control) within the ToolJet dashboard to restrict analytical and write capabilities based on organizational departments.
