summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xupdate.sh21
1 files changed, 12 insertions, 9 deletions
diff --git a/update.sh b/update.sh
index d67006d..dfe0a5d 100755
--- a/update.sh
+++ b/update.sh
@@ -33,19 +33,22 @@ if [ "$config_ip" != "$actual_ip" ]; then
cat <<EOF > $RECORD_CHANGE_JSON
{
"Changes": [
- "Action": "UPSERT",
- "ResourceRecordSet": {
- "Name": "$DOMAIN",
- "Type": "A",
- "TTL": 300,
- "ResourceRecords": [
- "Value": "$actual_ip"
- ]
+ {
+ "Action": "UPSERT",
+ "ResourceRecordSet": {
+ "Name": "$DOMAIN",
+ "Type": "A",
+ "TTL": 300,
+ "ResourceRecords": [
+ "Value": "$actual_ip"
+ ]
+ }
}
]
}
EOF
- aws route53 change-resource-record-sets --hosted-zone-id $HOSTED_ZONE_ID \
+ aws route53 change-resource-record-sets \
+ --hosted-zone-id $HOSTED_ZONE_ID \
--change-batch $RECORD_CHANGE_JSON
else