Wickkiey
Wickkiey

Reputation: 4632

Deploy Azure Funtions with Environment variables - Nodejs

I have a Azure Function Nodejs implementation in local, where I can use environment variable in local.settings.json file.

Once I deploy, I can't find these variables in the portal which causes error,

Should I manually include these settings in Configuration -> Application settings in portal or any other better way.

Thanks in Advance !

Upvotes: 1

Views: 182

Answers (1)

Sajeetharan
Sajeetharan

Reputation: 222522

To publish the code along with the app settings as one unit, you can use the following command from the CLI:

func azure functionapp publish <YourFunctionAppName> --publish-local-settings -i --overwrite-settings -y

then you can see that local variables have been copied across with the right values.

Upvotes: 1

Related Questions