LogoLogo
API Documentation
Version 1.19.5 and Older
Version 1.19.5 and Older
  • DecisionRules Documentation
  • API
    • API Introduction
    • API Keys
      • Solver API Keys
      • Management API keys
      • BI API keys
    • Rule Solver API
    • Management API
      • Deprecated Endpoints
    • Console Logs API
    • Business Intelligence API
      • Deprecated Endpoints
    • Datacenters & Locations
      • Global Cloud
      • Regional Cloud
    • Apache Kafka Solver API
    • Endpoint Settings
    • Archive
      • Rule Flow Solver API (DEPRECATED)
  • Decision tables
    • Decision Tables Introduction
    • Table Designer
    • Input & Output JSON Model
      • Simple Editor
      • JSON Editor
      • Binding to Model
    • Supported Data Types
    • Operators and Functions
      • Basic operators
      • Date operators
      • Functions
        • Logical Functions
        • Math Functions
        • Date and Time Functions
        • Text Functions
        • Data Functions
        • Array Functions
        • Integration functions
        • Functions and JSON
    • Export & Import of Decision Tables
      • Export Decision Table
      • Import Decision Table
      • File Structure of JSON Format
      • Managing Decision Table in Excel/Google Sheets
      • Deprecated Formats: XLSX v.1 and CSV
    • Table Operations
      • Filter Values
      • Valid Values
      • Sorting
  • Decision Trees
    • Decision Trees Introduction
    • Decision Tree Designer
    • Export & Import Decision Trees
      • Export Decision Tree
      • Import Decision Tree
  • Scripting Rules
    • Scripting Rule Introduction
    • Custom functions in Scripting Rules
    • Calling external API within ScriptingRules
    • Use Rule Variables in Scripting Rules
    • Call Embedded Rules in Scripting Rules
    • Export & Import Scripting Rules
      • Export Scripting Rule
      • Import Scripting Rule
    • Tips
  • Rule Flow
    • Rule Flow Designer
    • Rule Flow Mapping
    • Rule States in Rule Flow
    • Warnings & Errors
    • Rule Flow Limits
    • Export & Import Rule Flows
      • Export Rule Flow
      • Import Rule Flow
  • Workflow
    • Workflow Introduction
    • Workflow Designer
    • Workflow Nodes Overview
    • Workflow Limits
  • Other
    • Rule Alias
    • Execution Strategy
    • Rule State
    • Rule Versioning
    • Favorite Rules
    • Rule Variables
    • Rule Comparison
      • Decision Table Comparison
      • Decision Tree Comparison
      • Scripting Rule Comparison
    • Rule Tags
    • Rule Dependencies
    • Test Bench
    • Single Sign-On (SSO)
    • Event timeline
    • Rule Lock
    • Rule Migration Strategies
    • Changes in Version 1.19.0 (10/2024)
  • Organizations
    • Introduction
      • Access to Organization
    • Structure
      • Organization Roles
      • Members
      • Teams
      • Spaces
      • Space Roles
      • Policies
      • Settings
  • Teamwork
    • Dashboard
    • Folders
    • Spaces
    • Manage Spaces
    • Share Rules Between Spaces
    • Users & Roles
    • Teamwork Indicator
  • SDK and Integrations
    • Languages / Frameworks
      • SQL Server
      • Oracle PL/SQL
      • PostgreSQL
      • JavaScript
      • Java Spring Example
      • PHP Library
      • Python Library
      • .NET Library
      • Google Tag Manager
    • Excel Add-in
  • Business Intelligence
    • Audit Logs
    • Create a Power BI Report
    • Connect Power BI to Business Intelligence API
    • Connecting from Power BI (deprecated)
    • Connect DecisionRules to Power BI Using Our Custom Connector
  • Billing
    • Invoices & Billing
    • Change Product Plan
    • Billing Information
    • Plan Limits Explained
  • Regional Cloud
    • Regional Cloud
    • Region Specific API URLs
  • On-Premise / Docker
    • Environment Variables
    • Redis Connection Modes
    • Setup Single Sign-On (SSO)
      • Set up Microsoft Entra ID SSO
      • Set up Google SSO
    • DecisionRules Application
      • Minimal Requirements
      • DecisionRules Server
      • DecisionRules Client
      • DecisionRules Business Intelligence
      • Networking Between Docker Containers
    • Docker Showcase App
      • Showcase
      • Showcase + Business Intelligence
    • AWS Setup
      • AWS ECS/Fargate
      • Cache - Amazon ElastiCache
    • Microsoft Azure Setup
      • Database - Azure CosmosDB
      • Cache - Azure Cache for Redis
      • Azure Container Apps
    • Azure Red Hat OpenShift
    • Google Kubernetes Engine (GKE)
    • Kubernetes Setup
      • Kubernetes Setup with Business Intelligence
    • Logging options
    • CD/CI Pipelines
      • Azure DevOps CICD Pipelines
      • Using Migration script (old way)
    • Offline License
  • Terms & Conditions
    • Terms and Conditions
    • Privacy Policy
    • Service Level Agreement
      • Community Support
      • Standard Cloud (SaaS)
      • Silver SLA
      • Gold SLA
      • Custom SLA
    • Sub-Processor List
  • Roadmap 🚲 🗺️
  • Release Notes
    • Public Cloud
    • On-Premise / Private Cloud
