Permalink
Browse files

Add rhel-7.2-iso build script

I've just confirmed that rhel-7.2 from iso build work correctly!

As a quick addendum: I've previously mentioned an issue with
virt-builder allocating a storage pool, but not cleaning it up after
creation. I've tried solving this with the commandline and I believe
I've succeeded. If you do not do this, then the oh-my-vagrant machine will have a collision when trying to `up` a machine with the same image name.

$ virsh -c qemu:///system pool-list
 Name                 State      Autostart
-------------------------------------------
 default              active     yes
 iso                  active     yes
 rhel-7.2-iso         active     yes
 tmp                  active     yes
 v7                   active     yes

$ virsh -c qemu:///system pool-destroy rhel-7.2-iso
Pool rhel-7.2-iso destroyed

$ virsh -c qemu:///system pool-delete rhel-7.2-iso
error: Failed to delete pool rhel-7.2-iso
error: failed to remove pool '/home/james/tmp/builder/rhel-7.2-iso': Directory not empty

$ virsh -c qemu:///system pool-undefine rhel-7.2-iso
Pool rhel-7.2-iso has been undefined

Please note that the delete wasn't necessary, and in fact it's the wrong operation, but I ran it to see what results it would have. Perhaps this should be incorporated into the vagrant-builder script as a cleanup operation. We could patch this after it has been reproduced and properly understood.

This is issue: #8
  • Loading branch information...
1 parent ca90c6c commit e99f888a5cde5ad152c8e27b37c8202763bc9357 @purpleidea committed Dec 13, 2015
Showing with 21 additions and 0 deletions.
  1. +21 −0 v7/versions/rhel-7.2-iso.sh
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+# to use this script, from its parent dir, run: ./versions/<script>.sh <target>
+# you'll want to edit the below bash variables to match your use cases :)
+# eg: ./versions/rhel-7.2.sh upload
+# to make your own base image and upload it to your own server somewhere.
+
+VERSION='rhel-7.2'
+POSTFIX='iso'
+ISO='rhel-server-7.2-x86_64-dvd.iso'
+SIZE='40' # disk size of image
+SERVER=''
+REMOTE_PATH='' # make a $VERSION directory in this dir
+KEYS='EPEL-7 puppetlabs' # add extra keys to the base image
+REPOS='epel7 epel7-testing el7-puppet' # add extra repos for docker, etc...
+DOCKER=''
+# TODO: add moreutils
+PACKAGES='sudo vim-enhanced git wget file man tree nmap tcpdump htop lsof telnet mlocate bind-utils koan iftop yum-utils nc psmisc bash-completion'
+POOLID=''
+RHELREPOS='rhel-7-server-rpms rhel-7-server-extras-rpms'
+make VERSION=$VERSION POSTFIX=$POSTFIX ISO=$ISO SERVER=$SERVER REMOTE_PATH=$REMOTE_PATH KEYS="$KEYS" REPOS="$REPOS" DOCKER="$DOCKER" PACKAGES="$PACKAGES" POOLID="$POOLID" RHELREPOS="$RHELREPOS" $@

0 comments on commit e99f888

Please sign in to comment.