天波用户运营管理后台系统
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

setup_test.sh 1009B

12345678910111213141516171819202122232425262728293031
  1. ###
  2. # @Author: JinxuChen
  3. # @Date: 2021-11-15
  4. # @LastEditTime: 2021-12-02 09:22:16
  5. # @LastEditors: JinxuChen
  6. # @Description: In User Settings Edit
  7. # @FilePath: \GpsCardAdmin\setup_test.sh
  8. ###
  9. #!/usr/bin/env bash
  10. npm -v
  11. npm config set registry https://registry.npm.taobao.org
  12. npm config list
  13. npm install
  14. npm run build-test
  15. image_version=$version
  16. # 删除镜像
  17. docker rmi -f $(
  18. docker images | grep 139.224.254.18:5000/gps_card_admin | awk '{print $3}'
  19. )
  20. # 构建gps_card_admin:$image_version镜像
  21. docker build . -t telpo/gps_card_admin:$image_version;
  22. #TODO:推送镜像到私有仓库
  23. echo '=================开始推送镜像======================='
  24. docker tag telpo/gps_card_admin:$image_version 139.224.254.18:5000/gps_card_admin:$image_version
  25. docker push 139.224.254.18:5000/gps_card_admin:$image_version
  26. echo '=================推送镜像完成======================='
  27. #删除产生的None镜像
  28. docker rmi -f $(docker images | grep none | awk '{print $3}')
  29. # 查看镜像列表
  30. docker images