Skip to main content

tcb config pull

Pull the configuration of deployed resources from the cloud into the local cloudbaserc.json, to sync the cloud state or bootstrap a local configuration.

Usage​

tcb config pull <module> [name...] [options]

<module> is the resource module:

ModuleDescription
fnPull function configuration
integrationPull integration configuration

Parameters​

ParameterRequiredDescriptionDefault
[name...]NoResource names, one or more—
--allNoPull every resource declared in the configuration filefalse
-e, --env-id <envId>NoEnvironment ID—
-o, --output <output>NoOutput path, relative paths resolve against the current directorycloudbaserc.json
--stdoutNoPrint to the console instead of writing a filefalse
--code-secret <codeSecret>NoCodeSecret of a code-encrypted function—
--dir <dir>NoDirectory used to infer configuration when the cloud resource is missing—
--yesNoSkip confirmation and overwrite the existing resource with the same namefalse

Examples​

# Pull a single function
tcb config pull fn myFunc

# Pull several functions
tcb config pull fn func1 func2 func3

# Pull every function declared in the configuration file
tcb config pull fn --all

# Print to the console instead of writing a file
tcb config pull fn func1 --stdout

# Custom output path, without confirmation
tcb config pull fn --all -o ./config/cloudbaserc.json --yes

# Pull a single integration
tcb config pull integration myPayment

# Pull every integration
tcb config pull integration --all --yes

Behaviour​

ScenarioBehaviour
Local configuration missingCreated and filled with the pulled configuration
Resource with the same name existsAsks whether to overwrite, --yes overwrites directly
Resource with a different nameAppended to the functions / integrations array
Function missing in the cloudAsks whether to infer the configuration from the local directory, --dir picks the directory
Integration missing in the cloudFails and suggests creating a template with tcb config init integration

Password-like integration fields (API keys, certificates) come back as the ****** placeholder and must be filled in manually.