Skip to content

TrueWatchTech/idurar-demo-setup-guide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

TrueWatch Workshop: iDURAR Deployment and Instrumentation on AWS EKS

(Hands-on demo for TrueWatch users & partners)

This guide shows you how to deploy the open‑source iDURAR CRM on AWS EKS and instrument it end‑to‑end with TrueWatch for metrics, logs, real‑user monitoring (RUM) and distributed tracing.


1  Introduction

TrueWatch is a full‑stack observability platform that unifies metrics, logs, traces, real‑user monitoring and synthetic testing behind a single pane of glass.
iDURAR is a MERN‑stack CRM with:

  • React frontend
  • Node.js + Express backend
  • MongoDB persistence
  • Container‑friendly design (Helm charts & manifests)

Throughout this workshop you will

  1. Deploy iDURAR on EKS
  2. Install Datakit (TrueWatch’s agent)
  3. Add RUM to the React UI
  4. Build live dashboards, pipelines and alerts
  5. Trace a request hop‑by‑hop from the browser to MongoDB

2  Prerequisites

Requirement Notes
TrueWatch Cloud account & workspace Sign up at https://id1-auth.truewatch.com/businessRegister.
AWS account with EKS cluster The examples use an existing cluster named eks-demo-cluster in ap-southeast-1.
AWS CloudShell All commands are executed from CloudShell unless noted.
kubectl, git, aws CLI Pre‑installed in CloudShell.

3  Environment Setup

On AWS CloudShell, clone the workshop repository and change into it:

git clone https://github.com/TrueWatchTech/idurar-demo-workshop
cd idurar-demo-workshop/workshop

4  Configure Datakit on AWS EKS

Step 1  Obtain Dataway endpoint

From TrueWatch → Integrations → Datakit → Kubernetes copy the ENV_DATAWAY value.

01

Step 2  Update datakit.yaml

Open the manifest and replace YOUR-ENV-DATAWAY (line 133) with the value copied above:

vim datakit.yaml    # use ":set nu" for line numbers

02

Step 3  Configure your Kube‑context

aws eks --region ap-southeast-1 update-kubeconfig --name eks-demo-cluster

Remember to update the region and cluster name to your environment's context.

03

Step 4  Deploy Datakit

kubectl apply -f datakit.yaml
kubectl get pods -n datakit

Step 5  Verify in the UI

  1. Infrastructure – EKS nodes should appear. 04
  2. Containers → Pods – Pod‑level metrics. 05
  3. Analysis Dashboard – Host & container widgets. 06
  4. Network → Map – Traffic flows. 07
  5. Logs – e.g., kube‑proxy and cluster events. 08

5  Create a RUM Client Application

Step 1  Register the application

  1. TrueWatch → RUM → Application → Create
  2. Choose Web
  3. Name & ID: idurar
  4. Copy the generated clientToken
  5. Click Create

01

Step 2  Inject the token in the React UI

vim ../frontend/src/main.jsx   # edit line 10

Replace the placeholder token with the one you just copied.

02


6  Deploy the Demo Application

Step 1  Make helper scripts executable

chmod +x bootstrap.sh build-and-push.sh deploy.sh

01

Step 2  Confirm/adjust AWS Region

vim values.env    # edit line 6 if necessary

02

Step 3  Bootstrap ECR & other resources

./bootstrap.sh

04

Step 4  Build & push images (≈5 min)

./build-and-push.sh

05

Step 5  Deploy application & refresh Datakit

./deploy.sh
kubectl delete -f datakit.yaml && kubectl apply -f datakit.yaml

06

Step 6  Grab the external URL

kubectl get all -n idurar-demo

07

Step 7  Log in

  • Username: admin@demo.com
  • Password: admin123

08


7  End‑to‑End Tracing Walk‑Through

  1. Create a customer (iDURAR → Customers → Add). 01
  2. TrueWatch → RUM → Session Explorer, open latest session. 02
  3. Fetch/XHR → sort by latency. 03
  4. Click /api/payment/summaryView Related Trace → select MongoDB span. 04
  5. Locate Current Span to zoom in; inspect timing & query. 05
  6. Host tab to correlate with node metrics. 06
  7. Logs tab → host to see correlated logs. 07
  8. Back in the session view, click any Error entry for details. 08 09

8  Create a Log Pipeline

Step 1  New pipeline

Logs → Pipelines → Create Pipeline

01

Step 2  Grab sample logs

Fill basic info → Get a Sample.
If empty, click +Add and select idurar-frontend.

02

Step 3  Define parsing rules (Grok)

Choose Manual and paste:

# Extract the 'message' field from the log
json(_, message)

# Replace new lines
replace(message, "\n", " ")

# Grok patterns
grok(message, "> vite --host %{IP:host_ip}")
grok(message, "VITE v%{GREEDYDATA:version} ready in %{NUMBER:ready_time} ms")
grok(message, "➜ Local: %{URI:local_url}")
grok(message, "➜ Network: %{URI:network_url}")

Click Test.

Step 4  Save

Verify extracted fields and Save the pipeline. Future logs will be parsed automatically.

03


9  Create Alert Rules

Step 1  New monitor

Monitoring → Monitors → Create → APM Metric Detection

01 02

Step 2  Configure & create

Fill in the parameters as shown and click Create.

03 04


10  Deployment Architecture

01

Component Purpose
AWS ALB Routes user traffic to EKS.
iDURAR Frontend React UI integrated with RUM SDK.
iDURAR Backend Node.js/Express API & business logic.
MongoDB Persistent data store.
Datakit DaemonSet collecting metrics/logs/traces.
TrueWatch SaaS observability backend.

© 2025 TrueWatch Demo Workshop

About

This guide shows you how to deploy the open‑source iDURAR CRM on AWS EKS and instrument it end‑to‑end with TrueWatch for metrics, logs, real‑user monitoring (RUM) and distributed tracing.

Resources

Stars

Watchers

Forks

Contributors