Cloud Patrol Forum Deployment Document
Packaged under Windows and sent to the server to run
Building Windows environment
install Java
Use jvms to manage the java version. If you already have java 8, please ignore it
Download jvms
access
download the latest version

Recommended to decompress to C:\java

Initialize jvms
Search for 编辑系统环境变量 on Windows settings


Double-click Path

Create this new record

Then, open powershell and type
jvms init

Download Java 8
Download address:









Enabling Java 8
Enter in powershell
jvms list
View the version of java managed by jvms in this machine, and enter
jvms switch [ 8 前面的数字]

verify the installation
Enter in powershell
java -version

Install maven
download
download links for

decompression
Unzip the compressed package to C:\maven

configured
Modify configuration file C:\maven\conf\settings.xml
Add between<mirrors> and</mirrors>
<mirror>
<id>aliyun</id>
<mirrorOf>central</mirrorOf>
<name>aliyun maven</name>
<url>https://maven.aliyun.com/repository/public</url>
</mirror>
This configuration is used to set the maven mirror warehouse address

Add between<settings> and</settings>
<localRepository>E:\m2</localRepository>
This configuration is used to set the maven local warehouse address, and try to change it to something other than the C drive.

Add to system environment variables

verify the installation
Enter in powershell
mvn -v

install Git
download
download links for

During the installation process, the default configuration will work, and keep pressing next until the installation is successful
verify the installation
Enter in powershell
git -v

Install Docker Desktop
download
Download address is

configured
Recommend rewriting Docker Engine

If you use 轩辕镜像, please modify the configuration to
{
"builder": {
"gc": {
"defaultKeepStorage": "30GB",
"enabled": true
}
},
"experimental": false,
"insecure-registries": [
"******.xuanyuan.run"
],
"registry-mirrors": [
"https://******.xuanyuan.run"
]
}install NodeJS
Manage node versions using nvm
Download nvm
download links for

Then agree to the protocol, default configuration, and install
Configure nvm
Running in powershell
# 注意结尾有斜杠
nvm node_mirror https://npmmirror.com/mirrors/node/
nvm npm_mirror https://npmmirror.com/mirrors/npm/
This configuration is used to set up domestic mirroring sources
install NodeJS
Running in powershell
# 输出安装版本
nvm -v
# 安装 node 22
nvm install 22
# 使用 node 22
nvm use 22
Configure node
Running in powershell
npm config set registry https://registry.npmmirror.com
This configuration is used to set up domestic mirroring sources
Package and copy the program
start the MySQL
Open powershell on the D drive and run
git clone https://gitee.com/qinzihang2006/blog.git

Running under D:\blog
docker compose up mysql
in the event of

, you can exit and it will run in the background
modify the configuration file
Change the value of VITE_API_URL in D:\blog\bbs-web-admin\.env.production to the real ip address of the server
Change the value of VITE_API_URL in D:\blog\bbs-web-mobile\.env.production to the real ip address of the server
Change the value of VITE_API_URL in D:\blog\bbs-web-pc\.env.production to the real ip address of the server
Add the address of cross-domain requests to D:\blog\src\main\resources\crossOrigin.properties, such as http://10.1.100.104
Install dependencies
Run mvn install under D:\blog and download relevant back-end dependencies
Run npm install under D:\blog\bbs-web-mobile and download mobile dependencies
Run npm install under D:\blog\bbs-web-admin and download the admin-side dependencies
Run npm install under D:\blog\bbs-web-pc and download web dependencies
test run
Run mvn spring-boot:run under D:\blog, if something similar to
16:28:47 INFO cms.Application - Started Application in 5.304 seconds (JVM running for 5.962)
And there is no error message, and it can be run by default
Running npm run dev under D:\blog\bbs-web-mobile if something similar to
vite v2.9.15 dev server running at:
> Local: http://localhost:3000/admin/
> Network: use `--host` to expose
ready in 579ms.
And there is no error message, and it can be run by default
The same applies to admin and pc
packaged
Run mvn clean package under D:\blog
In fact, the
mvn installcommand contains packaging
Run npm run build under D:\blog\bbs-web-mobile
Run npm run build under D:\blog\bbs-web-admin
Run npm run build under D:\blog\bbs-web-pc
upload
Here we take Ubuntu 24.04 as an example
Copy D:\blog\target\bbs-pro-6.9.jar to the server under ~
Copy D:\blog\bbs-web-pc\dist to the server under ~/bbs-web-pc
Copy D:\blog\bbs-web-mobile\dist to the server under ~/bbs-web-mobile
Copy D:\blog\bbs-web-admin\dist to the server under ~/bbs-web-admin
Copy D:\blog\docker-compose.yml to the server under ~
Copy D:\blog\nginx.conf to the server under ~
Copy D:\blog\bbs-pro.sql to the server under ~

Server environment construction
install Docker
reference
The automatic installation script is
curl -fsSL https://get.docker.com | bash -s docker --mirror Aliyun
add user group
sudo groupadd docker
sudo usermod -aG docker $USER
configured
It is recommended to use Xuanyuan image to modify the configuration of docker
bash <(wget -qO- https://xuanyuan.cloud/docker.sh)
run
Running under ~
sudo docker compose up -d
Modify forum configuration
Visit http://ip地址:8085/admin/login
User name: admin
Password: 1234567

relevant instructions
relevant URL
Home http://ip地址/
Backstage http://ip地址/admin/login
logo path
bbs-web-admin\public\favicon.ico
bbs-web-pc\public\favicon.ico
bbs-web-mobile\public\favicon.ico
bbs-web-admin\src\assets\images\favicon.ico
bbs-web-pc\src\assets\images\favicon.ico
bbs-web-mobile\src\assets\images\favicon.ico
bbs-web-admin\src\assets\images\logo.gif
bbs-web-pc\src\assets\images\logo.gif
bbs-web-mobile\src\assets\images\logo.gif



If you enjoyed this, leave a comment~