#!/usr/bin/perl -wT # # EMULAB-COPYRIGHT # Copyright (c) 2006 University of Utah and the Flux Group. # All rights reserved. # use English; use strict; use Getopt::Std; use POSIX qw(setsid); use POSIX qw(strftime); use Errno qw(EDQUOT); use XML::Simple; use Data::Dumper; # # Create a new experiment template. # # Exit codes are important; they tell the web page what has happened so # it can say something useful to the user. Fatal errors are mostly done # with die(), but expected errors use this routine. At some point we will # use the DB to communicate the actual error. # # $status < 0 - Fatal error. Something went wrong we did not expect. # $status = 0 - Everything okay. # $status > 0 - Expected error. User not allowed for some reason. # sub usage() { print(STDERR "Usage: template_swapin [-q] [-w] [-s]\n". " [-S reason] [-L reason] [-a