Cloud Computing Course
Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

129 Zeilen
3.2 KiB

vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
vor 3 Jahren
  1. # Library_Auto_Seats_Pick
  2. ##### For Cloud Computing Course
  3. ------
  4. ### Background
  5. The end of each semester could always evoke the students' enthusiasm for learning, while the library resources of Zhongbei campus are quite worse than Minhang campus, which means there is more competition for seats. And this might cause some students can't reserve a seat for several days.
  6. This project aims to provide automatic seat-grab solutions for students with low screen time, raising the efficiency of seats grabbing.
  7. ### Install
  8. - ##### This project uses Python, Flask, Chrome and Chromedrvier. Go check them out if you don't have them locally installed.
  9. - **Install Flask**
  10. Open a terminal, make a new folder to store the project. Let's call this folder **autobook**.
  11. If you are using Python 3.6, enter **autobook** and create a virtual environment.
  12. ```shell
  13. python3 -m venv flask
  14. ```
  15. Type these commands one by one to install Flask and its extension.
  16. ```shell
  17. flask/bin/pip install flask
  18. flask/bin/pip install flask-login
  19. flask/bin/pip install flask-openid
  20. flask/bin/pip install flask-mail
  21. flask/bin/pip install flask-sqlalchemy
  22. flask/bin/pip install sqlalchemy-migrate
  23. flask/bin/pip install flask-whooshalchemy
  24. flask/bin/pip install flask-wtf
  25. flask/bin/pip install flask-babel
  26. flask/bin/pip install guess_language
  27. flask/bin/pip install flipflop
  28. flask/bin/pip install coverage
  29. ```
  30. - **Install Chrome**
  31. ```shell
  32. yum -y install google-chrome-stable
  33. ```
  34. - **Install Chromedriver**
  35. The version of Chromedriver should be consistent with your Chrome's. If you don't know your Chrome's version, try to type this command to check out.
  36. ```shell
  37. google-chrome --version
  38. ```
  39. Go to this address to find a matching version of Chrome.
  40. http://chromedriver.storage.googleapis.com/index.html
  41. You could download the .zip file to your PC, transfer to your cloud host via Xftp or something else, and unzip it later.
  42. Or you might use this command.
  43. ```shell
  44. wget https://npm.taobao.org/mirrors/chromedriver/83.0.4103.14/chromedriver_linux64.zip
  45. unzip chromedriver_linux64.zip
  46. ```
  47. Just to make sure everything goes well, you might as well type this to avoid possible permission problem.
  48. ```shell
  49. chmod a+x chromedriver
  50. ```
  51. - **Other necessary Python modules**
  52. Use Pip to install some essential modules.
  53. ```shell
  54. pip3 install pyvirtualdisplay
  55. pip3 install selenium
  56. pip3 install PyEmail
  57. pip3 install gevent
  58. ```
  59. ### Usage
  60. - ##### Deploy
  61. Determine run.py as an executable file.
  62. ```shell
  63. chmod a+x run.py
  64. ```
  65. Run as follows.
  66. ```shell
  67. ./run.py
  68. ```
  69. - ##### Customer use
  70. Visit the website:
  71. http://127.0.0.1:5000/
  72. ![login page](http://gitea.shuishan.net.cn/10195501441/Library_Auto_Seats_Pick/src/branch/master/img-folder/login.png)
  73. ![success page](http://gitea.shuishan.net.cn/10195501441/Library_Auto_Seats_Pick/src/branch/master/img-folder/success.png)
  74. ### Maintainers
  75. [@Young Hojan](http://gitea.shuishan.net.cn/10195501441)
  76. ### License
  77. [MIT](http://gitea.shuishan.net.cn/10195501441/Library_Auto_Seats_Pick/src/branch/master/LICENSE.md) © Young Hojan