3 ##Quick Start on the same machine:
5 Tested on Ubuntu 14.04 and OS X El Capitan
8 git clone https://gerrit.opnfv.org/gerrit/domino
9 sudo apt-get install python-pip
10 sudo pip install tosca-parser
11 sudo pip install heat-translator
14 Proceed to the domino folder and run a smoke test that checks APIs
20 If "internal error" message is received, a python library is missing
22 Clean the server side database:
26 Make sure that all the existing domino server and client processes are killed.
28 kill $(pgrep -f "DominoServer.py")
29 kill $(pgrep -f "DominoClient.py")
31 ###Start Domino Server:
32 ./DominoServer.py --log=DEBUG
34 ###Start the first Domino Client:
35 ./DominoClient.py -p 9091 --cliport 9100 --log=DEBUG
37 Note: if --log option is ommitted, the default logging level is Warning messages
39 ###Start the second Domino Client:
40 ./DominoClient.py -p 9092 --cliport 9200 --log=DEBUG
42 ##CLI at the Domino Client:
45 python domino-cli.py <cliport> heartbeat
47 ###Subscribe for policy labels
48 python domino-cli.py <cliport> subscribe -l/--label <policytype>:properties:key:value
51 First checkout the tosca file "./tosca-templates/tosca_helloworld_nfv.yaml" and see how policy types and rules are defined. Then, for the first Domino Client, use subscribe command as:
53 python domino-cli.py 9100 subscribe --label tosca.policies.Placement.Geolocation:properties:region:us-west-1
55 ###Publish default template file under tosca-templates
56 python domino-cli.py <cliport> publish --tosca-file <path_to_toscafile>
59 Run the following command for the second Domino Client:
61 python domino-cli.py 9200 publish --tosca-file ./tosca-templates/tosca_helloworld_nfv.yaml
63 Now, inspect the files generated under ./toscafiles, where the original file as well as parts sent to each Domino Client are shown (each part identified by UDID assigned to that client)
65 ###Query published tosca-templates for each client
66 python domino-cli.py <cliport> list-tuids
69 Run the following command for the second Domino Client:
71 python domino-cli.py 9200 list-tuids
73 ###Change the published template for a specific Template Unique ID (TUID)
74 python domino-cli.py <cliport> publish -t ./tosca-templates/tosca_helloworld_nfv.yaml -k <TUID>
77 Run the following command for the second Domino Client:
79 TUID=$(python domino-cli.py 9200 list-tuids | cut -c3-34)
80 python domino-cli.py 9200 publish -t ./tosca-templates/tosca_helloworld_nfv.yaml -k "$TUID"
83 If accidentally you start DominoClient before DominoServer, don't panic. First start the DominoServer and then input the command on the DominoClient side: