mirror of
https://github.com/QYG2297248353/appstore-1panel.git
synced 2024-12-01 14:22:23 +08:00
22 lines
439 B
Bash
22 lines
439 B
Bash
#!/bin/bash
|
|
|
|
# 检查 .env 文件是否存在
|
|
if [ -f .env ]; then
|
|
# 导入 .env 文件中的变量
|
|
source .env
|
|
|
|
# 使用 docker network rm 命令删除网络
|
|
docker network rm $CLUSTER_NETWORK
|
|
|
|
# 检查删除是否成功
|
|
if [ $? -eq 0 ]; then
|
|
echo "Network $CLUSTER_NETWORK deleted successfully."
|
|
else
|
|
echo "Failed to delete network $CLUSTER_NETWORK."
|
|
fi
|
|
|
|
else
|
|
echo "Error: .env file not found."
|
|
exit 1
|
|
fi
|