Fedora Remix maintained by the Rochester Institute of Technology (RIT) Linux Users Group, targeted at users new to Linux and RIT students, faculty, and staff
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
1.4 KiB

  1. #!/bin/bash
  2. set -eu
  3. #####################################################################
  4. # TigerOS Build Script for running on the build box with Jenkins CI #
  5. # @author: Aidan Kahrs #
  6. # #
  7. # Usage: sudo bash ci-build-mock.sh #
  8. # #
  9. #####################################################################
  10. # Check that the current user is root
  11. if [ $EUID != 0 ]
  12. then
  13. echo "Please run this script as root (sudo $@$0)."
  14. exit
  15. fi
  16. wget -O tigeros.ks https://raw.githubusercontent.com/RITlug/TigerOS/master/tigeros.ks
  17. mock -r fedora-25-x86_64 --init
  18. mock -r fedora-25-x86_64 --copyin tigeros.ks ./tigeros.ks
  19. mock -r fedora-25-x86_64 --install lorax-lmc-novirt git vim-minimal pykickstart
  20. mock -r fedora-25-x86_64 --chroot "livemedia-creator --ks tigeros.ks --no-virt --resultdir /var/lmc --project TigerOS-Live --make-iso --volid TigerOS --iso-only --iso-name TigerOS.iso --releasever 25 --title TigerOS-live --macboot"
  21. rm -rf /srv/isos/TigerOS-$(date +%Y%m%d).iso
  22. mock -r fedora-25-x86_64 --copyout /var/lmc/TigerOS.iso /srv/isos/TigerOS-$(date +%Y%m%d).iso
  23. rm -rf /var/lmc/
  24. cd /srv/isos
  25. rm -rf CHECKSUM512-$(date +%Y%m%d)
  26. sha512sum TigerOS-$(date +%Y%m%d).iso > CHECKSUM512-$(date +%Y%m%d)
  27. chown -R nginx:nginx /srv
  28. chmod 755 /srv/isos/*.iso
  29. echo "Build finished"