...
Code Block | ||||
---|---|---|---|---|
| ||||
# PROTOTYPE - development needs to be done first curl -v --silent -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHBkcDphbHBoYTEyMw==' --header 'Environment: TEST' -d '{ "policyClass": "Decision", "policyName": "com.vDNS.MinMax", "policyDescription": "Ensure number of instances within a range", "ecompNameonapName": "PDPD", "ruleProvider": "GUARD_MIN_YAMLMAX", "attributes": { "MATCHING": { "actor": "SO", "recipe": "scaleOut", "targets": ".*", "clname": "ControlLoop-vDNS-6f37f56d-a87d-4b85-b6a9-cc953cf779b3", "min": "1", "max": "5", "guardActiveStart": "00:00:01-05:00", "guardActiveEnd": "00:00:00-05:00" } } }' 'http://pdp:8081/pdp/api/createPolicy' |
Code Block | ||||
---|---|---|---|---|
| ||||
# DRAFT - this needs to be tested first curl -v --silent -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHBkcDphbHBoYTEyMw==' --header 'Environment: TEST' -d '{ "policyClass": "Decision", "policyName": "com.vDNS.Frequency", "policyDescription": "Limit vDNS Scale Up over time period", "ecompNameonapName": "PDPD", "ruleProvider": "GUARD_YAML", "attributes": { "MATCHING": { "actor": "SO", "recipe": "scaleOut", "targets": ".*", "clname": "ControlLoop-vDNS-6f37f56d-a87d-4b85-b6a9-cc953cf779b3", "limit": "1", "timeWindow": "10", "timeUnits": "minute", "guardActiveStart": "00:00:01-05:00", "guardActiveEnd": "00:00:00-05:00" } } }' 'http://pdp:8081/pdp/api/createPolicy' |
...