1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54
|
# This is a comment
import toto.graph;
##
# Facet
##
facet VM {
installer: iaas;
}
# Components
VM_ec2 {
facets: VM;
children: cluster-node, mysql;
}
VM_openstack {
facets: VM;
children: cluster-node, mysql;
}
cluster-node {
alias: a cluster node;
installer: puppet;
exports: ip, port, optional-property1, optional_property2;
imports: cluster-node.ip (optional), cluster-node.port (optional), mysql.ip, mysql.port;
}
mysql {
alias: a MySQL database;
installer: puppet;
exports: ip, port;
}
##
# Normally, instances are defined in another file...
##
instance of VM_ec2 {
name: VM_;
count: 3;
my-instance-property: whatever;
instance of cluster-node {
name: cluster node; # An in-line comment
}
}
instance of VM_openstack {
name: VM_database;
instance of mysql {
name: mysql;
}
}
|