Powered by GitBook
On this page
  • How to set networking for DecisionRules in docker
  • How to setup multi-container app
  • Method 1: Setup with terminal
  • Method 2: Setup with docker-compose file

Was this helpful?

  1. On-Premise / Docker
  2. DecisionRules Application

Networking Between Docker Containers

If you don't want to use a docker-compose file for whatever reason you can create networking between containers manually.

This can be achieved only on the same network!

How to set networking for DecisionRules in docker

How to setup multi-container app

What containers will we need:

  1. Server App

  2. Client App

  3. Business Intelligence App

  4. Redis

  5. MongoDB

Method 1: Setup with terminal

First of all, we need to create a docker network because containers, by default, don't see other containers thus they cannot communicate with each other. We will use a simple command docker network create

Note: If you are using PowerShell on Windows you need to use `` for multi-line command!

// creating docker network space
docker network create <network_name>

// if you want to remove network
docker network remove <network_name>

In the second step, we need to run all mandatory containers mentioned above. We will do it with the help of docker run . In this command, we will set ports and env variables as well.

// create mongoDB docker container
docker run -dp 27017:27017 --network decisionrules mongo
// create redis docker container
docker run -dp 6379:6379 --network decisionrules redis

If the command is successful it prints containers id

-d flags that can be interpreted as-d -pwhich is a detached mode with exposed ports. Detached mode means that the container runs in the background and grimly does its work.

// creating decisionrules server container
docker run -d -p 8080:8080 -p 8081:8081 
--network decisionrules
-e WORKERS_NUMBER=1
-e REDIS_URL=YOUR_REDIS_URL
-e MONGO_DB_URI=YOUR_MONGODB_URL
-e BI_MONGO_DB_URI=YOUR_BI_MONGODB_URL
-e CLIENT_URL=YOUR_CLIENT_URL
-e LICENSE_KEY=YOUR_LICENSE_KEY
-v license:/assets/lic/ decisionrules/server
// creating decisionrules client container
docker run -dp 80:80 --network decisionrules -e API_URL=YOUR_CLIENT_URL BI_API_URL=YOUR_BI_URL decisionrules/client
// creating decisionrules business intelligence container
docker run -dp 82:82 --network decisionrules -e BI_MONGO_DB_URI=YOUR_MONGO_URI decisionrules/business-intelligence

Hurray! It is done. Now you can go to localhost:80 a DecisionRules should be up and running.

Method 2: Setup with docker-compose file

You can use docker-compose for a very easy setup.

version: "3.7"

services:
  server:
    image: decisionrules/server
    environment:
      - "SHOWCASE=false"
      - "REDIS_URL=YOUR_REDIS_URL"
      - "MONGO_DB_URI=YOUR_MONGO_URI"
      - "CLIENT_URL=YOUR_CLIENT_URL"
      - "LICENSE_KEY=YOUR_LICENSE_KEY"
    ports:
      - "8080:8080"
      - "8081:8081"
    links:
      - mongoDb
      - redis
  client:
    image: decisionrules/client
    environment:
      - "API_URL=YOUR_API_URL"
      - "BI_API_URL=YOUR_BI_API_URL"
    ports:
    - "80:80"
    
  business-intelligence:
    image: decisionrules/business-intelligence
    environment:
      - "BI_MONGO_DB_URI=YOUR_MONGO_URI"
    ports:
    - "8082:8082"  

  mongoDb:
    image: mongo
    ports:
      - "27017:27017"

  redis:
    image: redis
    ports:
      - "6379:6379"

Run docker-compose with docker compose up command

Was this helpful?

Your env properties configuration may vary. For all possibilities go

here