kvm: pin cns.recipe.symlink
[slapos.git] / software / test-slave-instance-deployment / instance-default.cfg
1 [buildout]
2 parts =
3   publish-connection-informations
4   request-slave-instance
5   check-connection-informations-promise
6 eggs-directory = ${buildout:eggs-directory}
7 develop-eggs-directory = ${buildout:develop-eggs-directory}
8 offline = true
9
10 [directories]
11 recipe = slapos.cookbook:mkdirectory
12 bin = $${buildout:directory}/bin
13 etc = $${buildout:directory}/etc
14 scripts = $${:etc}/run
15 services = $${:etc}/service
16 promises = $${:etc}/promise
17
18 [slap-configuration]
19 recipe = slapos.cookbook:slapconfiguration.serialised
20 computer = $${slap-connection:computer-id}
21 partition = $${slap-connection:partition-id}
22 url = $${slap-connection:server-url}
23 key = $${slap-connection:key-file}
24 cert = $${slap-connection:cert-file}
25
26 [request-test-instance]
27 # Deploy a dummy instance
28 <= slap-connection
29 recipe = slapos.cookbook:request
30 name = Test Root Instance
31 software-url = $${slap-connection:software-release-url}
32 software-type = test
33 return = foo slave-instance-list
34
35 [request-slave-instance]
36 # Deploy a dummy instance
37 <= slap-connection
38 recipe = slapos.cookbook:request
39 name = Test Root Instance - Slave
40 software-url = $${slap-connection:software-release-url}
41 software-type = test
42 slave = true
43 sla = instance_guid
44 sla-instance_guid = $${request-test-instance:instance-guid}
45 return = foo
46
47 [publish-connection-informations]
48 recipe = slapos.cookbook:publish
49 note = test-instance-guid should be equal to XXX, test-instance-state should be equal to started, test-instance-slave-instance-list should be NOT empty, and root-instance-slave-instance-list SHOULD be empty, slave-instance-parameter should NOT be empty.
50 test-instance-guid = $${request-test-instance:instance-guid}
51 test-instance-state = $${request-test-instance:instance-state}
52 test-instance-slave-instance-list = $${request-test-instance:connection-slave-instance-list}
53 root-instance-slave-instance-list = $${slap-configuration:slave-instance-list}
54 slave-instance-parameter = $${request-slave-instance:connection-foo}
55
56 # Create a file containing connection parameters
57 # Then create a promise that will check content of this file
58 [dump-connection-informations]
59 <= publish-connection-informations
60 recipe = slapos.cookbook:jsondump
61 json-output = $${buildout:directory}/connection-parameters.json
62
63 [check-connection-informations-promise]
64 recipe = collective.recipe.template
65 input = ${promise-template:output}
66 output = $${directories:promises}/checkparameters
67 mode = 700