Skip to content
/ tazama Public template
forked from Blazity/next-enterprise

Real-time open-source transaction monitoring demo

License

Notifications You must be signed in to change notification settings

PaulVZ-AO/tazama

Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

tazama logo

typescript

Tazama Demo Application

Note

Tazama Open Source Real-Time Transaction Monitoring Software for Fraud and Money Laundering Detection

GitHub License

Welcome to the Tazama Demo Application. This demo app is used to demo the Tazama Open Source Real-Time Transaction Monitoring System built to support any Financial Services Provider (FSP) that requires Transaction Monitoring for Fraud and Money Laundering detection. Whether that FSP is a small provider running one or 2 transactions per day or a national payment switch running at over 3,000 Transactions per second. With Tazama they can implement simple or complex rules, implement Fraud Detection controls or support Anti-Money Laundering activities. 🌍

Requirements

What you need:

  • tazama logo Full-Stack-Tazama-Docker - Setup the Rules and Typologies Using Docker Compose from the Tazama Repository. Follow the instructions in the readme.md
  • πŸ’» Demo UI - Clone this repository and use the easy to setup UI to demo the Tazama Open Source Real-Time Transaction Monitoring System that dynamically builds the UI based on the configured rules and typologies

Table of Contents

Getting Started

Local Setup

To get started by running the demo locally, follow these steps:

  1. Fork & clone repository:
## Don't forget to ⭐ star and fork it first :)
git clone [email protected]:tazama-lf/tazama-demo.git
  1. Setup
add your GH_TOKEN to the .npmrc file ${GH_TOKEN}
  1. Install the dependencies:
yarn install --frozen-lockfile
  1. Create a new .env file and copy the contents of the env_sample file to the newly created .env
NODE_ENV=dev
NEXT_PUBLIC_URL="http://localhost:3001"
PORT="3001"
NEXT_PUBLIC_TMS_SERVER_URL="http://localhost:5000"
NEXT_PUBLIC_TMS_KEY="no_key_set"
NEXT_PUBLIC_CMS_NATS_HOSTING="nats://localhost:14222"
NEXT_PUBLIC_NATS_USERNAME=""
NEXT_PUBLIC_NATS_PASSWORD=""
NEXT_PUBLIC_ARANGO_DB_HOSTING="http://localhost:18529"
NEXT_PUBLIC_DB_USER="root"
NEXT_PUBLIC_DB_PASSWORD=""
NEXT_PUBLIC_WS_URL="http://localhost:3001"

NEXT_PUBLIC_NATS_SUBSCRIPTIONS="['connection', '>', '[email protected]']"
  1. Run the development server:
yarn dev
  1. Open http://localhost:3001 with your browser to see the result.

Network Setup

  1. Follow the Full-Stack-Tazama-Docker setup guide.
  2. Add the following to the Full-Stack-Tazama-Docker docker-compose.yaml found in the root directory
demo:
    image: tazamaorg/demo-ui:v1.0.16
    env_file:
      - path: ./env/demo.env
        required: true
    restart: always
    depends_on:
      - tms
      - arango
      - nats
    ports:
      - '3001:3001'

*Note - Make sure to update the image to the most recent version tazamaorg/demo-ui:{current_version} eg: v1.0.16

  1. Navigate to the env directory in the Full-Stack-Tazama-Docker folder:
demo.env file:
# SPDX-License-Identifier: Apache-2.0

NODE_ENV=dev
NEXT_PUBLIC_URL="http://{server_ip_address}:3001"
PORT="3001"
NEXT_PUBLIC_TMS_SERVER_URL="http://{server_ip_address}:5000"
NEXT_PUBLIC_TMS_KEY=""
NEXT_PUBLIC_CMS_NATS_HOSTING="nats://nats:4222"
NEXT_PUBLIC_NATS_USERNAME=""
NEXT_PUBLIC_NATS_PASSWORD=""
NEXT_PUBLIC_ARANGO_DB_HOSTING="http://{server_ip_address}:18529"
NEXT_PUBLIC_DB_USER="root"
NEXT_PUBLIC_DB_PASSWORD=""
NEXT_PUBLIC_WS_URL="http://{your_machines_ip_address}:3001"

