Skip to content

Commit

Permalink
dns_zone_id
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaopal committed May 10, 2018
1 parent 00a91bd commit 7e8e29f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions files/npc-setup.instance.sh
Original file line number Diff line number Diff line change
Expand Up @@ -188,11 +188,11 @@ instances_prepare(){
}

local DNS_ZONE="$(jq -r '.dns_zone//empty'<<<"$INSTANCE")" DNS_ZONE_CONFIG='{}' && [ ! -z "$DNS_ZONE" ] && {
DNS_ZONE_CONFIG="$(dns_zones_lookup "$DNS_ZONE" "{dns_zone: .HostedZoneId}")" && [ ! -z "$DNS_ZONE_CONFIG" ] || return 1
DNS_ZONE_CONFIG="$(dns_zones_lookup "$DNS_ZONE" "{dns_zone_id: .HostedZoneId}")" && [ ! -z "$DNS_ZONE_CONFIG" ] || return 1
}

local REVERSE_ZONE="$(jq -r '.reverse_dns_zone//empty'<<<"$INSTANCE")" REVERSE_ZONE_CONFIG='{}' && [ ! -z "$REVERSE_ZONE" ] && {
REVERSE_ZONE_CONFIG="$(dns_zones_lookup "$REVERSE_ZONE" "{reverse_dns_zone: .HostedZoneId}")" && [ ! -z "$REVERSE_ZONE_CONFIG" ] || return 1
REVERSE_ZONE_CONFIG="$(dns_zones_lookup "$REVERSE_ZONE" "{reverse_dns_zone_id: .HostedZoneId}")" && [ ! -z "$REVERSE_ZONE_CONFIG" ] || return 1
}

IMAGE_ID="$IMAGE_ID" \
Expand Down Expand Up @@ -307,8 +307,8 @@ api2_create_instance(){
else false end),
NetworkChargeType: (if .vpc_network and .vpc_inet then "TRAFFIC" else false end),
AssociatePrivateIdcIpAddress: (if .vpc_network and .vpc_corp then true else false end),
DnsZoneId: .dns_zone,
ReverseZoneId: .reverse_dns_zone,
DnsZoneId: .dns_zone_id,
ReverseZoneId: .reverse_dns_zone_id,
Personality: (.user_data//{} | to_entries | map({
Path: .key,
Contents: .value
Expand Down

0 comments on commit 7e8e29f

Please sign in to comment.