$ ./mg-hosts manual-task-create ianc@kazak
Borrow, estimating 1 day duration (for the planner):
-$ ./mg-allocate -U 1d marilith-n5
+$ ./mg-allocate -U 1d marilith-n5
Return (not automatic, even with an estimate given):
-$ ./mg-allocate \!marilith-n5
+$ ./mg-allocate ^marilith-n5
Removing machines for servicing/outage
======================================
# ./mg-allocate [-l] [-l] [-l]
#
# <resource-spec> syntax:
-# [!][<type>/]<name>[/<share>] type defaults to 'host'
+# [^][<type>/]<name>[/<share>] type defaults to 'host'
# type=='S' means 'shared-host'
# type=='F' means 'shared-flight'
# share defaults to *
-# "!" prefix means deallocate
+# "^" prefix (or "!") means deallocate
# name=option|option|... means
# any one of those options
# option={flag,flag...} means anything
# be owned by the current task (or perhaps by a task
# named in --steal).
#
-# Not compatible with the !<resource> deallocation
+# Not compatible with the ^<resource> deallocation
# syntax: donation implies deallocation, in a sense.
#
# --steal <task-spec>
sub parse_1res ($) {
my ($res) = @_;
- $res =~ m,^(\!?) (?: ([^/]+)/ )? ([^/]+) (?: /(\d+|\*) )?$,x
+ $res =~ m,^([!^]?) (?: ([^/]+)/ )? ([^/]+) (?: /(\d+|\*) )?$,x
or die "bad resource $res ?";
my $allocate= !$1;
my $restype= defined($2) ? $2 : 'host';
# ./mg-schema-test-database drop [_SUFFIX]
# This will throw away all of the information in the test DB.
#
-# 5. OSSTEST_TASK=iwj@testing ./mg-allocate !a-host
+# 5. OSSTEST_TASK=iwj@testing ./mg-allocate ^a-host
# Hosts that were marked in the main DB as borrowed, are returned by
# mg-schema-test-database to the main DB task that previously owned
# them, but not freed. So you need to explicitly free them.