NEXT_PUBLIC_NATS_SUBSCRIPTIONS="['connection', '>', '[email protected]']"

  1. From the Full-Stack-Tazama-Docker directory run:

    docker compose pull demo

    then:

    docker compose up demo -d
  2. Navigate to: http://localhost:3001

  3. To bring the demo container down run:

    docker compose down demo --remove-orphans

Setup UI

  1. First Load

main

  1. Click the gear icon on the top right for Settings

settings

Settings Screen

  • TMS API Host URL: http://localhost:5000

    *Check what port number is being used by the TMS server on the docker instance (Default Port: 5000)

  • CMS NATS Hosting: http://localhost:14222 if run outside of docker-compose else nats://nats:4222

    *Check what port number is being used by the NATS server on the docker instance (Default Port: 4222)

  • Arango DB Hosting: http://localhost:18529

    *Check what port number is being used by the TMS server on the docker instance (Default Port: 8529)

  • Websocket IP Address: http://localhost:3001

    *If run locally use http://localhost:3001 else if run on a network or hosted use http://{your_ip_address}:3001 (Default Port: 3001)

Tag and Release

Versioning

Format: v1.0.16

Given a version number MAJOR.MINOR.PATCH, increment the:

MAJOR version when you make incompatible API changes, MINOR version when you add functionality in a backwards-compatible manner, and PATCH version when you make backwards-compatible bug fixes. Additional labels for pre-release and build metadata are available as extensions to the MAJOR.MINOR.PATCH format.

In this section the following script will update the PATCH version in the package.json file and update the docker-compose.dev.yml file.

Tag, Build and Push to Docker Hub

  1. From the root of the project directory run:

    sudo chmod +x ./tag.sh
  2. When you are ready to create a new image, run ./tag.sh from the command line.

    ./tag.sh

    *This will build the Docker Image and Push it to Docker Hub

Reverting version changes if the build fails

If the build fails run the following script to revert changes made to the docker-compose.dev.yml and the package.json files.

  1. From the root of the project directory run:

    sudo chmod +x ./revertTag.sh
  2. When you are ready to create a new image, run ./tag.sh from the command line.

    ./revertTag.sh
  3. Fix the build issues and run the ./tag.sh script again to Tag and Release the Demo

Create Docker Image for Dev Testing

  1. Build the Docker image

    COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose -f docker-compose.dev.yml build
  2. Tag the Docker Image

    docker tag tazamaorg/demo-ui:{version} tazamaorg/demo-ui:{version}-dev

    *Note: Check The docker-compose.dev.yml file to see what the version will be and update above command by replacing {version} with eg. v1.0.16

  3. Push the image to docker hub

    If you want to push the Docker image to Dockerhub for a distribution and testing:

    docker push tazamaorg/demo-ui:{version}-dev

    *Note: Check The docker-compose.dev.yml file to see what the version will be and update above command by replacing {version} with eg. v1.0.16

  4. To use the Docker Image in the Full-Stack-Tazama-Docker stack, update the following:

    demo:
      image: tazamaorg/demo-ui:{version}-dev
      env_file:
        - path: ./env/demo.env
          required: true
      restart: always
      depends_on:
        - tms
        - arango
        - nats
      ports:
        - '3001:3001'

    *Note: Check The docker-compose.dev.yml file to see what the version will be and update above command by replacing {version} with eg. v1.0.16

License

This project is licensed under the Apache License Version 2.0. For more information, see the LICENSE file.

Contributors

Detmar Ruhfus
Detmar Ruhfus

πŸ’» πŸ“–
Paul Von Zeuner
Paul Von Zeuner

πŸ’»
Sahra Amir
Sahra Amir

πŸ’»
Oliver Vermeulen
Oliver Vermeulen

πŸ’»
Add your contributions

Thank you

About

Real-time open-source transaction monitoring demo

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 94.5%
  • JavaScript 2.8%
  • MDX 1.9%
  • Other 0.8%