release_frontend_docker.bat 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. echo off
  2. call setEnvVars.bat
  3. docker -v
  4. set START_TIME="%date:~0,10% %time:~0,2%:%time:~3,5%"
  5. echo start time %START_TIME%
  6. rem call Set-ExecutionPolicy RemoteSigned -Scope Process
  7. cd ./maxkey-web-frontend/maxkey-web-app
  8. rem ng build
  9. call ng build --base-href /maxkey/
  10. call docker build -f Dockerfile -t %MXK_REPOSITORY%/maxkey-frontend .
  11. rem maxkey-frontend:latest
  12. rem push to docker hub
  13. call docker push %MXK_REPOSITORY%/maxkey-frontend
  14. rem maxkey-frontend:$version
  15. call docker tag %MXK_REPOSITORY%/maxkey-frontend %MXK_REPOSITORY%/maxkey-frontend:%MXK_VERSION%
  16. rem push to docker hub
  17. call docker push %MXK_REPOSITORY%/maxkey-frontend:%MXK_VERSION%
  18. cd ../../
  19. cd ./maxkey-web-frontend/maxkey-web-mgt-app
  20. rem ng build
  21. call ng build --base-href /maxkey-mgt/
  22. call docker build -f Dockerfile -t %MXK_REPOSITORY%/maxkey-mgt-frontend .
  23. rem maxkey-mgt-frontend:latest
  24. rem push to docker hub
  25. call docker push %MXK_REPOSITORY%/maxkey-mgt-frontend
  26. rem maxkey-mgt-frontend:$version
  27. call docker tag %MXK_REPOSITORY%/maxkey-mgt-frontend %MXK_REPOSITORY%/maxkey-mgt-frontend:%MXK_VERSION%
  28. rem push to docker hub
  29. call docker push %MXK_REPOSITORY%/maxkey-mgt-frontend:%MXK_VERSION%
  30. set END_TIME="%date:~0,10% %time:~0,2%:%time:~3,5%"
  31. echo Build Release start at %START_TIME% complete at %END_TIME%.
  32. pause