Trying to use provision by claim and provisioning hook to admit the device. The provisioning hook output will return a formatted thingName rather than the name passed into the provisioning hook,
const requestedThingName = input.parameters.ThingName;
....
const output = {
allowProvisioning: True,
parameterOverrides: {
ThingName: newThingName,
},
this works, but on the device side, after iot mqtt session successfully established, in /greengrass/v2/config/effectiveConfig.yaml, the file looks like this:
system:
certificateFilePath: ""
privateKeyPath: ""
rootCaPath: ""
rootpath: "/greengrass/v2"
thingName: ""
services:
aws.greengrass.FleetProvisioningByClaim:
configuration:
I would expect, updated thingName is there under thingName key.
I can only see the newThingName in config.tlog:
{"TS":1649181903995,"TP":["setenv","AWS_IOT_THING_NAME"],"W":"changed","V":"newThingName"}
I think effectiveConfig.yaml should be updated.