Update duokaixianzhiban.sh

This commit is contained in:
smeb y 2024-03-20 23:54:30 +08:00 committed by GitHub
parent c1ca9f142a
commit ce92d72444
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -45,7 +45,6 @@ mkdir -p $volume_dir
# 创建用户指定数量的容器
for i in $(seq 1 $container_count)
do
disk_size_mb=$((disk_size_gb * 1024))
# 为每个容器创建一个具有特定大小的文件系统映像
@ -58,6 +57,9 @@ do
mkdir -p $mount_point
sudo mount -o loop $volume_path $mount_point
# 将挂载信息添加到 /etc/fstab
echo "$volume_path $mount_point ext4 loop,defaults 0 0" | sudo tee -a /etc/fstab
# 运行容器并设置重启策略为always
container_id=$(docker run -d --restart always -v $mount_point:/root/.titanedge/storage --name "titan$i" nezha123/titan-edge:1.1)