Fading Coder

One Final Commit for the Last Sprint

Home > Tech > Content

ModernWMS: Open-Source .NET Warehouse Management System Deployment Guide

Tech May 9 3

Overview of ModernWMS

ModernWMS is a lightweight yet comprehensive open-source Warehouse Management System (WMS) developed using the .NET framework. The application is designed with cross-platform compatibility in mind, allowing a single codebase to be deployed across various operating systems seamlessly.

Understanding WMS

A Warehouse Management System is specialized software engineered to orchestrate and optimize warehouse operations. It provides end-to-end oversight of the supply chain within the facility, encompassing inventory tracking from receiving to dispatch, order processing, spatial allocation, and workforce task management.

Windows Environment Setup and Deployment

The following guide demonstrates how to acquire, build, and host the application on a Windows environment using PowerShell.

Step 1: Acquiring the Source Code

$AppRoot = "D:\WMS_Deploy"
$ArchiveFile = "wms_source.zip"
New-Item -ItemType Directory -Force -Path $AppRoot
Set-Location $AppRoot
Invoke-WebRequest -Uri "https://gitee.com/modernwms/ModernWMS/repository/archive/master.zip" -OutFile $ArchiveFile
Expand-Archive -LiteralPath $ArchiveFile -DestinationPath $AppRoot

Step 2: Environment Prerequisites

Ensure the .NET 7 SDK and Node.js are installed before proceeding with the build process.

$SdkInstaller = "dotnet-sdk-7.0.101-win-x64.exe"
$NodeInstaller = "node-v16.13.1-x64.msi"

Invoke-WebRequest -Uri "https://download.visualstudio.microsoft.com/download/pr/35660869-0942-4c5d-8692-6e0d4040137a/4921a36b578d8358dac4c27598519832/dotnet-sdk-7.0.101-win-x64.exe" -OutFile $SdkInstaller
Start-Process -FilePath $SdkInstaller -ArgumentList "/install /quiet /norestart" -Wait

Invoke-WebRequest -Uri "https://nodejs.org/dist/v16.13.1/node-v16.13.1-x64.msi" -OutFile $NodeInstaller
Start-Process msiexec.exe -ArgumentList "/i $NodeInstaller /passive /norestart" -Wait

npm install -g yarn

Step 3: Compiling Backend and Front end

Create output directories and publish both the API server and the web client.

$BackendDest = "$AppRoot\server_build"
$FrontendDest = "$AppRoot\web_build"
$SourcePath = "$AppRoot\ModernWMS-master"

New-Item -ItemType Directory -Force -Path $BackendDest, $FrontendDest

Set-Location "$SourcePath\backend"
dotnet publish
Copy-Item -Path "$SourcePath\backend\ModernWMS\bin\Debug\net7.0\publish\*" -Destination $BackendDest -Recurse
Copy-Item -Path "$SourcePath\backend\ModernWMS\wms.db" -Destination $BackendDest

Set-Location "$SourcePath\frontend"
yarn install
yarn build
Copy-Item -Path "$SourcePath\frontend\dist\*" -Destination $FrontendDest -Recurse

Step 4: Configuring Nginx and Launching the Application

Download Nginx, map the frontend build to its HTML directory, and start both the proxy and the backend service.

$NginxArchive = "nginx-1.16.1.zip"
$NginxRoot = "$AppRoot\nginx"

Invoke-WebRequest -Uri "http://nginx.org/download/nginx-1.16.1.zip" -OutFile $NginxArchive
Expand-Archive -LiteralPath $NginxArchive -DestinationPath $AppRoot
Copy-Item -Path "$FrontendDest\*" -Destination "$NginxRoot\html\" -Recurse

Start-Process -FilePath "$NginxRoot\nginx.exe" -WorkingDirectory $NginxRoot
Set-Location $BackendDest
dotnet ModernWMS.dll --urls "http://0.0.0.0:20011"

Step 5: Accessing the Interface

Navigate to the deployment server's IP address in a web browser. The default credentials for the initial login are username admin and password 1.

Source Repository

The complete codebase is available at: https://gitee.com/modernwms/ModernWMS

Tags: .NETWMS

Related Articles

Understanding Strong and Weak References in Java

Strong References Strong reference are the most prevalent type of object referencing in Java. When an object has a strong reference pointing to it, the garbage collector will not reclaim its memory. F...

Comprehensive Guide to SSTI Explained with Payload Bypass Techniques

Introduction Server-Side Template Injection (SSTI) is a vulnerability in web applications where user input is improper handled within the template engine and executed on the server. This exploit can r...

Implement Image Upload Functionality for Django Integrated TinyMCE Editor

Django’s Admin panel is highly user-friendly, and pairing it with TinyMCE, an effective rich text editor, simplifies content management significantly. Combining the two is particular useful for bloggi...

Leave a Comment

Anonymous

◎Feel free to join the discussion and share your thoughts.