Has anyone seen Pulumi "forget" an Azure Function ...
# azure
c
Has anyone seen Pulumi "forget" an Azure Function App Setting? It's only one that's gone. It's in the code (I promise 😉 ) but it's not in the state file anymore and won't get applied to the Function.
Okay, somehow, I had to refresh the stack a few times, eventually that one App Setting ended up in the stack. Not sure what happened.
Oh man, okay, so I'm not sure what's happening. The app setting is in the code (always has been), it's in the state, but when running
pulumi up -r
and looking at the diff pulumi wants to delete the app setting.
So, that app setting uses a value coming from another resource (specifically the connection string from a cosmos DB account). I reference this by
cosmosDbAccount.connectionStrings[0]
this used to work, we used this for months, but now that doesn't seem to work anymore, the app setting isn't empty or anything, it just gets deleted. If I change the value to a string of any sort, it gets created, all good. So, what is happening?
Only got it working now by putting the connection string into pulumi as a config secret, which works, but is obviously not a good solution, as this only works because the account already exists. So, what is happening? Do we need to expedite our migration to azure-nextgen?
g
Real quick, can you run a
pulumi about
for me so I know what versions of the various packages you're using?
c
Copy code
bash-5.0# pulumi about
CLI
Version      3.21.0
Go Version   go1.17.5
Go Compiler  gc

Plugins
NAME          VERSION
azure         4.30.0
azure-native  1.52.0
nodejs        unknown
random        4.3.1

Host
OS       alpine
Version  3.11.6
Arch     x86_64

This project is written in nodejs (/usr/bin/node v12.20.1)

Backend
Name     0b4c24e51500
URL      <azblob://state>
User     root

NAME                  VERSION
@pulumi/azure         4.30.0
@pulumi/azure-native  1.52.0
@pulumi/pulumi        3.19.0
@pulumi/random        4.3.1
@types/glob           7.1.3
@types/node           10.17.28
glob                  7.1.6