Commit 1fa25734 authored by Jonathon Duerig's avatar Jonathon Duerig

Added a type_relation to rspecv2 along with an example.

parent 2a63abab
......@@ -36,18 +36,29 @@ NodeContents &=
# multiple physical links to connect to the same interface.
element cloud { AnyExtension } &
# Lists services provided by the CM for this node.
element services { ServiceContents } &
# Node type. This includes both hardware and sliver type elements:
HardwareType* &
SliverType*
element sliver_type {
SliverTypeContents &
element disk_image {
DiskImageContents &
attribute default { text }?
}*
}*
AvailableContents =
AnyExtension &
# Indictates current availability
attribute now { xsd:boolean }
DiskImageContents =
AnyExtension &
attribute name { text } &
attribute os { text }? &
attribute version { text }?
LinkContents &=
# Component identifiers
attribute component_id { text } &
......@@ -106,10 +117,19 @@ ExecuteServiceContents &=
# Shell environment allowed
attribute shell { "sh" }
TypeRelationContents &=
AnyExtension &
element hardware_type { HardwareTypeContents }* &
element sliver_type { SliverTypeContents }* &
element disk_image { DiskImageContents }*
RSpecContents &=
attribute type { "advertisement" } &
element external_ref {
ExternalReferenceContents
}* &
element type_relation {
TypeRelationContents
}*
start = RSpec
......@@ -118,12 +118,14 @@ LinkClass = element link_class {
attribute name { text }
}
SliverType = element sliver_type {
SliverType = element sliver_type { SliverTypeContents }
SliverTypeContents =
AnyExtension &
attribute name { text }
}
HardwareType = element hardware_type {
HardwareType = element hardware_type { HardwareTypeContents }
HardwareTypeContents =
AnyExtension &
attribute name { text }
}
<?xml version="1.0" encoding="UTF-8"?>
<rspec xmlns="http://www.protogeni.net/resources/rspec/2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.protogeni.net/resources/rspec/2 http://www.protogeni.net/resources/rspec/2/ad.xsd"
type="advertisement">
<type_relation>
<hardware_type name="pc" />
<hardware_type name="pc600" />
<hardware_type name="pc3000" />
<sliver_type name="raw-pc" />
<disk_image name="RH9-STD" os="linux" version="Redhat-9" />
</type_relation>
<type_relation>
<hardware_type name="pc3000" />
<sliver_type name="raw-pc" />
<disk_image name="FBSD62-STD" os="linux" version="FreeBSD-6.2" />
</type_relation>
<node component_id="urn:publicid:IDN+emulab.net+node+pc175"
component_manager_id="urn:publicid:IDN+emulab.net+authority+cm"
exclusive="true">
<services>
<login authentication="ssh-keys" hostname="pc175.emulab.net" port="22"/>
</services>
<sliver_type name="raw-pc">
<disk_image name="FBSD62-UNSTABLE" os="linux" version="FreeBSD-6.21"
default="true">
</disk_image>
</sliver_type>
<hardware_type name="pc3000" />
<hardware_type name="pc" />
</node>
<node component_id="urn:publicid:IDN+emulab.net+node+pc176"
component_manager_id="urn:publicid:IDN+emulab.net+authority+cm"
exclusive="true">
<services>
<login authentication="ssh-keys" hostname="pc176.emulab.net" port="22"/>
</services>
<sliver_type name="raw-pc" />
<hardware_type name="pc3000" />
<hardware_type name="pc" />
</node>
<node component_id="urn:publicid:IDN+emulab.net+node+pc1"
component_manager_id="urn:publicid:IDN+emulab.net+authority+cm"
exclusive="true">
<services>
<login authentication="ssh-keys" hostname="pc1.emulab.net" port="22"/>
</services>
<sliver_type name="raw-pc" />
<hardware_type name="pc600" />
<hardware_type name="pc" />
</node>
</rspec>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment