install.sh 586 B

1234567891011121314151617181920212223242526272829
  1. #!/bin/bash
  2. echo "=========================="
  3. echo
  4. echo "Nginx UI Install Shell"
  5. echo "Copyright (c) 0xJacky 2021"
  6. echo
  7. echo "=========================="
  8. echo "installing yarn..."
  9. npm install -g yarn
  10. echo "Compiling frontend..."
  11. cd nginx-ui-frontend || exit 1
  12. yarn build
  13. cd ..
  14. echo "Compiling api server..."
  15. cd server || exit 1
  16. go build -o nginx-ui-server main.go
  17. echo "build completed"
  18. cd ..
  19. echo "==============="
  20. echo "frontend dist path: nginx-ui-frontend/dist"
  21. echo "start server, run server/nginx-ui-server"
  22. echo "start server at background, run nohup ./nginx-ui-server &"