Expose ec2_instance_type (#2107)
This commit is contained in:
parent
36de163900
commit
296644adeb
|
@ -37,6 +37,7 @@ const (
|
|||
ec2LabelAZ = ec2Label + "availability_zone"
|
||||
ec2LabelInstanceID = ec2Label + "instance_id"
|
||||
ec2LabelInstanceState = ec2Label + "instance_state"
|
||||
ec2LabelInstanceType = ec2Label + "instance_type"
|
||||
ec2LabelPublicDNS = ec2Label + "public_dns_name"
|
||||
ec2LabelPublicIP = ec2Label + "public_ip"
|
||||
ec2LabelPrivateIP = ec2Label + "private_ip"
|
||||
|
@ -153,6 +154,7 @@ func (ed *EC2Discovery) refresh() (tg *config.TargetGroup, err error) {
|
|||
|
||||
labels[ec2LabelAZ] = model.LabelValue(*inst.Placement.AvailabilityZone)
|
||||
labels[ec2LabelInstanceState] = model.LabelValue(*inst.State.Name)
|
||||
labels[ec2LabelInstanceType] = model.LabelValue(*inst.InstanceType)
|
||||
|
||||
if inst.VpcId != nil {
|
||||
labels[ec2LabelVPCID] = model.LabelValue(*inst.VpcId)
|
||||
|
|
Loading…
Reference in New Issue