Skip to main content

hivepaas env

An app's environment variables

hivepaas env [command]

hivepaas env ls​

List an app's environment variables

hivepaas env ls [flags]

Flags:

FlagDescription
--allwith those HivePaaS sets and those the app inherits
--buildonly the build-time variables
--sharedonly the shared variables

hivepaas env pull​

Write the variables an app runs with as a .env file: those it inherits, its shared ones and its runtime ones, or with --build its build-time ones - the app's own over what it inherits. Those HivePaaS sets, which describe the app where it runs, are left out. A value naming others, ${db.HIVEPAAS_URL}, is written as it is: only the server expands it.

Without FILE it writes to stdout. A FILE that exists is replaced only with --force; the file is made readable by you alone, for it holds secrets.

hivepaas env pull [FILE] [flags]

Examples:

hivepaas env pull .env.local
hivepaas env pull -a worker > worker.env

Flags:

FlagDescription
--buildthe build-time variables instead of the runtime ones
--forcereplace FILE when it exists

hivepaas env set​

Set environment variables of an app: the runtime ones, or with --build or --shared the build-time or shared ones. A value may name others, ${db.HIVEPAAS_URL}, unless --literal.

--file sets those of a .env file, - for stdin; KEY=VALUE arguments beside it win.

hivepaas env set [KEY=VALUE...] [flags]

Examples:

hivepaas env set LOG_LEVEL=debug FEATURE_X=on
hivepaas env set --file .env.production
hivepaas env set --build NODE_ENV=production

Flags:

FlagDescription
--buildset the build-time variables
--file stringset the variables of this .env file; - reads stdin
--literaltake the values as they are, without expanding ${...}
--sharedset the shared variables

hivepaas env unset​

Remove environment variables of an app

hivepaas env unset KEY... [flags]

Flags:

FlagDescription
--buildremove from the build-time variables
--sharedremove from the shared variables

The global flags apply to every command.