Skip to content
This repository has been archived by the owner on May 29, 2024. It is now read-only.

richardoey/ATE-MongoDB

Repository files navigation

ATE Dashboard v2.0

ATE Dashboard v2.0 is the second generation of ATE Dashboard that is built to help ATE monitors the production test activity.

  1. The technologies used in this project are MongoDB + Express + VueJS + NodeJS (MEVN).
  2. For better understanding, please read the Architecture section.
  3. For the development installation, please refer to Getting Started.
  4. For deployment, refer to Deploy On Docker.

Architecture

Image of ATE Dashboard Architecture

Technology References

  1. VueJS retrieves data by using RESTFUL API (NodeJS + Express) You could check the API url in server router (server/routers/index.js)
    Note: every URL will be begun with /api e.g. GET http://localhost:8000/api/tests/all.
  2. NodeJS + Express retrieves data from MongoDB using MongoDB Node Driver.
    Current code uses v3.6 which is compatible with MongoDB v3.6 and v4+ (Compatibility check here)
  3. C# Program inserts data to MongoDB using MongoDB C# Bson driver
  4. However, C# Program uploads the .txt (Data, log, ComportText, TelnetText) to the NodeJS server using RESTFUL API.

Getting Started

Prerequisites

  1. Install NodeJS v14.17.0 (I suggest you to use nvm-windows or nvm if you use other OS beside Windows). You also could directly download and install from official NodeJS.
  2. Install MongoDB v4.4.6. Follow this instruction

Installation

  1. Clone the repo
    git clone http://gitlab.jazzhipster.com.tw:30000/team_ate/Dashboard-V2/ate.git

  2. Go to server folder
    cd server

  3. Install NPM packages
    npm install

  4. Run the server (Backend)
    npm run serve

  5. Open new terminal and go to client folder
    cd client

  6. Install NPM packages
    npm install

  7. Run the client (Frontend)
    npm run serve

  8. Open browser and type localhost:8080

Deploy on Docker

Notes: Before build and running below commands, make sure you don't have any images named dashboard-server and dashboard-client. If yes, please name your image with other name.
Also ensure to free port :8080 and :80

Build & Run Projects Container

  1. Install MongoDB, client(VueJS), and server (NodeJS) using MongoDB Docker Official Images docker-compose.yml and run these below commands
    docker-compose up -d

  2. Install MongoDB Compass in your computer, then connect to your admin database with username and password in your docker-compose.yml

  3. Then, Create Database named ate_mongodb with collection name auth_users, ate_projects, ate_logs, ate_files and ate_tests.

Configure the DB_HOST url in config.js with

DB_HOST: 'mongodb://<username>:<password>@<ip_address>:27017/?authSource=admin'
  1. Open browser, go to http:<ip_address> e.g. http://192.168.100.150, it will redirect you to Login page

References:

Releases

No releases published

Packages

No packages published

Languages