RPi3_4install.sh 907 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. #!/bin/sh -e
  2. if [ "$(id -u)" != "0" ]; then
  3. echo "Run as Root" 1>&2
  4. exit 1
  5. fi
  6. sudo apt-get update -y && apt-get upgrade -y
  7. sudo apt install tmux apache2 iptables git npm php dnsmasq apache2 dnsmasq-base python hostapd mdk3 macchanger -y
  8. git clone https://github.com/adamff24/PwrDeauther.git
  9. cp -f dnsmasq.conf /etc/
  10. cp -Rf html /var/www/
  11. chown -R www-data:www-data /var/www/html
  12. chown root:www-data /var/www/html/.htaccess
  13. chmod 777 /var/www/html/creds.txt
  14. cp -f override.conf /etc/apache2/conf-available/
  15. cd /etc/apache2/conf-enabled
  16. ln -s ../conf-available/override.conf override.conf
  17. cd /etc/apache2/mods-enabled
  18. ln -s ../mods-available/rewrite.load rewrite.load
  19. git clone --depth 1 --recursive https://github.com/gildas-lormeau/SingleFile.git
  20. chown -R pi:pi SingleFile/
  21. cd SingleFile
  22. npm install
  23. cd cli
  24. chmod +x single-file
  25. systemctl disable hostapd
  26. systemctl disable dnsmasq