summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Callaghan <dcallagh@redhat.com>2016-07-20 12:10:43 +1000
committerDan Callaghan <dcallagh@redhat.com>2016-07-20 12:10:43 +1000
commitb963b6a96016393c0dafed0dc3f586facd6135b2 (patch)
treeb0929379b78069385fb20a7d7670200881dcedba
parenta9e587fc059f132fd4ac011ce67bbd368c3dd140 (diff)
delete old Beaker-in-a-box
We have the new one at https://git.beaker-project.org/cgit/beaker-in-a-box/ which is also referenced in the Beaker docs now.
-rw-r--r--.gitignore4
-rw-r--r--Makefile13
-rw-r--r--README1
-rw-r--r--docco.css199
-rw-r--r--in-a-box/beaker-distros38
-rw-r--r--in-a-box/beaker-setup108
-rw-r--r--in-a-box/beaker-virt198
-rw-r--r--in-a-box/beaker.ks89
-rw-r--r--in-a-box/index.html48
-rwxr-xr-xshocco.sh466
10 files changed, 2 insertions, 1162 deletions
diff --git a/.gitignore b/.gitignore
index f73e032..07a5e38 100644
--- a/.gitignore
+++ b/.gitignore
@@ -15,10 +15,6 @@
/docs-*/
/downloads.mk
/git-rev*
-/in-a-box/beaker.ks.html
-/in-a-box/beaker-setup.html
-/in-a-box/beaker-distros.html
-/in-a-box/beaker-virt.html
/old-downloads.mk
/releases/
/schema/
diff --git a/Makefile b/Makefile
index 845f6f0..f5fedf1 100644
--- a/Makefile
+++ b/Makefile
@@ -11,11 +11,6 @@ all: all-website yum
include downloads.mk
include old-downloads.mk
include changelogs.mk
-INABOX = \
- in-a-box/beaker.ks.html \
- in-a-box/beaker-setup.html \
- in-a-box/beaker-distros.html \
- in-a-box/beaker-virt.html
.PHONY: all-website
all-website: \
@@ -25,8 +20,7 @@ all-website: \
releases/index.atom \
$(DOWNLOADS) \
$(OLD_DOWNLOADS) \
- $(CHANGELOGS) \
- $(INABOX)
+ $(CHANGELOGS)
downloads.mk: generate-downloads-mk.py git_tags.py
./generate-downloads-mk.py $(BEAKER_GIT) >$@
@@ -78,13 +72,10 @@ releases/SHA256SUM: $(DOWNLOADS) $(OLD_DOWNLOADS)
yum::
./build-yum-repos.py --config yum-repos.conf --dest $@
-in-a-box/%.html: in-a-box/% shocco.sh
- ./shocco.sh $< >$@
-
.PHONY: check clean
check:
# ideas: spell check everything, validate HTML, check for broken links, run sphinx linkcheck builder
./check-yum-repos.py
clean:
- rm -f changelogs.mk downloads.mk releases/SHA1SUM releases/SHA256SUM releases/index.* $(INABOX)
+ rm -f changelogs.mk downloads.mk releases/SHA1SUM releases/SHA256SUM releases/index.*
diff --git a/README b/README
index 0dfa3ee..5c529d1 100644
--- a/README
+++ b/README
@@ -21,4 +21,3 @@ Dependencies
------------
* python-dulwich (to generate release changelogs)
-* rubygem-rdiscount ( to install markdown for shocco)
diff --git a/docco.css b/docco.css
deleted file mode 100644
index 99a3d8b..0000000
--- a/docco.css
+++ /dev/null
@@ -1,199 +0,0 @@
-/*
- * This is an old version of docco.css from Docco:
- * https://github.com/jashkenas/docco/blob/0c4c54ed2f19b3d2bd877a578110c4917cb64e65/resources/docco.css
- * which is copyright Jeremy Ashkenas, under MIT license.
- * (shocco has not been updated for the latest layout changes in Docco)
- */
-
-/*--------------------- Layout and Typography ----------------------------*/
-body {
- font-family: 'Palatino Linotype', 'Book Antiqua', Palatino, FreeSerif, serif;
- font-size: 15px;
- line-height: 22px;
- color: #252519;
- margin: 0; padding: 0;
-}
-a {
- color: #261a3b;
-}
- a:visited {
- color: #261a3b;
- }
-p {
- margin: 0 0 15px 0;
-}
-h1, h2, h3, h4, h5, h6 {
- margin: 0px 0 15px 0;
-}
- h1 {
- margin-top: 40px;
- }
-hr {
- border: 0 none;
- border-top: 1px solid #e5e5ee;
- height: 1px;
- margin: 20px 0;
-}
-#container {
- position: relative;
-}
-#background {
- position: fixed;
- top: 0; left: 525px; right: 0; bottom: 0;
- background: #f5f5ff;
- border-left: 1px solid #e5e5ee;
- z-index: -1;
-}
-#jump_to, #jump_page {
- background: white;
- -webkit-box-shadow: 0 0 25px #777; -moz-box-shadow: 0 0 25px #777;
- -webkit-border-bottom-left-radius: 5px; -moz-border-radius-bottomleft: 5px;
- font: 10px Arial;
- text-transform: uppercase;
- cursor: pointer;
- text-align: right;
-}
-#jump_to, #jump_wrapper {
- position: fixed;
- right: 0; top: 0;
- padding: 5px 10px;
-}
- #jump_wrapper {
- padding: 0;
- display: none;
- }
- #jump_to:hover #jump_wrapper {
- display: block;
- }
- #jump_page {
- padding: 5px 0 3px;
- margin: 0 0 25px 25px;
- }
- #jump_page .source {
- display: block;
- padding: 5px 10px;
- text-decoration: none;
- border-top: 1px solid #eee;
- }
- #jump_page .source:hover {
- background: #f5f5ff;
- }
- #jump_page .source:first-child {
- }
-table td {
- border: 0;
- outline: 0;
-}
- td.docs, th.docs {
- max-width: 450px;
- min-width: 450px;
- min-height: 5px;
- padding: 10px 25px 1px 50px;
- overflow-x: hidden;
- vertical-align: top;
- text-align: left;
- }
- .docs pre {
- margin: 15px 0 15px;
- padding-left: 15px;
- }
- .docs p tt, .docs p code {
- background: #f8f8ff;
- border: 1px solid #dedede;
- font-size: 12px;
- padding: 0 0.2em;
- }
- .pilwrap {
- position: relative;
- }
- .pilcrow {
- font: 12px Arial;
- text-decoration: none;
- color: #454545;
- position: absolute;
- top: 3px; left: -20px;
- padding: 1px 2px;
- opacity: 0;
- -webkit-transition: opacity 0.2s linear;
- }
- td.docs:hover .pilcrow {
- opacity: 1;
- }
- td.code, th.code {
- padding: 14px 15px 16px 25px;
- width: 100%;
- vertical-align: top;
- background: #f5f5ff;
- border-left: 1px solid #e5e5ee;
- }
- pre, tt, code {
- font-size: 12px; line-height: 18px;
- font-family: Menlo, Monaco, Consolas, "Lucida Console", monospace;
- margin: 0; padding: 0;
- }
-
-
-/*---------------------- Syntax Highlighting -----------------------------*/
-td.linenos { background-color: #f0f0f0; padding-right: 10px; }
-span.lineno { background-color: #f0f0f0; padding: 0 5px 0 5px; }
-body .hll { background-color: #ffffcc }
-body .c { color: #408080; font-style: italic } /* Comment */
-body .err { border: 1px solid #FF0000 } /* Error */
-body .k { color: #954121 } /* Keyword */
-body .o { color: #666666 } /* Operator */
-body .cm { color: #408080; font-style: italic } /* Comment.Multiline */
-body .cp { color: #BC7A00 } /* Comment.Preproc */
-body .c1 { color: #408080; font-style: italic } /* Comment.Single */
-body .cs { color: #408080; font-style: italic } /* Comment.Special */
-body .gd { color: #A00000 } /* Generic.Deleted */
-body .ge { font-style: italic } /* Generic.Emph */
-body .gr { color: #FF0000 } /* Generic.Error */
-body .gh { color: #000080; font-weight: bold } /* Generic.Heading */
-body .gi { color: #00A000 } /* Generic.Inserted */
-body .go { color: #808080 } /* Generic.Output */
-body .gp { color: #000080; font-weight: bold } /* Generic.Prompt */
-body .gs { font-weight: bold } /* Generic.Strong */
-body .gu { color: #800080; font-weight: bold } /* Generic.Subheading */
-body .gt { color: #0040D0 } /* Generic.Traceback */
-body .kc { color: #954121 } /* Keyword.Constant */
-body .kd { color: #954121; font-weight: bold } /* Keyword.Declaration */
-body .kn { color: #954121; font-weight: bold } /* Keyword.Namespace */
-body .kp { color: #954121 } /* Keyword.Pseudo */
-body .kr { color: #954121; font-weight: bold } /* Keyword.Reserved */
-body .kt { color: #B00040 } /* Keyword.Type */
-body .m { color: #666666 } /* Literal.Number */
-body .s { color: #219161 } /* Literal.String */
-body .na { color: #7D9029 } /* Name.Attribute */
-body .nb { color: #954121 } /* Name.Builtin */
-body .nc { color: #0000FF; font-weight: bold } /* Name.Class */
-body .no { color: #880000 } /* Name.Constant */
-body .nd { color: #AA22FF } /* Name.Decorator */
-body .ni { color: #999999; font-weight: bold } /* Name.Entity */
-body .ne { color: #D2413A; font-weight: bold } /* Name.Exception */
-body .nf { color: #0000FF } /* Name.Function */
-body .nl { color: #A0A000 } /* Name.Label */
-body .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */
-body .nt { color: #954121; font-weight: bold } /* Name.Tag */
-body .nv { color: #19469D } /* Name.Variable */
-body .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */
-body .w { color: #bbbbbb } /* Text.Whitespace */
-body .mf { color: #666666 } /* Literal.Number.Float */
-body .mh { color: #666666 } /* Literal.Number.Hex */
-body .mi { color: #666666 } /* Literal.Number.Integer */
-body .mo { color: #666666 } /* Literal.Number.Oct */
-body .sb { color: #219161 } /* Literal.String.Backtick */
-body .sc { color: #219161 } /* Literal.String.Char */
-body .sd { color: #219161; font-style: italic } /* Literal.String.Doc */
-body .s2 { color: #219161 } /* Literal.String.Double */
-body .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */
-body .sh { color: #219161 } /* Literal.String.Heredoc */
-body .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */
-body .sx { color: #954121 } /* Literal.String.Other */
-body .sr { color: #BB6688 } /* Literal.String.Regex */
-body .s1 { color: #219161 } /* Literal.String.Single */
-body .ss { color: #19469D } /* Literal.String.Symbol */
-body .bp { color: #954121 } /* Name.Builtin.Pseudo */
-body .vc { color: #19469D } /* Name.Variable.Class */
-body .vg { color: #19469D } /* Name.Variable.Global */
-body .vi { color: #19469D } /* Name.Variable.Instance */
-body .il { color: #666666 } /* Literal.Number.Integer.Long */
diff --git a/in-a-box/beaker-distros b/in-a-box/beaker-distros
deleted file mode 100644
index e2dd6d4..0000000
--- a/in-a-box/beaker-distros
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/bin/sh
-# Distros need to be imported into Beaker before we can provision them.
-
-echo "This script will import distros into Beaker."
-echo "The distros will not be mirrored locally."
-echo "The following distros will be imported:"
-echo " CentOS-5 x86_64"
-echo " CentOS-5 i386"
-echo " CentOS-6 x86_64"
-echo " CentOS-6 i386"
-echo " CentOS-7 x86_64"
-echo " Fedora-20 x86_64"
-echo " Fedora-20 i386"
-echo " Fedora-21 x86_64"
-echo " Fedora-21 i386"
-echo -n "Do you want to proceed? (y/n) "
-read answer
-if [ "$answer" != "y" -a $answer != "Y" ]; then
- exit 1
-fi
-
-beaker-import http://mirror.centos.org/centos/5/os/x86_64/
-beaker-import http://mirror.centos.org/centos/5/os/i386/
-beaker-import http://mirror.centos.org/centos/6/os/x86_64/
-beaker-import http://mirror.centos.org/centos/6/os/i386/
-beaker-import http://mirror.centos.org/centos/7/os/x86_64/
-beaker-import http://download.fedoraproject.org/pub/fedora/linux/releases/20/Fedora/x86_64/os
-beaker-import http://download.fedoraproject.org/pub/fedora/linux/releases/20/Fedora/i386/os
-beaker-import --family=Fedora http://download.fedoraproject.org/pub/fedora/linux/releases/21/Server/x86_64/os
-beaker-import --family=Fedora http://download.fedoraproject.org/pub/fedora/linux/releases/21/Server/i386/os
-
-# This command will fetch the Beaker harness RPMs for all the distros which we
-# have just imported. The harness must be mirrored locally on the Beaker server
-# in order to run scheduled jobs.
-beaker-repo-update
-
-# And we're done!
-echo "All Done!"
diff --git a/in-a-box/beaker-setup b/in-a-box/beaker-setup
deleted file mode 100644
index 7295c53..0000000
--- a/in-a-box/beaker-setup
+++ /dev/null
@@ -1,108 +0,0 @@
-#!/bin/sh
-# This script will get a basic Beaker installation up and running.
-
-# These are the tasks which we will fetch and upload to Beaker below.
-rpms="
- https://beaker-project.org/tasks/beaker-distribution-install-1.12-2.noarch.rpm
- https://beaker-project.org/tasks/beaker-distribution-inventory-1.2-4.noarch.rpm
- https://beaker-project.org/tasks/beaker-distribution-reservesys-3.4-5.noarch.rpm
- https://beaker-project.org/tasks/beaker-distribution-updateDistro-1.2-1.noarch.rpm
- https://beaker-project.org/tasks/distribution-distribution-command-1.1-4.noarch.rpm
- https://beaker-project.org/tasks/distribution-distribution-utils-dummy-1.0-3.noarch.rpm
- https://beaker-project.org/tasks/distribution-distribution-virt-install-4.0-86.noarch.rpm
- https://beaker-project.org/tasks/distribution-distribution-virt-start-2.0-1.noarch.rpm
- https://beaker-project.org/tasks/rh-tests-kernel-distribution-ltp-nfs-1.0-0.noarch.rpm
-"
-
-# We need to collect a few details from the user.
-echo "This script will do the following"
-echo " - backup /etc/my.cnf and replace it with new defaults."
-echo " - create the beaker DB, DB user and initialize the DB."
-echo " - Add lab controller account for this machine."
-echo " - Add some standard tasks to the scheduler"
-echo " (see https://beaker-project.org/docs/user-guide/beaker-provided-tasks.html)"
-echo -n "Do you want to proceed? (y/n) "
-read answer
-if [ "$answer" != "y" -a $answer != "Y" ]; then
- exit 1
-fi
-
-echo -n "Please enter a login name for the Beaker admin account: "
-read admin
-echo -n "Please enter an email address for $admin: "
-read email
-password="dummy"
-stty -echo
-trap "stty echo; exit" INT TERM EXIT
-while [ "$password" != "$password_again" ]; do
- echo -n "Please enter a passowrd for $admin: "
- read password
- echo
- echo -n "Please enter the password again: "
- read password_again
- echo
- if [ "$password" != "$password_again" ]; then
- echo "Passwords don't match, try again"
- echo
- fi
-done
-stty echo
-trap - INT TERM EXIT
-
-# Let's apply some useful settings to the MySQL server.
-cp /etc/my.cnf /etc/my.cnf-orig
-cat /etc/my.cnf-orig | awk '
- {print $1};
- /\[mysqld\]/ {
- print "default-storage-engine=INNODB";
- print "max_allowed_packet=50M";
- print "character-set-server=utf8";
- }' > /etc/my.cnf
-service mysqld restart
-
-# By default, Beaker connects to the local MySQL server using database `beaker`
-# with username `beaker` and password `beaker`. If you'd like to change these,
-# be sure to update the `sqlalchemy.dburi` setting in `/etc/beaker/server.cfg`
-# accordingly.
-echo "CREATE DATABASE beaker;" | mysql
-echo "GRANT ALL ON beaker.* TO 'beaker'@'localhost' IDENTIFIED BY 'beaker';" | mysql
-
-# The `beaker-init` program will populate a fresh database. Here we pass in the
-# admin user's details which we collected above.
-su -s /bin/sh apache -c "beaker-init -u \"$admin\" -p \"$password\" -e \"$email\""
-
-# Now we can log in to Beaker using our admin credentials and do a few things.
-# Normally these steps would be done using a web browser.
-tmpdir=$(mktemp -d)
-trap "popd; rm -rf $tmpdir; exit" INT TERM EXIT
-pushd $tmpdir
-curl -c tmpcookie -d user_name=$admin -d password=$password -d login=1 http://localhost/bkr/login || exit 1
-# Add ourselves as a lab controller.
-curl -b tmpcookie -d fqdn=$(hostname -f) -d lusername=host/localhost.localdomain -d lpassword=password -d email=root@localhost.localdomain -d Save=1 http://localhost/bkr/labcontrollers/save || exit 1
-# Fetch and upload some useful task RPMs.
-wget $rpms
-for task in *.rpm; do
- curl -b tmpcookie --form task_rpm=@$task http://localhost/bkr/tasks/save || exit 1
-done
-popd
-rm -rf $tmpdir
-trap - INT TERM EXIT
-
-# The beaker-proxy, beaker-watchdog, and beaker-provision daemons run on the lab controller.
-chkconfig beaker-proxy on
-service beaker-proxy start
-chkconfig beaker-watchdog on
-service beaker-watchdog start
-chkconfig beaker-provision on
-service beaker-provision start
-# The beaker-transfer daemon is not needed when the lab controller and the
-# scheduler are the same machine.
-#chkconfig beaker-transfer on
-#service beaker-transfer start
-
-# Finally, we can start up the beakerd scheduler daemon.
-chkconfig beakerd on
-service beakerd start
-
-# And we're done!
-echo "All Done!"
diff --git a/in-a-box/beaker-virt b/in-a-box/beaker-virt
deleted file mode 100644
index 2e102b2..0000000
--- a/in-a-box/beaker-virt
+++ /dev/null
@@ -1,198 +0,0 @@
-#!/bin/sh
-# This script creates some KVM guests using libvirt, and then adds them to
-# Beaker as test systems.
-
-# These are the settings for the systems which we create below.
-systems="
- virt-10;52:54:00:22:24:a4;192.168.122.10
- virt-11;52:54:00:22:24:a5;192.168.122.11
- virt-12;52:54:00:22:24:a6;192.168.122.12
-"
-
-# We need to collect a few details from the user again.
-echo "This script will create three virtual systems."
-echo -n "Do you want to proceed? (y/n) "
-read answer
-if [ "$answer" != "y" -a $answer != "Y" ]; then
- exit 1
-fi
-
-echo -n "Please enter the admin login: "
-read admin
-
-echo -n "Please enter the password for $admin: "
-stty -echo
-trap "stty echo; exit" INT TERM EXIT
-read password
-stty echo
-
-# We need libvirtd to listen over TCP on the loopback interface; that is how
-# Beaker will communicate with it, in order to reboot the guest systems. For
-# production environments it is possible to use a more secure configuration,
-# such as over SSH using key authentication.
-sed -ie 's/^#LIBVIRTD_ARGS=.*/LIBVIRTD_ARGS="--listen"/' /etc/sysconfig/libvirtd
-sed -ie '
- s/^#listen_tls = 0/listen_tls = 0/;
- s/^#listen_tcp = 1/listen_tcp = 1/;
- s/^#listen_addr.*/listen_addr = "127.0.0.1"/i;
- s/^#auth_tcp = "sasl"/auth_tcp = "none"/' /etc/libvirt/libvirtd.conf
-service libvirtd restart
-
-# Replace the default libvirt network with one that supports PXE.
-function gen_qemu_network()
-{
-virsh net-destroy default
-( cat <<__EOF__
-<network>
- <name>default</name>
- <bridge name="virbr1" />
- <mac address='52:54:00:BB:C:19'/>
- <forward/>
- <ip address="192.168.122.1" netmask="255.255.255.0">
- <tftp root="/var/lib/tftpboot" />
- <dhcp>
- <range start="192.168.122.100" end="192.168.122.254" />
-__EOF__
-for system in $systems; do
- PIFS=$IFS
- IFS=";"
- set -- $system
- name=$1
- mac=$2
- ip=$3
- IFS=$PIFS
- echo "<host mac='$mac' name='$name' ip='$ip' />"
-done
-cat <<__EOF__
- <bootp file="pxelinux.0" />
- </dhcp>
- </ip>
-</network>
-__EOF__
-) | virsh net-create /dev/stdin
-}
-
-# Define a storage pool.
-## XXX isn't this already defined by default?
-function gen_qemu_pool()
-{
-( cat <<__EOF__
-<pool type='dir'>
- <name>default</name>
- <capacity>34183356416</capacity>
- <allocation>12157771776</allocation>
- <available>22025584640</available>
- <source>
- </source>
- <target>
- <path>/var/lib/libvirt/images</path>
- <permissions>
- <mode>0700</mode>
- <owner>-1</owner>
- <group>-1</group>
- </permissions>
- </target>
-</pool>
-__EOF__
-) | virsh pool-create /dev/stdin
-}
-
-# Create a libvirt volume.
-function gen_qemu_volume()
-{
-local name="$1"
-( cat <<__EOF__
-<volume>
- <name>$name.img</name>
- <key>/var/lib/libvirt/images/$name.img</key>
- <source>
- </source>
- <capacity>8589934592</capacity>
- <allocation>8589950976</allocation>
- <target>
- <path>/var/lib/libvirt/images/$name.img</path>
- <format type='raw'/>
- <permissions>
- <mode>0600</mode>
- <owner>0</owner>
- <group>0</group>
- </permissions>
- </target>
-</volume>
-__EOF__
-) | virsh vol-create default /dev/stdin
-}
-
-# Create a libvirt guest to be added to Beaker.
-function gen_qemu_system()
-{
-local name="$1"
-local mac="$2"
-(cat <<__EOF__
-<domain type='kvm'>
- <name>$name</name>
- <memory>1048576</memory>
- <currentMemory>1048576</currentMemory>
- <vcpu>1</vcpu>
- <os>
- <type arch='x86_64' machine='rhel6.1.0'>hvm</type>
- <boot dev='network'/>
- <boot dev='hd'/>
- <bootmenu enable='no'/>
- </os>
- <clock offset='utc'/>
- <devices>
- <disk type='file' device='disk'>
- <driver name='qemu' type='raw' cache='none' io='threads'/>
- <source file='/var/lib/libvirt/images/$name.img'/>
- <target dev='vda' bus='virtio'/>
- </disk>
- <interface type='network'>
- <mac address='$mac'/>
- <source network='default'/>
- <model type='virtio'/>
- </interface>
- <memballoon model='virtio'/>
- <graphics type='vnc' port='-1' autoport='yes' keymap='en-us'/>
- </devices>
-</domain>
-__EOF__
-) | virsh define /dev/stdin
-}
-
-# The lab controller for each system will be ourselves.
-hostname=$(hostname -f)
-
-gen_qemu_network
-gen_qemu_pool
-
-# Create the guests in libvirt, and record them in a CSV file which we will
-# upload to Beaker.
-tmpdir=$(mktemp -d)
-trap "rm -rf $tmpdir; exit" INT TERM EXIT
-echo "csv_type,fqdn,shared,arch,lab_controller,owner,secret,status,type" >$tmpdir/01-system.csv
-echo "csv_type,fqdn,power_address,power_id,power_type" >$tmpdir/02-power.csv
-for system in $systems; do
- PIFS=$IFS
- IFS=";"
- set -- $system
- name=$1
- mac=$2
- ip=$3
- IFS=$PIFS
- echo "system,$name,True,\"x86_64,i386\",$hostname,$admin,False,Automated,Machine" >>$tmpdir/01-system.csv
- echo "power,$name,qemu+tcp:localhost,$name,virsh" >>$tmpdir/02-power.csv
- echo -e "$ip\t$name" >> /etc/hosts
- gen_qemu_volume $name
- gen_qemu_system $name $mac
-done
-# Log in to Beaker and upload the CSV files we created.
-curl -c $tmpdir/tmpcookie -d user_name=$admin -d password=$password -d login=1 http://localhost/bkr/login || exit 1
-for csv in $tmpdir/*.csv; do
- curl -b $tmpdir/tmpcookie --form csv_file=@$csv http://localhost/bkr/csv/action_import
-done
-rm -rf $tmpdir
-trap - INT TERM EXIT
-
-# And we're done!
-echo "All Done!"
diff --git a/in-a-box/beaker.ks b/in-a-box/beaker.ks
deleted file mode 100644
index f6cd54f..0000000
--- a/in-a-box/beaker.ks
+++ /dev/null
@@ -1,89 +0,0 @@
-
-# Beaker is developed and tested on Red Hat Enterprise Linux 6, but any
-# compatible distro should work as well.
-url --url=http://mirror.centos.org/centos/6/os/x86_64/
-repo --name=install --baseurl=http://mirror.centos.org/centos/6/os/x86_64/
-repo --name=updates --baseurl=http://mirror.centos.org/centos/6/updates/x86_64/
-repo --name=extras --baseurl=http://mirror.centos.org/centos/6/extras/x86_64/
-repo --name=cr --baseurl=http://mirror.centos.org/centos/6/cr/x86_64/
-repo --name=beaker-server --baseurl=http://beaker-project.org/yum/server/RedHatEnterpriseLinux6/
-
-# If you're feeling adventurous, you could try Fedora instead. Bug reports are
-# welcome.
-#url --url=http://download.fedoraproject.org/pub/fedora/linux/releases/16/Fedora/x86_64/os/
-#repo --name=updates --baseurl=http://download.fedoraproject.org/pub/fedora/linux/updates/16/x86_64/
-#repo --name=beaker-server --baseurl=http://beaker-project.org/yum/server/Fedora16/
-
-# The usual installation stuff. Beaker has no particular requirements here.
-auth --useshadow --enablemd5
-firewall --disable
-firstboot --disable
-clearpart --all --initlabel
-part / --fstype=ext4 --size=2000 --grow
-part /boot --fstype=ext4 --size=500
-part swap --recommended
-bootloader --location=mbr
-keyboard us
-lang en_US
-timezone America/New_York
-install
-reboot
-
-# The root password is `beaker`. You may want to change this.
-rootpw --iscrypted $1$mF86/UHC$0siTuCcbOzXX5nOSdcsPG.
-
-# For now, the Beaker server does not support running with SELinux enabled.
-# Patches welcome.
-selinux --disabled
-
-# These are the basic requirements for running a Beaker server and lab.
-%packages
-beaker-server
-beaker-lab-controller
-mysql-server
-MySQL-python
-autofs
-mod_ssl
-tftp-server
-
-# We will create some KVM guests to add to Beaker.
-libvirt
-virt-manager
-kvm
-qemu-img
-
-# A few extra packages for convenience.
-python-setuptools
-python-setuptools-devel
-python-devel
-xorg-x11-xauth
-
-%post
-set -x -v
-exec 1>/root/ks-post.log 2>&1
-
-# Turn on some services which are needed.
-chkconfig mysqld on
-chkconfig httpd on
-chkconfig xinetd on
-chkconfig tftp on
-
-# The real work of setting up a Beaker environment is done in these scripts.
-wget -O /usr/local/sbin/beaker-setup http://beaker-project.org/in-a-box/beaker-setup
-chmod 755 /usr/local/sbin/beaker-setup
-wget -O /usr/local/sbin/beaker-distros http://beaker-project.org/in-a-box/beaker-distros
-chmod 755 /usr/local/sbin/beaker-distros
-wget -O /usr/local/sbin/beaker-virt http://beaker-project.org/in-a-box/beaker-virt
-chmod 755 /usr/local/sbin/beaker-virt
-cat <<EOF >>/etc/motd
-Welcome to Beaker!
-
-You need to configure a few things before you can run any jobs.
-
-/usr/local/sbin/beaker-setup
- This will intitialize the beaker DB and setup admin account
-/usr/local/sbin/beaker-distros
- This will import some common distros for use
-/usr/local/sbin/beaker-virt
- This will setup some virt hosts on this box for use
-EOF
diff --git a/in-a-box/index.html b/in-a-box/index.html
deleted file mode 100644
index d14b039..0000000
--- a/in-a-box/index.html
+++ /dev/null
@@ -1,48 +0,0 @@
-<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
-<head>
- <title>Beaker in a box</title>
- <meta charset="utf-8" />
- <meta name="viewport" content="width=device-width" />
- <!--[if lt IE 9]>
- <script src="//html5shim.googlecode.com/svn/trunk/html5.js"></script>
- <![endif]-->
- <link href="../style.css" rel="stylesheet" type="text/css"/>
-</head>
-<body>
-<div class="header">
- <div class="body_element">
- <div class="title">
- <a href="../"><img src="../images/logo.png" alt="Beaker" width="110" height="40" /></a>
- </div>
- <nav class="menu">
- <form class="search" method="get" action="../search.html">
- <input type="search" name="q" placeholder="search" />
- </form>
- <a href="../docs/">docs</a>
- <a href="../dev/">develop</a>
- <a href="../download.html">download</a>
- </nav>
- </div>
-</div>
-<div class="main_content">
- <div class="body_element">
- <h1>Beaker in a box</h1>
- <p>This kickstart and associated scripts can be used to install and
- configure a complete working Beaker environment, including three virtual
- guests to act as test systems. You will need a spare system capable of KVM
- virtualization with at least 4GB of RAM.</p>
- <pre>http://beaker-project.org/in-a-box/beaker.ks</pre>
- <p>You can also walk through the kickstarts and scripts online, with
- side-by-side documentation:</p>
- <ul>
- <li><a href="beaker.ks.html">beaker.ks</a></li>
- <li><a href="beaker-setup.html">beaker-setup</a></li>
- <li><a href="beaker-distros.html">beaker-distros</a></li>
- <li><a href="beaker-virt.html">beaker-virt</a></li>
- </ul>
- </div>
-</div>
-</body>
-<!-- vim: set sw=2 : -->
-</html>
diff --git a/shocco.sh b/shocco.sh
deleted file mode 100755
index d23fc6c..0000000
--- a/shocco.sh
+++ /dev/null
@@ -1,466 +0,0 @@
-#!/bin/sh
-# **shocco** is a quick-and-dirty, literate-programming-style documentation
-# generator written for and in __POSIX shell__. It borrows liberally from
-# [Docco][do], the original Q&D literate-programming-style doc generator.
-#
-# `shocco(1)` reads shell scripts and produces annotated source documentation
-# in HTML format. Comments are formatted with Markdown and presented
-# alongside syntax highlighted code so as to give an annotation effect. This
-# page is the result of running `shocco` against [its own source file][sh].
-#
-# shocco is built with `make(1)` and installs under `/usr/local` by default:
-#
-# git clone git://github.com/rtomayko/shocco.git
-# cd shocco
-# make
-# sudo make install
-# # or just copy 'shocco' wherever you need it
-#
-# Once installed, the `shocco` program can be used to generate documentation
-# for a shell script:
-#
-# shocco shocco.sh
-#
-# The generated HTML is written to `stdout`.
-#
-# [do]: http://jashkenas.github.com/docco/
-# [sh]: https://github.com/rtomayko/shocco/blob/master/shocco.sh#commit
-
-# Usage and Prerequisites
-# -----------------------
-
-# The most important line in any shell program.
-set -e
-
-# There's a lot of different ways to do usage messages in shell scripts.
-# This is my favorite: you write the usage message in a comment --
-# typically right after the shebang line -- *BUT*, use a special comment prefix
-# like `#/` so that its easy to pull these lines out.
-#
-# This also illustrates one of shocco's corner features. Only comment lines
-# padded with a space are considered documentation. A `#` followed by any
-# other character is considered code.
-#
-#/ Usage: shocco [-t <title>] [<source>]
-#/ Create literate-programming-style documentation for shell scripts.
-#/
-#/ The shocco program reads a shell script from <source> and writes
-#/ generated documentation in HTML format to stdout. When <source> is
-#/ '-' or not specified, shocco reads from stdin.
-
-# This is the second part of the usage message technique: `grep` yourself
-# for the usage message comment prefix and then cut off the first few
-# characters so that everything lines up.
-expr -- "$*" : ".*--help" >/dev/null && {
- grep '^#/' <"$0" | cut -c4-
- exit 0
-}
-
-# A custom title may be specified with the `-t` option. We use the filename
-# as the title if none is given.
-test "$1" = '-t' && {
- title="$2"
- shift;shift
-}
-
-# Next argument should be the `<source>` file. Grab it, and use its basename
-# as the title if none was given with the `-t` option.
-file="$1"
-: ${title:=$(basename "$file")}
-
-# These are replaced with the full paths to real utilities by the
-# configure/make system.
-MARKDOWN='/usr/bin/rdiscount'
-PYGMENTIZE='/usr/bin/pygmentize'
-
-# We're going to need a `markdown` command to run comments through. This can
-# be [Gruber's `Markdown.pl`][md] (included in the shocco distribution) or
-# Discount's super fast `markdown(1)` in C. Try to figure out if either are
-# available and then bail if we can't find anything.
-#
-# [md]: http://daringfireball.net/projects/markdown/
-# [ds]: http://www.pell.portland.or.us/~orc/Code/discount/
-command -v "$MARKDOWN" >/dev/null || {
- if command -v Markdown.pl >/dev/null
- then alias markdown='Markdown.pl'
- elif test -f "$(dirname $0)/Markdown.pl"
- then alias markdown="perl $(dirname $0)/Markdown.pl"
- else echo "$(basename $0): markdown command not found." 1>&2
- exit 1
- fi
-}
-
-# Check that [Pygments][py] is installed for syntax highlighting.
-#
-# This is a fairly hefty prerequisite. Eventually, I'd like to fallback
-# on a simple non-highlighting preformatter when Pygments isn't available. For
-# now, just bail out if we can't find the `pygmentize` program.
-#
-# [py]: http://pygments.org/
-command -v "$PYGMENTIZE" >/dev/null || {
- echo "$(basename $0): pygmentize command not found." 1>&2
- exit 1
-}
-
-# Work and Cleanup
-# ----------------
-
-# Make sure we have a `TMPDIR` set. The `:=` parameter expansion assigns
-# the value if `TMPDIR` is unset or null.
-: ${TMPDIR:=/tmp}
-
-# Create a temporary directory for doing work. Use `mktemp(1)` if
-# available; but, since `mktemp(1)` is not POSIX specified, fallback on naive
-# (and insecure) temp dir generation using the program's basename and pid.
-: ${WORK:=$(
- if command -v mktemp 1>/dev/null 2>&1
- then
- mktemp -d "$TMPDIR/$(basename $0).XXXXXXXXXX"
- else
- dir="$TMPDIR/$(basename $0).$$"
- mkdir "$dir"
- echo "$dir"
- fi
- )}
-
-# We want to be absolutely sure we're not going to do something stupid like
-# use `.` or `/` as a work dir. Better safe than sorry.
-test -z "$WORK" -o "$WORK" = '/' && {
- echo "$(basename $0): could not create a temp work dir."
- exit 1
-}
-
-# We're about to create a ton of shit under our `$WORK` directory. Register
-# an `EXIT` trap that cleans everything up. This guarantees we don't leave
-# anything hanging around unless we're killed with a `SIGKILL`.
-trap "rm -rf $WORK" 0
-
-# Preformatting
-# -------------
-#
-# Start out by applying some light preformatting to the `<source>` file to
-# make the code and doc formatting phases a bit easier. The result of this
-# pipeline is written to a temp file under the `$WORK` directory so we can
-# take a few passes over it.
-
-# Get a pipeline going with the `<source>` data. We write a single blank
-# line at the end of the file to make sure we have an equal number of code/comment
-# pairs.
-(cat "$file" && printf "\n\n# \n\n") |
-
-# We want the shebang line and any code preceding the first comment to
-# appear as the first code block. This inverts the normal flow of things.
-# Usually, we have comment text followed by code; in this case, we have
-# code followed by comment text.
-#
-# Read the first code and docs headers and flip them so the first docs block
-# comes before the first code block.
-(
- lineno=0
- codebuf=;codehead=
- docsbuf=;docshead=
- while read -r line
- do
- # Issue a warning if the first line of the script is not a shebang
- # line. This can screw things up and wreck our attempt at
- # flip-flopping the two headings.
- lineno=$(( $lineno + 1 ))
- test $lineno = 1 && ! expr "$line" : "#!.*" >/dev/null &&
- echo "$(basename $0): ${file}:1 [warn] shebang! line missing." 1>&2
-
- # Accumulate comment lines into `$docsbuf` and code lines into
- # `$codebuf`. Only lines matching `/#(?: |$)/` are considered doc
- # lines.
- if expr "$line" : '# ' >/dev/null || test "$line" = "#"
- then docsbuf="$docsbuf$line
-"
- else codebuf="$codebuf$line
-"
- fi
-
- # If we have stuff in both `$docsbuf` and `$codebuf`, it means
- # we're at some kind of boundary. If `$codehead` isn't set, we're at
- # the first comment/doc line, so store the buffer to `$codehead` and
- # keep going. If `$codehead` *is* set, we've crossed into another code
- # block and are ready to output both blocks and then straight pipe
- # everything by `exec`'ing `cat`.
- if test -n "$docsbuf" -a -n "$codebuf"
- then
- if test -n "$codehead"
- then docshead="$docsbuf"
- docsbuf=""
- printf "%s" "$docshead"
- printf "%s" "$codehead"
- echo "$line"
- exec cat
- else codehead="$codebuf"
- codebuf=
- fi
- fi
- done
-
- # We made it to the end of the file without a single comment line, or
- # there was only a single comment block ending the file. Output our
- # docsbuf or a fake comment and then the codebuf or codehead.
- echo "${docsbuf:-#}"
- echo "${codebuf:-"$codehead"}"
-) |
-
-# Remove comment leader text from all comment lines. Then prefix all
-# comment lines with "DOCS" and interpreted / code lines with "CODE".
-# The stream text might look like this after moving through the `sed`
-# filters:
-#
-# CODE #!/bin/sh
-# CODE #/ Usage: shocco <file>
-# DOCS Docco for and in POSIX shell.
-# CODE
-# CODE PATH="/bin:/usr/bin"
-# CODE
-# DOCS Start by numbering all lines in the input file...
-# ...
-#
-# Once we pass through `sed`, save this off in our work directory so
-# we can take a few passes over it.
-sed -n '
- s/^/:/
- s/^:[ ]\{0,\}# /DOCS /p
- s/^:[ ]\{0,\}#$/DOCS /p
- s/^:/CODE /p
-' > "$WORK/raw"
-
-# Now that we've read and formatted our input file for further parsing,
-# change into the work directory. The program will finish up in there.
-cd "$WORK"
-
-# First Pass: Comment Formatting
-# ------------------------------
-
-# Start a pipeline going on our preformatted input.
-# Replace all CODE lines with entirely blank lines. We're not interested
-# in code right now, other than knowing where comments end and code begins
-# and code begins and comments end.
-sed 's/^CODE.*//' < raw |
-
-# Now squeeze multiple blank lines into a single blank line.
-#
-# __TODO:__ `cat -s` is not POSIX and doesn't squeeze lines on BSD. Use
-# the sed line squeezing code mentioned in the POSIX `cat(1)` manual page
-# instead.
-cat -s |
-
-# At this point in the pipeline, our stream text looks something like this:
-#
-# DOCS Now that we've read and formatted ...
-# DOCS change into the work directory. The rest ...
-# DOCS in there.
-#
-# DOCS First Pass: Comment Formatting
-# DOCS ------------------------------
-#
-# Blank lines represent code segments. We want to replace all blank lines
-# with a dividing marker and remove the "DOCS" prefix from docs lines.
-sed '
- s/^$/##### DIVIDER/
- s/^DOCS //' |
-
-# The current stream text is suitable for input to `markdown(1)`. It takes
-# our doc text with embedded `DIVIDER`s and outputs HTML.
-$MARKDOWN |
-
-# Now this where shit starts to get a little crazy. We use `csplit(1)` to
-# split the HTML into a bunch of individual files. The files are named
-# as `docs0000`, `docs0001`, `docs0002`, ... Each file includes a single
-# doc *section*. These files will sit here while we take a similar pass over
-# the source code.
-(
- csplit -sk \
- -f docs \
- -n 4 \
- - '/<h5>DIVIDER<\/h5>/' '{9999}' \
- 2>/dev/null ||
- true
-)
-
-
-# Second Pass: Code Formatting
-# ----------------------------
-#
-# This is exactly like the first pass but we're focusing on code instead of
-# comments. We use the same basic technique to separate the two and isolate
-# the code blocks.
-
-# Get another pipeline going on our performatted input file.
-# Replace DOCS lines with blank lines.
-sed 's/^DOCS.*//' < raw |
-
-# Squeeze multiple blank lines into a single blank line.
-cat -s |
-
-# Replace blank lines with a `DIVIDER` marker and remove prefix
-# from `CODE` lines.
-sed '
- s/^$/# DIVIDER/
- s/^CODE //' |
-
-# Now pass the code through `pygmentize` for syntax highlighting. We tell it
-# the the input is `sh` and that we want HTML output.
-$PYGMENTIZE -l sh -f html -O encoding=utf8 |
-
-# Post filter the pygments output to remove partial `<pre>` blocks. We add
-# these back in at each section when we build the output document.
-sed '
- s/<div class="highlight"><pre>//
- s/^<\/pre><\/div>//' |
-
-# Again with the `csplit(1)`. Each code section is written to a separate
-# file, this time with a `codeXXX` prefix. There should be the same number
-# of `codeXXX` files as there are `docsXXX` files.
-(
- DIVIDER='/<span class="c"># DIVIDER</span>/'
- csplit -sk \
- -f code \
- -n 4 - \
- "$DIVIDER" '{9999}' \
- 2>/dev/null ||
- true
-)
-
-# At this point, we have separate files for each docs section and separate
-# files for each code section.
-
-# HTML Template
-# -------------
-
-# Create a function for apply the standard [Docco][do] HTML layout, using
-# [jashkenas][ja]'s gorgeous CSS for styles. Wrapping the layout in a function
-# lets us apply it elsewhere simply by piping in a body.
-#
-# [ja]: http://github.com/jashkenas/
-# [do]: http://jashkenas.github.com/docco/
-layout () {
- cat <<HTML
-<!DOCTYPE html>
-<html>
-<head>
- <meta http-eqiv='content-type' content='text/html;charset=utf-8'>
- <title>$1</title>
- <link rel=stylesheet href="../docco.css">
-</head>
-<body>
-<div id=container>
- <div id=background></div>
- <table cellspacing=0 cellpadding=0>
- <thead>
- <tr>
- <th class=docs><h1>$1</h1></th>
- <th class=code></th>
- </tr>
- </thead>
- <tbody>
- <tr><td class='docs'>$(cat)</td><td class='code'></td></tr>
- </tbody>
- </table>
-</div>
-</body>
-</html>
-HTML
-}
-
-# Recombining
-# -----------
-
-# Alright, we have separate files for each docs section and separate
-# files for each code section. We've defined a function to wrap the
-# results in the standard layout. All that's left to do now is put
-# everything back together.
-
-# Before starting the pipeline, decide the order in which to present the
-# files. If `code0000` is empty, it should appear first so the remaining
-# files are presented `docs0000`, `code0001`, `docs0001`, and so on. If
-# `code0000` is not empty, `docs0000` should appear first so the files
-# are presented `docs0000`, `code0000`, `docs0001`, `code0001` and so on.
-#
-# Ultimately, this means that if `code0000` is empty, the `-r` option
-# should not be provided with the final `-k` option group to `sort`(1) in
-# the pipeline below.
-if stat -c"%s" /dev/null >/dev/null 2>/dev/null ; then
- # GNU stat
- [ "$(stat -c"%s" "code0000")" = 0 ] && sortopt="" || sortopt="r"
-else
- # BSD stat
- [ "$(stat -f"%z" "code0000")" = 0 ] && sortopt="" || sortopt="r"
-fi
-
-# Start the pipeline with a simple list of split out temp filename. One file
-# per line.
-ls -1 docs[0-9]* code[0-9]* 2>/dev/null |
-
-# Now sort the list of files by the *number* first and then by the type. The
-# list will look something like this when `sort(1)` is done with it:
-#
-# docs0000
-# code0000
-# docs0001
-# code0001
-# docs0002
-# code0002
-# ...
-#
-sort -n -k"1.5" -k"1.1$sortopt" |
-
-# And if we pass those files to `cat(1)` in that order, it concatenates them
-# in exactly the way we need. `xargs(1)` reads from `stdin` and passes each
-# line of input as a separate argument to the program given.
-#
-# We could also have written this as:
-#
-# cat $(ls -1 docs* code* | sort -n -k1.5 -k1.1r)
-#
-# I like to keep things to a simple flat pipeline when possible, hence the
-# `xargs` approach.
-xargs cat |
-
-
-# Run a quick substitution on the embedded dividers to turn them into table
-# rows and cells. This also wraps each code block in a `<div class=highlight>`
-# so that the CSS kicks in properly.
-{
- DOCSDIVIDER='<h5>DIVIDER</h5>'
- DOCSREPLACE='</pre></div></td></tr><tr><td class=docs>'
- CODEDIVIDER='<span class="c"># DIVIDER</span>'
- CODEREPLACE='</td><td class=code><div class=highlight><pre>'
- sed "
- s@${DOCSDIVIDER}@${DOCSREPLACE}@
- s@${CODEDIVIDER}@${CODEREPLACE}@
- "
-} |
-
-# Pipe our recombined HTML into the layout and let it write the result to
-# `stdout`.
-layout "$title"
-
-# More
-# ----
-#
-# **shocco** is the third tool in a growing family of quick-and-dirty,
-# literate-programming-style documentation generators:
-#
-# * [Docco][do] - The original. Written in CoffeeScript and generates
-# documentation for CoffeeScript, JavaScript, and Ruby.
-# * [Rocco][ro] - A port of Docco to Ruby.
-#
-# If you like this sort of thing, you may also find interesting Knuth's
-# massive body of work on literate programming:
-#
-# * [Knuth: Literate Programming][kn]
-# * [Literate Programming on Wikipedia][wi]
-#
-# [ro]: http://rtomayko.github.com/rocco/
-# [do]: http://jashkenas.github.com/docco/
-# [kn]: http://www-cs-faculty.stanford.edu/~knuth/lp.html
-# [wi]: http://en.wikipedia.org/wiki/Literate_programming
-
-# Copyright (C) [Ryan Tomayko <tomayko.com/about>](http://tomayko.com/about)<br>
-# This is Free Software distributed under the MIT license.
-: