alpine-whoogle-install.sh 1014 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. #!/usr/bin/env bash
  2. # Copyright (c) 2021-2023 tteck
  3. # Author: tteck (tteckster)
  4. # License: MIT
  5. # https://github.com/tteck/Proxmox/raw/main/LICENSE
  6. source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
  7. color
  8. verb_ip6
  9. catch_errors
  10. setting_up_container
  11. network_check
  12. update_os
  13. msg_info "Installing Dependencies"
  14. $STD apk add newt
  15. $STD apk add curl
  16. $STD apk add openssh
  17. $STD apk add nano
  18. $STD apk add mc
  19. msg_ok "Installed Dependencies"
  20. msg_info "Installing pip3 Package Manager"
  21. $STD apk add py3-pip
  22. msg_ok "Installed pip3 Package Manager"
  23. msg_info "Installing Alpine-Whoogle"
  24. $STD pip3 install brotli
  25. $STD pip3 install whoogle-search
  26. echo "#!/sbin/openrc-run
  27. description=\"Whoogle-Search\"
  28. pidfile=\"/run/whoogle.pid\"
  29. start() {
  30. /usr/bin/whoogle-search --host 0.0.0.0 &
  31. echo \$! > \$pidfile
  32. }
  33. stop() {
  34. kill \$(cat \$pidfile)
  35. rm \$pidfile
  36. }" >/etc/init.d/whoogle
  37. chmod 755 /etc/init.d/whoogle
  38. rc-service -q whoogle start
  39. rc-update add -q whoogle default
  40. msg_ok "Installed Alpine-Whoogle"
  41. motd_ssh
  42. root