Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1401681
  • 博文数量: 343
  • 博客积分: 13098
  • 博客等级: 上将
  • 技术积分: 2862
  • 用 户 组: 普通用户
  • 注册时间: 2005-07-06 00:35
文章存档

2012年(131)

2011年(31)

2010年(53)

2009年(23)

2008年(62)

2007年(2)

2006年(36)

2005年(5)

分类: 虚拟化

2012-08-20 20:48:58

 litevirt-config-0.0.1.zip    litevirt-create-0.0.1.zip   

build.sh


  1. #!/bin/sh

  2. livecd-creator --cache=./cache --shell --config=litevirt-hypervisor-livecd.ks --fslabel=Litevirt-Hypervisor-LiveCD -d
litevirt-hypervisor-livecd.ks

  1. firewall --disabled

  2. repo --name="f17" --mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=fedora-17&arch=x86_64
  3. repo --name="f17-updates" --mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=updates-released-f17&arch=x86_64

  4. device virtio_blk
  5. device virtio_pci
  6. device scsi_wait_scan
  7. device dm-multipath
  8. device dm-round-robin
  9. device dm-emc
  10. device dm-rdac
  11. device dm-hp-sw
  12. device scsi_dh_rdac
  13. device 3w-9xxx
  14. device 3w-sas
  15. device 3w-xxxx
  16. device a100u2w
  17. device aacraid
  18. device aic79xx
  19. device aic94xx
  20. device arcmsr
  21. device atp870u
  22. device be2iscsi
  23. device bfa
  24. device BusLogic
  25. device cciss
  26. device cxgb3i
  27. device dc395x
  28. device fnic
  29. device gdth
  30. device hpsa
  31. device hptiop
  32. device imm
  33. device initio
  34. device ips
  35. device libosd
  36. device libsas
  37. device libsrp
  38. device lpfc
  39. device megaraid
  40. device megaraid_mbox
  41. device megaraid_mm
  42. device megaraid_sas
  43. device mpt2sas
  44. device mvsas
  45. device osd
  46. device osst
  47. device pm8001
  48. device pmcraid
  49. device qla1280
  50. device qla2xxx
  51. device qla4xxx
  52. device qlogicfas408
  53. device stex
  54. device tmscsim
  55. device ums-sddr09
  56. device ums-realtek
  57. device ums-sddr55
  58. device ums-isd200
  59. device ums-alauda
  60. device ums-freecom
  61. device ums-cypress
  62. device ums-jumpshot
  63. device ums-onetouch
  64. device ums-karma
  65. device ums-usbat
  66. device ums-datafab
  67. device ums-eneub6250
  68. # System authorization information
  69. auth --useshadow --enablemd5
  70. # System keyboard
  71. keyboard us
  72. # System language
  73. lang en_US.UTF-8
  74. # SELinux configuration
  75. selinux --disabled
  76. # Installation logging level
  77. logging --level=info

  78. # System services
  79. services --enabled="sshd,snmpd"
  80. # System timezone
  81. timezone --isUtc UTC
  82. # System bootloader configuration
  83. bootloader --append="elevator=deadline" --location=mbr --timeout=30
  84. # Disk partitioning information
  85. part / --fstype="ext2" --size=1024

  86. %post
  87. echo "Starting Kickstart Post"
  88. PATH=/sbin:/usr/sbin:/bin:/usr/bin
  89. export PATH

  90. echo "Refine crond service"
  91. rm -f /etc/cron.daily/logrotate

  92. echo "Initialize snmp service"
  93. cat > /etc/snmp/snmpd.conf << \EOF_snmpd
  94. master agentx
  95. dontLogTCPWrappersConnects yes
  96. rwuser root auth .1
  97. EOF_snmpd

  98. echo "Strip out all unncesssary locales"
  99. localedef --list-archive | grep -v -i -E 'en_US.utf8' |xargs localedef --delete-from-archive
  100. mv /usr/lib/locale/locale-archive /usr/lib/locale/locale-archive.tmpl
  101. /usr/sbin/build-locale-archive


  102. echo "Mount kernel debugfs"
  103. echo "debugfs /sys/kernel/debug debugfs auto 0 0" >> /etc/fstab

  104. echo "switch to multi-user mode"
  105. ln -sf /usr/lib/systemd/system/multi-user.target /etc/systemd/system/default.target

  106. echo "Disable unnecessary services"
  107. systemctl disable iptables.service
  108. systemctl disable ip6tables.service
  109. systemctl disable readahead_early.service
  110. systemctl disable readahead_later.service

  111. echo "create admin users"
  112. passwd -d root

  113. echo "disable selinux"
  114. [ -f /etc/selinux/config ] && sed -i 's/SELINUX=enforcing/SELINUX=disabled/' /etc/selinux/config

  115. %end

  116. %post --nochroot
  117. PRODUCT='Litevirt Hypervisor'
  118. PRODUCT_SHORT='Litevirt Hypervisor'
  119. VERSION=0.0.1
  120. RELEASE=1.fc17


  121. # overwrite user visible banners with the image versioning info
  122. echo "Fix release info"
  123. cat > $INSTALL_ROOT/etc/litevirt-release <<EOF
  124. $PRODUCT release $VERSION ($RELEASE)
  125. EOF
  126. rm -rf $INSTALL_ROOT/etc/fedora-release
  127. ln -snf litevirt-release $INSTALL_ROOT/etc/redhat-release
  128. ln -snf litevirt-release $INSTALL_ROOT/etc/system-release
  129. cp $INSTALL_ROOT/etc/litevirt-release $INSTALL_ROOT/etc/issue
  130. echo "Kernel \r on an \m (\l)" >> $INSTALL_ROOT/etc/issue
  131. cp $INSTALL_ROOT/etc/issue $INSTALL_ROOT/etc/issue.net

  132. echo "Fix boot menu"
  133. # remove quiet from Node bootparams, added by livecd-creator
  134. sed -i -e 's/ quiet//' $LIVE_ROOT/isolinux/isolinux.cfg

  135. # Remove Verify and Boot option
  136. sed -i -e '/label check0/{N;N;N;d;}' $LIVE_ROOT/isolinux/isolinux.cfg


  137. # add serial console boot entry
  138. menu=$(mktemp)
  139. awk '
  140. /^label linux0/ { linux0=1 }
  141. linux0==1 && $1=="append" {
  142.   append0=$0
  143. }
  144. linux0==1 && $1=="label" && $2!="linux0" {
  145.   linux0=2
  146.   print "label Litevirt Hypervisor"
  147.   print " menu label Litevirt Hypervisor"
  148.   print " kernel vmlinuz0"
  149.   print append0" nomodeset "
  150. }
  151. { print }
  152. ' $LIVE_ROOT/isolinux/isolinux.cfg > $menu
  153. # change the title
  154. sed -i -e '/^menu title/d' $menu
  155. echo "say This is the $PRODUCT $VERSION ($RELEASE)" > $LIVE_ROOT/isolinux/isolinux.cfg
  156. echo "menu title ${PRODUCT_SHORT} $VERSION ($RELEASE)" >> $LIVE_ROOT/isolinux/isolinux.cfg
  157. cat $menu >> $LIVE_ROOT/isolinux/isolinux.cfg
  158. rm $menu

  159. NAME=$(grep CDLABEL $LIVE_ROOT/isolinux/isolinux.cfg |head -n1|sed -r 's/^.*CDLABEL\=([a-zA-Z0-9_\.-]+) .*$/\1/g')

  160. #setup efi boot menu
  161. cat > $LIVE_ROOT/EFI/BOOT/BOOTX64.conf <<EOF
  162. default=0
  163. splashimage=/EFI/BOOT/splash.xpm.gz
  164. timeout 30
  165. hiddenmenu
  166. title Litevirt Hypervisor
  167.   kernel /isolinux/vmlinuz0 root=live:CDLABEL=$NAME rootfstype=auto ro liveimg check rootflags=ro elevator=deadline quiet
  168.   initrd /isolinux/initrd0.img
  169. EOF

  170. %end

  171. %post --interpreter=image-minimizer --nochroot
  172. droprpm system-config-*
  173. keeprpm system-config-keyboard-base
  174. droprpm libsemanage-python

  175. droprpm mkinitrd
  176. droprpm isomd5sum
  177. droprpm checkpolicy
  178. droprpm make
  179. droprpm setools-libs-python
  180. droprpm setools-libs

  181. droprpm gamin
  182. droprpm pm-utils
  183. droprpm usermode
  184. droprpm vbetool
  185. droprpm ConsoleKit
  186. droprpm hdparm
  187. droprpm linux-atm-libs
  188. droprpm mtools
  189. droprpm syslinux
  190. droprpm wireless-tools
  191. droprpm radeontool
  192. droprpm libicu
  193. droprpm gnupg2
  194. droprpm fedora-release-notes
  195. droprpm fedora-logos

  196. # rhbz#641494 - drop unnecessary rpms pulled in from libguestfs-winsupport
  197. droprpm fakechroot
  198. droprpm fakechroot-libs
  199. droprpm fakeroot
  200. droprpm fakeroot-libs
  201. droprpm febootstrap

  202. # cronie pulls in exim (sendmail) which pulls in all kinds of perl deps
  203. droprpm exim
  204. droprpm perl*
  205. # keep libperl for snmpd
  206. keeprpm perl-libs
  207. droprpm postfix
  208. droprpm mysql*

  209. droprpm sysklogd

  210. # pam complains when this is missing
  211. keeprpm ConsoleKit-libs

  212. # kernel modules minimization

  213. # filesystems
  214. drop /lib/modules/*/kernel/fs
  215. keep /lib/modules/*/kernel/fs/ext*
  216. keep /lib/modules/*/kernel/fs/mbcache*
  217. keep /lib/modules/*/kernel/fs/squashfs
  218. keep /lib/modules/*/kernel/fs/jbd*
  219. keep /lib/modules/*/kernel/fs/btrfs
  220. keep /lib/modules/*/kernel/fs/cifs*
  221. keep /lib/modules/*/kernel/fs/fat
  222. keep /lib/modules/*/kernel/fs/nfs
  223. keep /lib/modules/*/kernel/fs/nfs_common
  224. keep /lib/modules/*/kernel/fs/fscache
  225. keep /lib/modules/*/kernel/fs/lockd
  226. keep /lib/modules/*/kernel/fs/nls/nls_utf8.ko
  227. keep /lib/modules/*/kernel/fs/configfs/configfs.ko
  228. # autofs4 configfs exportfs *fat *jbd mbcache.ko nls xfs
  229. #*btrfs cramfs *ext2 *fscache *jbd2 *nfs squashfs
  230. # cachefiles dlm *ext3 fuse jffs2 *nfs_common ubifs
  231. # cifs ecryptfs *ext4 gfs2 *lockd nfsd udf

  232. # network
  233. drop /lib/modules/*/kernel/net
  234. keep /lib/modules/*/kernel/net/802*
  235. keep /lib/modules/*/kernel/net/bridge
  236. keep /lib/modules/*/kernel/net/core
  237. keep /lib/modules/*/kernel/net/ipv*
  238. keep /lib/modules/*/kernel/net/key
  239. keep /lib/modules/*/kernel/net/llc
  240. keep /lib/modules/*/kernel/net/netfilter
  241. keep /lib/modules/*/kernel/net/rds
  242. keep /lib/modules/*/kernel/net/sctp
  243. keep /lib/modules/*/kernel/net/sunrpc
  244. #*802 atm can ieee802154 *key *netfilter rfkill *sunrpc xfrm
  245. #*8021q bluetooth *core *ipv4 *llc phonet sched wimax
  246. # 9p *bridge dccp *ipv6 mac80211 *rds *sctp wireless

  247. drop /lib/modules/*/kernel/sound

  248. # drivers
  249. drop /lib/modules/*/kernel/drivers
  250. keep /lib/modules/*/kernel/drivers/ata
  251. keep /lib/modules/*/kernel/drivers/block
  252. keep /lib/modules/*/kernel/drivers/cdrom
  253. keep /lib/modules/*/kernel/drivers/char
  254. keep /lib/modules/*/kernel/drivers/cpufreq
  255. keep /lib/modules/*/kernel/drivers/dca
  256. keep /lib/modules/*/kernel/drivers/dma
  257. keep /lib/modules/*/kernel/drivers/edac
  258. keep /lib/modules/*/kernel/drivers/firmware
  259. keep /lib/modules/*/kernel/drivers/idle
  260. keep /lib/modules/*/kernel/drivers/infiniband
  261. keep /lib/modules/*/kernel/drivers/input/misc/uinput.ko
  262. keep /lib/modules/*/kernel/drivers/md
  263. keep /lib/modules/*/kernel/drivers/message
  264. keep /lib/modules/*/kernel/drivers/net
  265. drop /lib/modules/*/kernel/drivers/net/pcmcia
  266. drop /lib/modules/*/kernel/drivers/net/wireless
  267. drop /lib/modules/*/kernel/drivers/net/ppp*
  268. keep /lib/modules/*/kernel/drivers/pci
  269. keep /lib/modules/*/kernel/drivers/scsi
  270. keep /lib/modules/*/kernel/drivers/staging/ramzswap
  271. keep /lib/modules/*/kernel/drivers/uio
  272. keep /lib/modules/*/kernel/drivers/usb
  273. drop /lib/modules/*/kernel/drivers/usb/atm
  274. drop /lib/modules/*/kernel/drivers/usb/class
  275. drop /lib/modules/*/kernel/drivers/usb/image
  276. drop /lib/modules/*/kernel/drivers/usb/misc
  277. drop /lib/modules/*/kernel/drivers/usb/serial
  278. keep /lib/modules/*/kernel/drivers/usb/storage
  279. keep /lib/modules/*/kernel/drivers/vhost
  280. keep /lib/modules/*/kernel/drivers/virtio
  281. keep /lib/modules/*/kernel/drivers/watchdog

  282. # acpi *cpufreq hid leds mtd ?regulator uwb
  283. #*ata crypto ?hwmon *md *net* rtc *vhost
  284. # atm *dca ?i2c media ?parport *scsi* video
  285. # auxdisplay *dma *idle memstick *pci ?serial *virtio
  286. #*block *edac ieee802154 *message pcmcia ?ssb watchdog
  287. # bluetooth firewire *infiniband ?mfd platform *staging xen
  288. #*cdrom *firmware input misc ?power ?uio
  289. #*char* ?gpu isdn mmc ?pps *usb

  290. drop /usr/share/zoneinfo
  291. keep /usr/share/zoneinfo/UTC

  292. drop /etc/alsa
  293. drop /usr/share/alsa
  294. drop /usr/share/awk
  295. drop /usr/share/vim
  296. drop /usr/share/anaconda
  297. drop /usr/share/backgrounds
  298. drop /usr/share/wallpapers
  299. drop /usr/share/kde-settings
  300. drop /usr/share/gnome-background-properties
  301. drop /usr/share/dracut
  302. drop /usr/share/setuptool
  303. drop /usr/share/hwdata/MonitorsDB
  304. drop /usr/share/hwdata/oui.txt
  305. drop /usr/share/hwdata/videoaliases
  306. drop /usr/share/hwdata/videodrivers
  307. drop /usr/share/firstboot
  308. drop /usr/share/lua
  309. drop /usr/share/kde4
  310. drop /usr/share/pixmaps
  311. drop /usr/share/icons
  312. drop /usr/share/fedora-release
  313. drop /usr/share/tabset
  314. drop /usr/share/augeas/lenses/tests
  315. drop /usr/share/augeas/lenses/dist/*
  316. # generic includes
  317. keep /usr/share/augeas/lenses/dist/build.aug
  318. keep /usr/share/augeas/lenses/dist/hosts.aug
  319. keep /usr/share/augeas/lenses/dist/inifile.aug
  320. keep /usr/share/augeas/lenses/dist/modprobe.aug
  321. keep /usr/share/augeas/lenses/dist/rx.aug
  322. keep /usr/share/augeas/lenses/dist/sep.aug
  323. keep /usr/share/augeas/lenses/dist/shellvars.aug
  324. keep /usr/share/augeas/lenses/dist/spacevars.aug
  325. keep /usr/share/augeas/lenses/dist/sysctl.aug
  326. keep /usr/share/augeas/lenses/dist/util.aug
  327. # whitelist only relevant lenses
  328. keep /usr/share/augeas/lenses/dist/buildd.aug
  329. keep /usr/share/augeas/lenses/dist/cgconfig.aug
  330. keep /usr/share/augeas/lenses/dist/cgrules.aug
  331. keep /usr/share/augeas/lenses/dist/cron.aug
  332. keep /usr/share/augeas/lenses/dist/dhclient.aug
  333. keep /usr/share/augeas/lenses/dist/dnsmasq.aug
  334. keep /usr/share/augeas/lenses/dist/ethers.aug
  335. keep /usr/share/augeas/lenses/dist/exports.aug
  336. keep /usr/share/augeas/lenses/dist/fstab.aug
  337. keep /usr/share/augeas/lenses/dist/group.aug
  338. keep /usr/share/augeas/lenses/dist/grub.aug
  339. keep /usr/share/augeas/lenses/dist/inittab.aug
  340. keep /usr/share/augeas/lenses/dist/iptables.aug
  341. keep /usr/share/augeas/lenses/dist/json.aug
  342. keep /usr/share/augeas/lenses/dist/krb5.aug
  343. keep /usr/share/augeas/lenses/dist/limits.aug
  344. keep /usr/share/augeas/lenses/dist/logrotate.aug
  345. keep /usr/share/augeas/lenses/dist/lokkit.aug
  346. keep /usr/share/augeas/lenses/dist/modules_conf.aug
  347. keep /usr/share/augeas/lenses/dist/multipath.aug
  348. keep /usr/share/augeas/lenses/dist/ntp.aug
  349. keep /usr/share/augeas/lenses/dist/pam.aug
  350. keep /usr/share/augeas/lenses/dist/passwd.aug
  351. keep /usr/share/augeas/lenses/dist/resolv.aug
  352. keep /usr/share/augeas/lenses/dist/securetty.aug
  353. keep /usr/share/augeas/lenses/dist/services.aug
  354. keep /usr/share/augeas/lenses/dist/shellvars_list.aug
  355. keep /usr/share/augeas/lenses/dist/sshd.aug
  356. keep /usr/share/augeas/lenses/dist/sudoers.aug
  357. keep /usr/share/augeas/lenses/dist/utill.aug
  358. keep /usr/share/augeas/lenses/dist/yum.aug
  359. drop /usr/share/tc
  360. drop /usr/share/emacs
  361. drop /usr/share/info
  362. drop /usr/src
  363. drop /usr/etc
  364. drop /usr/games
  365. drop /usr/include
  366. keep /usr/include/python2.*
  367. drop /usr/local
  368. drop /usr/sbin/dell*
  369. keep /usr/sbin/build-locale-archive
  370. drop /usr/sbin/glibc_post_upgrade.*
  371. drop /usr/lib*/tc
  372. drop /usr/lib*/tls
  373. drop /usr/lib*/sse2
  374. drop /usr/lib*/pkgconfig
  375. drop /usr/lib*/nss
  376. drop /usr/lib*/games
  377. drop /usr/lib*/alsa-lib
  378. drop /usr/lib*/krb5
  379. drop /usr/lib*/hal
  380. drop /usr/lib*/gio
  381. # syslinux
  382. drop /usr/share/syslinux
  383. # glibc-common locales
  384. drop /usr/lib/locale
  385. keep /usr/lib/locale/locale-archive
  386. keep /usr/lib/locale/usr/share/locale/en_US
  387. # pango
  388. drop /usr/lib*/pango
  389. drop /usr/lib*/libpango*
  390. drop /usr/lib*/libthai*
  391. drop /usr/share/libthai
  392. drop /etc/pango
  393. drop /usr/bin/pango*
  394. # hal
  395. drop /usr/bin/hal-disable-polling
  396. drop /usr/bin/hal-is-caller-locked-out
  397. drop /usr/bin/hal-is-caller-privileged
  398. drop /usr/bin/hal-lock
  399. drop /usr/bin/hal-set-property
  400. drop /usr/bin/hal-setup-keymap
  401. # openssh
  402. drop /usr/bin/sftp
  403. drop /usr/bin/slogin
  404. drop /usr/bin/ssh-add
  405. drop /usr/bin/ssh-agent
  406. drop /usr/bin/ssh-keyscan
  407. # docs
  408. drop /usr/share/omf
  409. drop /usr/share/gnome
  410. drop /usr/share/doc
  411. keep /usr/share/doc/*-firmware-*
  412. drop /usr/share/locale/
  413. keep /usr/share/locale/en_US
  414. drop /usr/share/man
  415. drop /usr/share/X11
  416. drop /usr/share/i18n
  417. drop /boot/*
  418. keep /boot/efi
  419. drop /var/lib/builder
  420. drop /usr/sbin/rhn_register
  421. drop /usr/sbin/*-channel

  422. drop /usr/share/selinux

  423. drop /usr/lib*/libboost*
  424. keep /usr/lib*/libboost_program_options.so*
  425. keep /usr/lib*/libboost_filesystem.so*
  426. keep /usr/lib*/libboost_thread-mt.so*
  427. keep /usr/lib*/libboost_system.so*
  428. drop /usr/kerberos
  429. keep /usr/kerberos/bin/kinit
  430. keep /usr/kerberos/bin/klist
  431. drop /lib/firmware
  432. keep /lib/firmware/3com
  433. keep /lib/firmware/acenic
  434. keep /lib/firmware/adaptec
  435. keep /lib/firmware/advansys
  436. keep /lib/firmware/bnx2
  437. keep /lib/firmware/bnx2x
  438. keep /lib/firmware/bnx2x*
  439. keep /lib/firmware/cxgb3
  440. keep /lib/firmware/cxgb4
  441. keep /lib/firmware/e100
  442. keep /lib/firmware/myricom
  443. keep /lib/firmware/ql*
  444. keep /lib/firmware/sun
  445. keep /lib/firmware/tehuti
  446. keep /lib/firmware/tigon
  447. keep /lib/firmware/cbfw_fc.bin
  448. keep /lib/firmware/ctfw_cna.bin
  449. keep /lib/firmware/ctfw_fc.bin
  450. keep /lib/firmware/aic94xx-seq.fw

  451. drop /lib/kbd/consolefonts
  452. drop /etc/pki/tls
  453. keep /etc/pki/tls/openssl.cnf
  454. drop /etc/pki/java
  455. drop /etc/pki/nssdb

  456. # minimize net-snmp
  457. drop /etc/rc.d/init.d/snmptrapd
  458. drop /etc/snmp/snmptrapd.conf
  459. drop /etc/sysconfig/snmptrapd
  460. drop /usr/sbin/snmptrapd
  461. drop /usr/bin/net-snmp-create-v3-user
  462. drop /usr/bin/snmpconf
  463. drop /usr/share/snmp/snmpconf-data

  464. #desktop files
  465. drop /etc/xdg/autostart/restorecond.desktop

  466. #ebtables depends on perl
  467. drop /sbin/ebtables-save
  468. drop /sbin/ebtables-restore

  469. # remove bogus kdump script (rpmdiff complains)
  470. drop /etc/kdump-adv-conf

  471. #cim
  472. droprpm tog-pegasus
  473. droprpm tog-pegasus-libs
  474. droprpm mailcap
  475. droprpm openslp

  476. #remove rpms added by dmraid
  477. droprpm ConsoleKit
  478. droprpm checkpolicy
  479. droprpm dmraid-events
  480. droprpm gamin
  481. droprpm gnupg2
  482. droprpm hdparm
  483. droprpm isomd5sum
  484. droprpm libicu
  485. droprpm libsemanage-python
  486. droprpm linux-atm-libs
  487. droprpm make
  488. droprpm mtools
  489. droprpm mysql-libs
  490. droprpm perl
  491. droprpm perl-Module-Pluggable
  492. droprpm perl-Net-Telnet
  493. droprpm perl-PathTools
  494. droprpm perl-Pod-Escapes
  495. droprpm perl-Pod-Simple
  496. droprpm perl-Scalar-List-Utils
  497. droprpm perl-hivex
  498. droprpm perl-macros
  499. droprpm setools-libs
  500. droprpm setools-libs-python
  501. droprpm sgpio
  502. droprpm syslinux
  503. droprpm system-config-firewall-base
  504. droprpm usermode

  505. #NFS Server
  506. droprpm rpcbind
  507. drop /usr/sbin/rpc.idmapd
  508. drop /usr/bin/rpcgen
  509. drop /usr/sbin/rpc.gssd
  510. drop /usr/sbin/rpc.idmapd
  511. drop /usr/sbin/rpc.mountd
  512. drop /usr/sbin/rpc.nfsd
  513. drop /usr/sbin/rpc.svcgssd
  514. drop /usr/sbin/rpcdebug
  515. %end

  516. %post
  517. echo "Removing python source files"
  518. find /usr -name '*.py' -exec rm -f {} \;
  519. find /usr -name '*.pyo' -exec rm -f {} \;

  520. %end

  521. %post --nochroot
  522. if [ "$(uname -i)" = "i386" -o "$(uname -i)" = "x86_64" ]; then
  523.     if [ ! -d $LIVE_ROOT/LiveOS ]; then mkdir -p $LIVE_ROOT/LiveOS ; fi
  524.     cp /usr/bin/livecd-iso-to-disk $LIVE_ROOT/LiveOS
  525.     cp /usr/bin/livecd-iso-to-pxeboot $LIVE_ROOT/LiveOS
  526. fi
  527. %end

  528. %packages --excludedocs --nobase
  529. acpid
  530. aic94xx-firmware
  531. anyterm
  532. audit
  533. bc
  534. bfa-firmware
  535. db4
  536. device-mapper-multipath
  537. dhclient
  538. dmraid
  539. dosfstools
  540. e2fsprogs
  541. efibootmgr
  542. eject
  543. ethtool
  544. appliance-tools-minimizer
  545. file
  546. generic-logos
  547. grub-efi
  548. hdparm
  549. hwdata
  550. irqbalance
  551. kernel
  552. kpartx
  553. kvm
  554. less
  555. lsof
  556. lsscsi
  557. ltrace
  558. make
  559. net-snmp
  560. newt-python
  561. numactl
  562. openssh-clients
  563. openssh-server
  564. passwd
  565. pciutils
  566. psmisc
  567. python
  568. python-libs
  569. qemu-kvm
  570. qemu-kvm-tools
  571. ql2100-firmware
  572. ql2200-firmware
  573. ql23xx-firmware
  574. ql2400-firmware
  575. ql2500-firmware
  576. rootfiles
  577. rpm-python
  578. strace
  579. sudo
  580. sysfsutils
  581. sysstat
  582. tcpdump
  583. usbutils
  584. vconfig
  585. vim-minimal
  586. bash
  587. bridge-utils
  588. -audit-libs-python
  589. -authconfig
  590. -cpio
  591. -fedora-logos
  592. -fedora-release
  593. -fedora-release-notes
  594. -gzip
  595. -libselinux-python
  596. -libuser
  597. -mtools
  598. -newt
  599. -parted
  600. -prelink
  601. -setserial
  602. -tar
  603. -usermode
  604. -ustr
  605. -which
  606. -dracut
  607. -wireless-tools
  608. -yum-metadata-parser
  609. %end

阅读(1338) | 评论(0) | 转发(0) |
0

上一篇:QEMU live block copy

下一篇:extlinux

给主人留下些什么吧!~~