This commit is contained in:
Raaghavi Sivaguru 2020-06-09 09:43:22 -07:00
Родитель 6a73403b8a
Коммит 3debe68a28
3 изменённых файлов: 1 добавлений и 7 удалений

Просмотреть файл

@ -6,7 +6,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
Gem::Specification.new do |spec|
spec.name = "fluent-plugin-imds"
spec.version = "0.1.4"
spec.version = "0.1.5"
spec.authors = ["Matt Juel "]
spec.email = ["v-majuel@microsoft"]

Просмотреть файл

@ -60,7 +60,6 @@ module Fluent
@IMDS = {"compute" => {"subscriptionId" => "",
"location" => "",
"resourceGroupName" => "",
"resourceId" => "",
"name" => "",
"vmSize" => "",
"vmId" => "",
@ -82,7 +81,6 @@ module Fluent
record["subscriptionId"] = data["compute"]["subscriptionId"]
record["region"] = data["compute"]["location"]
record["resourceGroupName"] = data["compute"]["resourceGroupName"]
record["resourceId"] = data["compute"]["resourceId"]
record["vmName"] = data["compute"]["name"]
record["vmSize"] = data["compute"]["vmSize"]
record["vmId"] = data["compute"]["vmId"]

Просмотреть файл

@ -60,7 +60,6 @@ class ImdsFilterTest < Test::Unit::TestCase
assert_equal(d.filtered_records[0]["subscriptionId"], "0000a0a0-0a0a-000a-0000-000a000aa0a")
assert_equal(d.filtered_records[0]["region"], "eastus")
assert_equal(d.filtered_records[0]["resourceGroupName"], "juelm-imds-fluentd")
assert_equal(d.filtered_records[0]["resourceId"], "/subscriptions/0000a0a0-0a0a-000a-0000-000a000aa0a/resourceGroups/juelm-imds-fluentd/providers/Microsoft.Compute/virtualMachines/fluentd-test2")
assert_equal(d.filtered_records[0]["vmName"], "fluentd-test2")
assert_equal(d.filtered_records[0]["vmSize"], "Standard_B2s")
assert_equal(d.filtered_records[0]["vmId"], "a7ff7831-57cf-4fa6-9016-726d1c81dfdf")
@ -93,7 +92,6 @@ class ImdsFilterTest < Test::Unit::TestCase
assert_equal(d.filtered_records[0]["subscriptionId"], "")
assert_equal(d.filtered_records[0]["region"], "")
assert_equal(d.filtered_records[0]["resourceGroupName"], "")
assert_equal(d.filtered_records[0]["resourceId"], "")
assert_equal(d.filtered_records[0]["vmName"], "")
assert_equal(d.filtered_records[0]["vmSize"], "")
assert_equal(d.filtered_records[0]["vmId"], "")
@ -128,7 +126,6 @@ class ImdsFilterTest < Test::Unit::TestCase
assert_equal(d.filtered_records[0]["subscriptionId"], "")
assert_equal(d.filtered_records[0]["region"], "")
assert_equal(d.filtered_records[0]["resourceGroupName"], "")
assert_equal(d.filtered_records[0]["resourceId"], "")
assert_equal(d.filtered_records[0]["vmName"], "")
assert_equal(d.filtered_records[0]["vmSize"], "")
assert_equal(d.filtered_records[0]["vmId"], "")
@ -161,7 +158,6 @@ class ImdsFilterTest < Test::Unit::TestCase
assert_equal(d.filtered_records[1]["subscriptionId"], "0000a0a0-0a0a-000a-0000-000a000aa0a")
assert_equal(d.filtered_records[1]["region"], "eastus")
assert_equal(d.filtered_records[1]["resourceGroupName"], "juelm-imds-fluentd")
assert_equal(d.filtered_records[1]["resourceId"], "/subscriptions/0000a0a0-0a0a-000a-0000-000a000aa0a/resourceGroups/juelm-imds-fluentd/providers/Microsoft.Compute/virtualMachines/fluentd-test2")
assert_equal(d.filtered_records[1]["vmName"], "fluentd-test2")
assert_equal(d.filtered_records[1]["vmSize"], "Standard_B2s")
assert_equal(d.filtered_records[1]["vmId"], "a7ff7831-57cf-4fa6-9016-726d1c81dfdf")