allLikeMall/yudao-server/run.sh
root 941a4f8787
All checks were successful
continuous-integration/drone Build is passing
更新 yudao-server/run.sh
2024-09-13 17:23:57 +08:00

16 lines
509 B
Bash

app_name='zymall'
# 定义应用版本
app_version='1.0.0'
# 定义应用环境
#profile_active='prod'
echo '----stop container----'
docker stop ${app_name}
echo '----rm container----'
docker rm ${app_name}
echo '----rm image----'
docker rmi ${app_name}:${app_version}
# 打包编译docker镜像
echo '----build image----'
docker buildx build -f Dockerfile -t ${app_name}:${app_version} .
echo '----start container----'
docker run -d -p 6127:6127 --name ${app_name} --restart always ${app_name}:${app_version}