Hi I would like to consult on any ideas on how I can manipulate a json file via linux command line by swapping the Weight values (0 and 100) of 2 objects.
From This:
[
{
"Type": "forward",
"ForwardConfig": {
"TargetGroups": [
{
"TargetGroupArn": "arn:aws:elasticloadbalancing:us-east-1:123456789:targetgroup/Pogi-Clust-MABAHOUTOT/0887654321",
"Weight": "100"
},
{
"TargetGroupArn": "arn:aws:elasticloadbalancing:us-east-1:123456789:targetgroup/Pogi-Clust-UTOMABAHO/1234567890",
"Weight": "0"
}
],
"TargetGroupStickinessConfig": {
"Enabled": false
}
}
}
]
To This:
[
{
"Type": "forward",
"ForwardConfig": {
"TargetGroups": [
{
"TargetGroupArn": "arn:aws:elasticloadbalancing:us-east-1:123456789:targetgroup/Pogi-Clust-MABAHOUTOT/0887654321",
"Weight": "0"
},
{
"TargetGroupArn": "arn:aws:elasticloadbalancing:us-east-1:123456789:targetgroup/Pogi-Clust-UTOMABAHO/1234567890",
"Weight": "100"
}
],
"TargetGroupStickinessConfig": {
"Enabled": false
}
}
}
]