-
Notifications
You must be signed in to change notification settings - Fork 329
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LoadBalancerV2 target groups: include port and protocol to EC2Instance #1278
Changes from 4 commits
7767e94
5c8454f
64dc3a5
6249dc6
02b535b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -157,8 +157,10 @@ def load_load_balancer_v2_target_groups( | |
ingest_instances = """ | ||
MATCH (elbv2:LoadBalancerV2{id: $ID}), (instance:EC2Instance{instanceid: $INSTANCE_ID}) | ||
MERGE (elbv2)-[r:EXPOSE]->(instance) | ||
ON CREATE SET r.firstseen = timestamp() | ||
SET r.lastupdated = $update_tag | ||
ON CREATE SET r.firstseen = timestamp(), | ||
r.target_group_arn = $TARGET_GROUP_ARN | ||
SET r.lastupdated = $update_tag, | ||
r.port = $PORT, r.protocol = $PROTOCOL | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You missed a comma. Needs to be
Also, is the ARN of the target group available? If so, maybe we should include the ARN of the target group as There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh also let's remember to update the schema doc |
||
WITH instance | ||
MATCH (aa:AWSAccount{id: $AWS_ACCOUNT_ID}) | ||
MERGE (aa)-[r:RESOURCE]->(instance) | ||
|
@@ -177,6 +179,9 @@ def load_load_balancer_v2_target_groups( | |
ID=load_balancer_id, | ||
INSTANCE_ID=instance, | ||
AWS_ACCOUNT_ID=current_aws_account_id, | ||
TARGET_GROUP_ARN=target_group.get('TargetGroupArn'), | ||
PORT=target_group.get('Port'), | ||
PROTOCOL=target_group.get('Protocol'), | ||
update_tag=update_tag, | ||
) | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible for the target_group_arn to change? To be safe, let's move this to the SET clause.