Is there any way to control what version of dependencies (and transient dependencies) are installed when deploying a cloud function?
Since the cloud function runtime uses node v6.11.5
, I assume it is using npm v3.10.10
distributed with that version of node. This version of npm does not support package.lock
(added in npm v5.0.0
).
I set all versions to fixed versions (removing the ^
) in my package.json
and added save-exact=true
to my .npmrc
file, but this will only control direct dependencies. Transient dependencies are not locked in this manner.
Is there any way to control all installed dependency versions in cloud functions? Is npm shrinkwrap.json
honored?