qubes-core-netvm 740 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. #!/bin/bash
  2. #
  3. # chkconfig: 345 90 90
  4. # description: Executes Qubes core scripts at NetVM boot
  5. #
  6. # Source function library.
  7. # shellcheck disable=SC1091
  8. . /etc/rc.d/init.d/functions
  9. # Source Qubes library.
  10. # shellcheck source=init/functions
  11. . /usr/lib/qubes/init/functions
  12. start()
  13. {
  14. have_qubesdb || return
  15. if is_netvm; then
  16. /usr/lib/qubes/network-manager-prepare-conf-dir
  17. /sbin/service NetworkManager start
  18. fi
  19. echo -n $"Executing Qubes Core scripts NetVM:"
  20. # shellcheck disable=SC2015
  21. /usr/lib/qubes/init/network-proxy-setup && success || failure
  22. echo
  23. }
  24. stop()
  25. {
  26. return 0
  27. }
  28. case "$1" in
  29. start)
  30. start
  31. ;;
  32. stop)
  33. stop
  34. ;;
  35. *)
  36. echo $"Usage: $0 {start|stop}"
  37. exit 3
  38. ;;
  39. esac
  40. # shellcheck disable=SC2086
  41. exit $RETVAL