File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change 1313 - vars/osp18_env.yml
1414 tasks :
1515 - block :
16+ # TODO: consider mounting these dirs into the pod
1617 # - name: Include vars from the extra_vars files
1718 # ansible.builtin.include_vars:
1819 # dir: "{{ cifmw_basedir }}/artifacts/parameters"
2728 ansible.builtin.shell :
2829 cmd : |
2930 {{ openstack_cmd }} rating module list
31+ export SERVICE_NAME=test_service_instance
32+ export GROUP_NAME=test_group_instance_uptime_flavor_id
33+ export FIELD_NAME="flavor_id"
34+
35+ {{ openstack_cmd }} rating hashmap group create $GROUP_NAME || true
36+ export GROUP_ID=$({{ openstack_cmd }} rating hashmap group list -f value -c Name -c 'Group ID' | grep $GROUP_NAME| awk '{ print $2}')
37+
38+ {{ openstack_cmd }} rating hashmap service create $SERVICE_NAME || true
39+ export SERVICE_ID=$({{ openstack_cmd }} rating hashmap service list -f value -c Name -c 'Service ID' | grep $SERVICE_NAME | awk '{ print $2 }')
40+
41+ {{ openstack_cmd }} rating hashmap field create $SERVICE_ID $FIELD_NAME || true
42+ export FLAVOR_FIELD_ID=$({{ openstack_cmd }} rating hashmap field list $SERVICE_ID -f value -c Name -c 'Field ID' | grep $FIELD_NAME | awk '{ print $2}')
43+
44+ export FLAVOR_NAME=m1.small
45+ export FLAVOR_ID=$({{ openstack_cmd }} flavor list -f value -c Name -c ID | grep $FLAVOR_NAME | awk '{print $2}')
46+
47+ {{ openstack_cmd }} rating hashmap mapping create 0.01 --field-id $FLAVOR_FIELD_ID --value $FLAVOR_ID -g $GROUP_ID -t flat
You can’t perform that action at this time.
0 commit comments