How to Install and Deploy Mall Admin Frontend on Windows and Linux

This guide walks you through downloading Node.js, obtaining the mall‑admin‑web source code, installing dependencies, and launching the front‑end application on both Windows and Linux, including steps for using a local backend or an online API and configuring Nginx for production.

macrozheng
macrozheng
macrozheng
How to Install and Deploy Mall Admin Frontend on Windows and Linux

This article explains how to install and deploy the mall-admin-web front‑end project on Windows and Linux environments.

Installation and deployment on Windows

Download and install Node.js

Download Node.js v8.9.4 from https://nodejs.org/dist/v8.9.4/node-v8.9.4-x64.msi.

Obtain the mall‑admin‑web source code

Clone or download the repository from GitHub (https://github.com/macrozheng/mall-admin-web) or Gitee (https://gitee.com/macrozheng/mall-admin-web).

Open the project in IDEA

Install dependencies

npm install

Start the application when the backend is already set up

Run the local mall‑admin service

Start mall‑admin‑web

In the IDEA terminal run:

npm run dev

Visit http://localhost:8090 to view the UI.

Log in; the front end calls the local backend API.

Start the application without a local backend

If the backend is not set up, use the online API at http://39.98.190.128:8080.

Modify dev.env.js to set BASE_API to the online address

Start mall‑admin‑web

In the IDEA terminal run:

npm run dev

Visit http://localhost:8090 to view the UI.

Log in; the front end calls the online API.

Deployment on Linux

Modify prod.env.js as needed (image omitted).

Package the project:

npm run build

The built files are placed in the dist directory (image omitted).

Compress the dist folder to dist.tar.gz (image omitted).

Upload the archive to the Linux server’s Nginx directory (image omitted).

Extract it: tar -zxvf dist.tar.gz Delete the existing Nginx html folder: rm -rf html Move the dist folder to html: mv dist html Start the mall‑admin Docker container: docker start mall-admin Restart Nginx: docker restart nginx Open http://192.168.3.101, log in; the front end now calls the Linux server address.

Source code

https://github.com/macrozheng/mall-admin-web

Recommended reading

mall在Linux环境下的部署(基于Docker Compose) – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483811&idx=1&sn=6379e53a612bfd2f9919e098321d8a56&scene=21#wechat_redirect

mall在Linux环境下的部署(基于Docker容器) – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483786&idx=1&sn=33052d6967de1a2c9592b2a1c58b8bef&scene=21#wechat_redirect

mall在Windows环境下的部署 – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483752&idx=1&sn=b36314dff07b1c5f91ee26944511cfcb&scene=21#wechat_redirect

mall整合SpringBoot+MyBatis搭建基本骨架 – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483685&idx=1&sn=9ab2dc82f04e3578eea96aec459f7bb8&scene=21#wechat_redirect

mall整合Swagger-UI实现在线API文档 – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483690&idx=1&sn=66019583772c03bad6896eb307409d75&scene=21#wechat_redirect

mall整合SpringSecurity和JWT实现认证和授权(一) – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483704&idx=1&sn=56a3b172c3f507acba629807b535eb13&scene=21#wechat_redirect

mall整合Elasticsearch实现商品搜索 – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483722&idx=1&sn=335d7e7f6ac6fc802231bf6a3ab71569&scene=21#wechat_redirect

mall整合Mongodb实现文档操作 – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483728&idx=1&sn=5fb894f603df69ba96b225899d3faf71&scene=21#wechat_redirect

mall整合RabbitMQ实现延迟消息 – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483734&idx=1&sn=fa9af8e9f72e7443126aed0f7a64b88b&scene=21#wechat_redirect

mall整合OSS实现文件上传 – https://mp.weixin.qq.com/s?__biz=MzU1Nzg4NjgyMw==∣=2247483740&idx=1&sn=58658062c5cecefaa5ecbd4a805ed196&scene=21#wechat_redirect

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

frontendnodejsnpm
macrozheng
Written by

macrozheng

Dedicated to Java tech sharing and dissecting top open-source projects. Topics include Spring Boot, Spring Cloud, Docker, Kubernetes and more. Author’s GitHub project “mall” has 50K+ stars.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.