Set Timezone on Ubuntu
Use the date command to query the date and time:
date
To change the timezone, we can use the timedatectl command.
First, run the following command to generate a list of available timezones:
timedatectl list-timezones
The timezone list will be printed to the screen. You can press SPACE to page down and use b to page up. Once you find the correct timezone, note it down, then type q to exit the list.
Next, use the timedatectl set-timezone command to set the timezone, replacing the highlighted part below with the local timezone you just found in the list:
sudo timedatectl set-timezone Asia/Shanghai
Update mx-space backend
Update the core and the bundled admin at the same time
docker pull innei/mx-server:latest
# 重新运行
docker compose up -d
# 可选,移除旧的镜像
docker images | grep 'innei/mx-server' | grep -v 'latest' | awk '{print $3}' | xargs docker rmi
Note that this only updates the latest 'latest' tag version. If you want to try the alpha version, change the docker pull command to the corresponding tag version by yourself.
Update admin separately Sometimes mx-admin has a minor version upgrade of admin that cannot be updated by updating the core Docker image. You can update it as follows:
First, go to the Release page, find the latest version, copy the download link of release.zip, then:
# 在容器外部下载 release.zip(也可以直接在容器内部下载,如果网络通畅的话)
wget https://github.com/mx-space/mx-admin/releases/download/v3.38.1/release.zip
# 如果是在容器外部下载,将 release.zip 上传到容器内部
docker cp release.zip mx-server:/app
# 进入容器
docker exec -it mx-server /bin/bash
# 进入工作目录
cd /app
# 解压 release.zip,解压出来的应该是 dist 文件夹
unzip release.zip
# 删除旧的 admin 文件夹
rm -rf /app/admin
# 移动新的 admin 文件夹
mv /app/dist /app/admin
Install Node.js, npm, pnpm, pm2, sharp on Ubuntu
Remove old version of Node.js
If you already have Node.js installed, it is recommended to remove the old version to avoid possible conflicts:
sudo apt-get remove nodejs
sudo apt-get autoremove
Set up Node.js 20.x PPA
Use curl to download and execute the NodeSource installation script:
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo bash -
This script will automatically add the Node.js 22.x PPA to your system and import the corresponding GPG key.
Install Node.js
Now you can install the latest version of Node.js:
sudo apt-get install -y nodejs
Verify installation
After installation, you can verify the Node.js version with the following command:
node -v
This should display Node.js version 20.x.
Install npm
Usually, npm is automatically installed together with Node.js. But if you need to update to the latest version of npm, use the following command:
sudo npm install -g npm
Install pnpm
pnpm is an efficient package manager. You can use npm to install it:
sudo npm install -g pnpm
Install pm2
pm2 is a popular process manager for managing and persistently running Node.js applications in production. Install it using:
sudo npm install -g pm2
Install sharp
sharp is a Node.js library for processing images. It can be installed via npm:
sudo npm install -g sharp
Baota Panel shiro and mx-space reverse proxy configuration
Frontend

Frontend
#PROXY-START/
location ^~ /
{
proxy_pass http://127.0.0.1:2323;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header REMOTE-HOST $remote_addr;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
proxy_http_version 1.1;
# proxy_hide_header Upgrade;
add_header X-Cache $upstream_cache_status;
#Set Nginx Cache
set $static_filePbkmHBNi 0;
if ( $uri ~* "\.(gif|png|jpg|css|js|woff|woff2)$" )
{
set $static_filePbkmHBNi 1;
expires 1m;
}
if ( $static_filePbkmHBNi = 0 )
{
add_header Cache-Control no-cache;
}
}
#PROXY-END/
Backend

Backend
#PROXY-START/
## WebSocket
location ^~ /socket.io {
proxy_pass http://127.0.0.1:2333/socket.io;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header REMOTE-HOST $remote_addr;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_buffering off;
proxy_http_version 1.1;
add_header Cache-Control no-cache;
}
## Others
location ^~ / {
proxy_pass http://127.0.0.1:2333;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header REMOTE-HOST $remote_addr;
add_header X-Cache $upstream_cache_status;
}
#PROXY-END/
Install and Use tmux
Installation
Choose the corresponding installation command based on your operating system:
Ubuntu / Debian:
sudo apt update sudo apt install tmuxCentOS / RHEL:
sudo yum install tmux
Start and Exit
Start a session
tmux new -s my_project
Detach temporarily
Press ctrl+b, release, then press d.
Terminate completely
Type exit or press Ctrl+d.
Kill a specific session
tmux kill-session -t my_project
Kill all sessions
tmux kill-server
Restore a session
List all background sessions:
tmux lsRestore the most recent session
tmux aRestore a specific session
tmux a -t my_projectScrolling and Copying
- Enter copy/scroll mode: press
[. - Use arrow keys or
PgUp/PgDnto scroll through historical output. - Exit: press
q.