健康同学微信公众号h5项目
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

29 líneas
1.4KB

  1. #!/bin/bash
  2. ###
  3. # @Date: 2022-08-18 09:19:07
  4. # @LastEditors: JinxChen
  5. # @LastEditTime: 2022-08-18 09:29:15
  6. # @FilePath: \TelpoH5FrontendWeb\setup_production.sh
  7. # @description:
  8. ###
  9. npm -v
  10. npm config set registry https://registry.npmmirror.com
  11. npm install
  12. npm run build
  13. image_version=$version;
  14. # 删除镜像
  15. docker rmi -f $(docker images | grep registry.cn-shanghai.aliyuncs.com/tolpo_platform/health_student_web | awk '{print $3}')
  16. # 构建telpo/mrp:$image_version镜像
  17. docker build --no-cache . -t telpo/health_student_web:$image_version;
  18. #TODO:推送镜像到阿里仓库
  19. echo '=================开始推送镜像======================='
  20. #docker login --username=telpo_linwl@1111649216405698 --password=telpo#1234 registry.cn-shanghai.aliyuncs.com
  21. #docker login --username=telpo_fengjj@1111649216405698 --password=PWDaliyun123 registry.cn-shanghai.aliyuncs.com
  22. docker login --username=rzl_wangjx@1111649216405698 --password=telpo.123 registry.cn-shanghai.aliyuncs.com
  23. docker tag telpo/health_student_web:$image_version registry.cn-shanghai.aliyuncs.com/tolpo_platform/health_student_web:$image_version
  24. docker push registry.cn-shanghai.aliyuncs.com/tolpo_platform/health_student_web:$image_version
  25. echo '=================推送镜像完成======================='
  26. #删除产生的None镜像
  27. docker rmi -f $(docker images | grep none | awk '{print $3}')
  28. # 查看镜像列表
  29. docker images;