Updated list of upstream contributions in Blazar
[promise.git] / deprecated / source / schema / openstack.yang
1 module openstack {
2   prefix os;
3
4   import nfv-infrastructure { prefix nfvi; }
5   import access-control-models { prefix acm; }
6   import ietf-yang-types { prefix yang; }
7   import ietf-inet-types { prefix inet; }
8   import complex-types { prefix ct; }
9
10   description
11     "OpenStack controller module";
12
13   revision 2016-01-19 {
14     description "Basic coverage of limited intents needed for Promise";
15   }
16   
17   identity openstack { base nfvi:manager; }
18   identity release { base openstack; }
19   identity distro { base openstack; }
20
21   feature os-system-admin {
22     description "OpenStack system administration capability";
23   }
24   
25   grouping os-credentials {
26     uses acm:access-credentials {
27       refine strategy {
28         default keystone;
29       }
30       refine endpoint {
31         default "http://localhost:5000/v2.0";
32       }
33     }
34     container tenant {
35       leaf id { type string; }
36       leaf name { type string; }
37     }
38   }
39   
40   // OpenStack infrastructure platform (PLACEHOLDER)
41   container platform {
42     uses nfvi:resource-stack;
43     
44     leaf release { type identityref { base release; } }
45     leaf distro  { type identityref { base distro; } }
46     
47     //ct:instance-list services { ct:instance-type OpenStackService; }
48     //ct:instance-list endpoints { ct:instance-type ServiceEndpoint; }
49   }
50
51   // OpenStack system administrator configuration tree
52   container admin {
53     if-feature os-system-admin;
54     container auth {
55       uses os-credentials;
56       leaf token { type yang:uuid; }
57     }
58   }
59
60   rpc authenticate {
61     if-feature os-system-admin;
62     input {
63       uses os-credentials;
64     }
65     output {
66       leaf token { type yang:uuid; }
67     }
68   }
69
70   rpc create-tenant {
71     if-feature os-system-admin;
72     
73   }
74 }