Skip to content

Sample Project Overview

Introduction

This sample project showcases a Docker Compose stack comprising Metal Server and various Database Management System (DBMS) providers.

The stack comes preloaded with data, facilitating the execution and testing of diverse use cases.

The project has been tested on:

  • CentOS 7
  • Ubuntu 22

Stack Services

Here's an overview of the key services included in the stack:

Service NameDescriptionDocker Image
metalMetal Servermetal-server Dockerfile
mdb-mflixMongoDBmongo:latest
ms-hrMS SQL Server 2019mcr.microsoft.com/mssql/server:2019-latest
pg-northwindPostgreSQL Serverpostgres:latest
pg-clubdataPostgreSQL Serverpostgres:latest
pg-clubdata-bookingsPostgreSQL Serverpostgres:latest
pg-clubdata-membersPostgreSQL Serverpostgres:latest
pg-clubdata-facilitiesPostgreSQL Serverpostgres:latest
azuriteMicrosoft Azure Storage Azuritemcr.microsoft.com/azure-storage/azurite:latest

Databases

For each DBMS, the project includes specific databases with associated tables or collections:

Service NameDatabase NameTables/Collections Names
mdb-mflixmflixmovies, users, sessions, comments, theaters
ms-hrhrregions, countries, locations, jobs, departments, employees, dependents
pg-northwindnorthwindterritories, order_details, employee_territories, us_states, customers, orders, employees, shippers, products, categories, suppliers, region, customer_demographics, customer_customer_demo
pg-clubdataclubdatamembers, facilities, bookings, mflix_log
pg-clubdata-membersclubdatamembers
pg-clubdata-facilitiesclubdatafacilities
pg-clubdata-bookingsclubdatabookings

Files

The project includes files to be used with File Data provider:

File NameStorageContent
colors.jsonazurite (datacontainer1)JSON data
addresses.csvazurite (datacontainer1)CSV data

Configuration File

The project includes a readily available configuration file for seamless setup. Configuration File

Prerequisites

Before delving into the sample project, ensure that your environment meets the following prerequisites:

  • Docker 24+
  • Git 2.42 or newer

Installation

Follow these steps to install the sample project:

  1. Clone the sample project repository:

    bash
    git clone https://github.com/anismegdiche/metal-sample-project.git
  2. Navigate to the project directory:

    bash
    cd metal-sample-project
  3. Change the permissions of the install.sh script:

    bash
    chmod +x *.sh
  4. Run the installation script:

    bash
    ./install.sh

    The stack will be up and ready after the installation process.

Verification

To ensure everything is set up correctly, run CRUD tests for each DBMS using the following command:

bash
docker-compose exec metal npm run test-client

Congratulations! You have successfully configured and verified your Metal Server Sample Project.

For more use cases, please refer to the section Use cases

Released under the GNU v3 License.