🐳 Deploy Planvisage Application in Ubuntu Server (with out GUI)

Operating System : Linux - Ubuntu Server 22.04 LTS (With Out GUI.) Ensure required ports are open : 22 for SSH, 1433 for SQL Server, 8080 for Planvisage).

Server Setup Guide

This guide will walk you through the steps to connect to a remote ubuntu server, install Podman, SQL Server, and the Planvisage application.


1. Connect to Server Using SSH

Step 1: Change to the Directory Where the Private Key Exists

cd /path/to/private/key

Replace /path/to/private/key with the actual path on your system.

Step 2: Run the SSH Command

ssh -i my-key.pem username@remote-server-ip

Replace: - my-key.pem with your actual private key file - username with the server username (e.g., ec2-user, ubuntu, etc.) - remote-server-ip with the IP address or domain of your remote server


2. Install Podman

Update Packages and Install Podman

sudo apt update && sudo apt install -y podman

For RHEL-based systems (e.g., CentOS, Rocky Linux), use:

sudo dnf install -y podman

3. Deploying SQL Server as Container

Step 1: Create a Pod and Expose Application Port 80

Create a pod named pvpod and map host ports to container ports:

sudo podman pod create --name pvpod -p 8080:8080 -p 1433:1433

Step 2: Create a Persistent Volume Directory

Create a directory on your host system to store the SQL Server data:

mkdir -p ~/mssql-data

Step 3: Give Permission to the Folder

Assign the correct ownership to the volume directory:

sudo chown -R 10001:10001 ~/mssql-data

This will serve as the persistent storage location.

Step 4: Run SQL Server with a Volume Mount

Start your SQL Server container inside the pvpod pod with volume mounting:

sudo podman run -d --pod pvpod --name sqlserver \
  -e 'ACCEPT_EULA=Y' \
  -e 'SA_PASSWORD=YourStrongPassword' \
  -v ~/mssql-data:/var/opt/mssql \
  mcr.microsoft.com/mssql/server:latest

4: Deploy Planvisage Web Application Container

Run the Planvisage web application container inside the pvpod pod:

sudo podman run -d --pod pvpod \
  --name PvWebApplication \
  --env TZ=Asia/Kolkata \
  --env LOG_TARGET=FILE \
  --env BLOB_CONNECTSTR= \
  --env DB_CONNECTSTR= \
  --env LICENSE_KEY=xxx-xxxx-xxxx-xxxx \
  --env LICENSE_NAME=comapnyname \
  --env LICENSE_EMAIL=user@domain.com \
  --env BLOB_CONTAINER_NAME=pvwebapp \
  --env SECURE_COOKIE=False \
  --env PV_SESSIONTIMEOUT=60 \
  --pull always \
  planvisage.azurecr.io/pvwebapp:latest

5. Deploy Planvisage Task Manager Scheduler Container

Run the task manager container in the same pvpod:

sudo podman run -d --pod pvpod \
  --name PvTaskManagerScheduler \
  --env TZ=Asia/Kolkata \
  --env LOG_TARGET=FILE \
  --env BLOB_CONNECTSTR= \
  --env DB_CONNECTSTR= \
  --env BLOB_CONTAINER_NAME=pvwebapp \
  --env SECURE_COOKIE=False \
  --env PV_SESSIONTIMEOUT=60 \
  --pull always \
  planvisage.azurecr.io/pvtaskmanagerscheduler:latest

6. Create R API Container ( Applicable only for Forecast Module)

7. Create Python API Container ( Applicable only for Forecast Module)

8. Configuaration - System Admin