Tutorials

Deployment Instructions – Setting Up The PinguCrew Project With Docker, Python, And Node.js

At the moment the default configuration when the run_server butler command uses docker containers to run the MongoDB, rabbit-mq and minio services.

It is mandatory to have docker service installed in case the the fault configuration is used.

To install docker you can refer to the official installtion instructions Install Docker Engine:

Python

To run the backend server and the Pingu bot it is necessary to have latest python version installed in your system.

Node.js

By the fault in order to execute the Pingu Frontend the framework uses NodeJS.

Deployment Steps

  1. Sync Submodules: First of all as the project is fragmented in multiple git submodules once the PinguCrew project is cloned it will be necessary to run the following git command to sync the rest of git submodules.
git submodule update --init
  1. Install Dependencies: Instead of manually installing all the dependency manually use the butler boostrap command.
  2. Setup configuration file parameters: You can find and modify the project configuration by editting the file located in configs/test/project.yaml. The following parameters need to be configured before jumping to the following deployment step:
    • MINIO_ROOT_USER & MINIO_ROOT_PASSWORD: admin credentials to access the Mino Dashboards.
    • SECRET_KEY: This ensures that sensitive information, like connection strings, API credentials, and user data, are encrypted and protected from unauthorized access in the Django Backend.
    • MINIO_STORAGE_PATH: local folder path where the Minio bucket DB will be stored.
    • MONGO_DB_PATH: local path where the MongoDB will be stored.
    • BACKEND_SUPERUSER: Django dashboard admin username. The admin password will be requested during when run_server butler command line is executed if the boostrap flag (-b) is set.
  3. Run backend server: The easiest way to run the backend service is using the run_server butler command line boostrap command. The butler assitant will make sure to initialize all the backend components for you including MongoDb, rabbit-mq and minio.
  4. Generate access tokens for the bots: The Pingu bots need access tokens to comunicate with the backend API and the minio buckets API.
    • Therefore, before execution any bot it is necesary to manually generate these token using the Django Admin dashboard or using the API directly and the minio dashboard.
      • Note: At this point you will notice that the configs/ folder has been linked to all the subprojects.Note: every time the butler command line is use the source folder will be sync with their copies.
        • There are few key values inside the project.yaml file that you will need to modify in order to run the Pingu bot succesfully:
          1. MINIO_ACCESS_KEY & MINIO_SECRET_KEY: To get this keys it is necesary to generate them using the minio dashboard.
          2. API_HOST && API_KEY: API host and API token used by the bots to interact with the backend.
            • At the moment all the bots share the same access token but in the future this configuration variable will be moved to the “src/pingubot/bot_working_directory/env.yaml” configuration file that way each bot will have its own access token.
  5. Run forntend server: The easyest way to run the frontend dashboard is by using the run_web butler command.
    • At this point it is posible to create a dashboard user by using the Django Admin dashboard or directly using the registration form in the login page.
Varshini

Varshini is a Cyber Security expert in Threat Analysis, Vulnerability Assessment, and Research. Passionate about staying ahead of emerging Threats and Technologies.

Recent Posts

Starship : Revolutionizing Terminal Experiences Across Shells

Starship is a powerful, minimal, and highly customizable cross-shell prompt designed to enhance the terminal…

1 day ago

Lemmy : A Decentralized Link Aggregator And Forum For The Fediverse

Lemmy is an innovative, open-source platform designed for link aggregation and discussion, providing a decentralized…

1 day ago

Massive UX Improvements, Custom Disassemblers, And MSVC Support In ImHex v1.37.0

The latest release of ImHex v1.37.0 introduces a host of exciting features and improvements, enhancing…

1 day ago

Ghauri : A Powerful SQL Injection Detection And Exploitation Tool

Ghauri is a cutting-edge, cross-platform tool designed to automate the detection and exploitation of SQL…

1 day ago

Writing Tools : Revolutionizing The Art Of Writing

Writing tools have become indispensable for individuals looking to enhance their writing efficiency, accuracy, and…

1 day ago

PatchWerk : A Tool For Cleaning NTDLL Syscall Stubs

PatchWerk is a proof-of-concept (PoC) tool designed to clean NTDLL syscall stubs by patching syscall…

2 days ago