local_dev.sh 577 B

12345678910111213141516171819202122232425262728293031
  1. # 本地dev脚本
  2. echo 'remove container'
  3. docker container stop catalog_site_prod
  4. docker container rm catalog_site_prod
  5. docker container stop catalog_site
  6. docker container rm catalog_site
  7. echo 'remove image'
  8. docker rmi catalog_site:prod
  9. docker rmi catalog_site:dev
  10. echo 'remove package-lock.json'
  11. rm package-lock.json
  12. echo 'remove .nuxt'
  13. rm -rf .nuxt
  14. echo 'remove node_modules'
  15. rm -rf node_modules
  16. echo 'docker build'
  17. docker build -t catalog_site:dev .
  18. echo 'docker run dev container'
  19. docker run -d -p 10174:9877 -v ${PWD}:/app --name catalog_site catalog_site:dev