Azure-docs: change module image from cli - json property with dot/period?

Created on 7 Aug 2019  Â·  6Comments  Â·  Source: MicrosoftDocs/azure-docs

I cannot find out how to change a json property past properties.desired, which is a single default tag with a dot/period in it. I have been trying many many things.

For example:
az iot edge deployment update --deployment-id demoimage1-6 --hub-name iot-hubski --set content.modulesContent.'$edgeAgent'.'properties.desired'.modules.'demoimage1-latest'.settings.image=demoworkspac2478a907.azurecr.io/demoimage1:5

See also stackoverflow post
https://stackoverflow.com/questions/57387665/nested-json-path-with-dot-period-in-azure


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Pri2 awaiting-product-team-response cxp in-progress iot-edgsvc product-question triaged

Most helpful comment

The documentation (https://docs.microsoft.com/en-us/cli/azure/ext/azure-cli-iot-ext/iot/edge/deployment?view=azure-cli-latest) currently doesn't have this information; will update it asap.

All 6 comments

@lkoppenol Thanks for the feedback! We are currently investigating and will update you shortly.

@lkoppenol Sorry for the delay. I am reaching out internally I will update you as soon I heard back!

you need to manually strinigying the $edgeHub JSON.

az iot edge deployment update --deployment-id testedge --hub-name microwaves --set content.modulesContent.'$edgeHub'="{'properties.desired': {'routes': {'route': 'FROM /messages/* INTO $upstream'},'schemaVersion': '1.0','storeAndForwardConfiguration': {'timeToLiveSecs': 7201}}}"

However it doesn't do anything because of content being immutable. Items that can be updated by "az iot edge deployment update" command:
labels
metrics
priority
targetCondition
labels and metrics do not allow values with ‘.’ in the name.

Thanks for your answer, here and on stackoverflow :D can you point to the documentation for this?

The documentation (https://docs.microsoft.com/en-us/cli/azure/ext/azure-cli-iot-ext/iot/edge/deployment?view=azure-cli-latest) currently doesn't have this information; will update it asap.

Your attention makes me feel special! thanks

Was this page helpful?
0 / 5 - 0 ratings

Related issues

bityob picture bityob  Â·  3Comments

paulmarshall picture paulmarshall  Â·  3Comments

JamesDLD picture JamesDLD  Â·  3Comments

varma31 picture varma31  Â·  3Comments

jebeld17 picture jebeld17  Â·  3Comments