天波用户运营管理后台系统
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 satır
941B

  1. ###
  2. # @Author: JinxuChen
  3. # @Date: 2021-11-15
  4. # @LastEditTime: 2021-12-02 09:21:48
  5. # @LastEditors: JinxuChen
  6. # @Description: In User Settings Edit
  7. # @FilePath: \GpsCardAdmin\setup_development.sh
  8. ###
  9. #!/bin/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=`date +%Y%m%d%H%M`;
  16. docker stop gps_card_admin || true;
  17. # 删除gps_parent_web容器
  18. docker rm gps_card_admin || true;
  19. # 删除镜像
  20. docker rmi -f $(docker images | grep telpo/gps_card_admin | awk '{print $3}')
  21. # 构建telpo/gps_card_admin:$image_version镜像
  22. docker build . -t telpo/gps_card_admin:$image_version;
  23. #删除产生的None镜像
  24. docker rmi -f $(docker images | grep none | awk '{print $3}')
  25. # 查看镜像列表
  26. docker images;
  27. # 启动容器
  28. docker run -p 8802:80 -d --restart=always --name gps_card_admin telpo/gps_card_admin:$image_version;
  29. # 查看日志
  30. docker logs gps_card_admin;