4 echo "Pushing default policies"
6 # Sometimes brmsgw gets an error when trying to retrieve the policies on initial push,
7 # so for the BRMS policies we will do a push, then delete from the pdp group, then push again.
8 # Second push should be successful.
10 curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
11 "pdpGroup": "default",
12 "policyName": "vFirewall",
14 "policyType": "MicroService"
15 }' 'http://pypdp:8480/PyPDPServer/pushPolicy'
19 curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
20 "pdpGroup": "default",
21 "policyName": "vLoadBalancer",
23 "policyType": "MicroService"
24 }' 'http://pypdp:8480/PyPDPServer/pushPolicy'
27 curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
28 "pdpGroup": "default",
29 "policyName": "BRMSParamvLBDemoPolicy",
31 "policyType": "BRMS_Param"
32 }' 'http://pypdp:8480/PyPDPServer/pushPolicy'
36 curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
37 "pdpGroup": "default",
38 "policyName": "BRMSParamvFWDemoPolicy",
40 "policyType": "BRMS_Param"
41 }' 'http://pypdp:8480/PyPDPServer/pushPolicy'
45 curl -X DELETE --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
46 "pdpGroup": "default",
47 "policyComponent": "PDP",
48 "policyName": "com.Config_BRMS_Param_BRMSParamvFWDemoPolicy.1.xml"
49 }' 'http://pypdp:8480/PyPDPServer/deletePolicy'
53 curl -X DELETE --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
54 "pdpGroup": "default",
55 "policyComponent": "PDP",
56 "policyName": "com.Config_BRMS_Param_BRMSParamvLBDemoPolicy.1.xml"
57 }' 'http://pypdp:8480/PyPDPServer/deletePolicy'
60 curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
61 "pdpGroup": "default",
62 "policyName": "BRMSParamvLBDemoPolicy",
64 "policyType": "BRMS_Param"
65 }' 'http://pypdp:8480/PyPDPServer/pushPolicy'
69 curl -X PUT --header 'Content-Type: application/json' --header 'Accept: text/plain' --header 'ClientAuth: cHl0aG9uOnRlc3Q=' --header 'Authorization: Basic dGVzdHJlc3Q6M2MwbXBVI2gwMUBOMWMz' --header 'Environment: TEST' -d '{
70 "pdpGroup": "default",
71 "policyName": "BRMSParamvFWDemoPolicy",
73 "policyType": "BRMS_Param"
74 }' 'http://pypdp:8480/PyPDPServer/pushPolicy'