Environment variables
Arius supports environment variables for sensitive credentials. When an environment variable is set, it takes precedence over the corresponding CLI flag.
| Variable | Description | Corresponding flag |
|---|
ARIUS_ACCOUNT_NAME | Azure Storage Account name | --accountname / -n |
ARIUS_ACCOUNT_KEY | Azure Storage Account key | --accountkey / -k |
Set ARIUS_ACCOUNT_KEY via an environment variable rather than passing it as a CLI argument. This prevents the key from appearing in your shell history and process listings.
CLI flags — archive
Archives a local directory to Azure Blob Storage.
arius archive <path>
--accountname <accountname> (or -n)
--accountkey <accountkey> (or -k)
--passphrase <passphrase> (or -p)
--container <containername> (or -c)
[--remove-local]
[--tier=<hot|cool|archive>]
| Flag | Short | Required | Default | Description |
|---|
<path> | — | Yes | — | Root directory on the local filesystem to archive. |
--accountname | -n | Yes | — | Azure Storage Account name. Also readable from ARIUS_ACCOUNT_NAME env var. |
--accountkey | -k | Yes | — | Azure Storage Account key. Also readable from ARIUS_ACCOUNT_KEY env var. |
--passphrase | -p | Yes | — | Passphrase used to encrypt blobs (AES256). |
--container | -c | Yes | — | Azure Blob Storage container name. |
--remove-local | — | No | false | Remove local files after a successful upload. |
--tier | — | No | archive | Storage tier for uploaded blobs: hot, cool, or archive. |
CLI flags — restore
Restores files from Azure Blob Storage to the local filesystem.
arius restore [targets...]
--accountname <accountname> (or -n)
--accountkey <accountkey> (or -k)
--passphrase <passphrase> (or -p)
--container <containername> (or -c)
[--root <directory>] (or -r)
[--download]
[--include-pointers]
| Flag | Short | Required | Default | Description |
|---|
[targets...] | — | No | ./ | Directory or files to restore. If a directory is given, all pointer files in it and its subdirectories are restored. |
--accountname | -n | Yes | — | Azure Storage Account name. Also readable from ARIUS_ACCOUNT_NAME env var. |
--accountkey | -k | Yes | — | Azure Storage Account key. Also readable from ARIUS_ACCOUNT_KEY env var. |
--passphrase | -p | Yes | — | Passphrase used to decrypt blobs. |
--container | -c | Yes | — | Azure Blob Storage container name. |
--root | -r | No | Current directory | Root directory for the restore operation (non-Docker only). |
--download | — | No | false | Download the actual file contents. If the blob is in the archive tier, rehydration is triggered; run restore again after ~15 hours. |
--include-pointers | — | No | false | Create pointer files (.pointer.arius) alongside the downloaded binaries. |
Environment variable precedence
When both an environment variable and a CLI flag are provided for the same option, the CLI flag takes precedence. Environment variables act as fallbacks when no flag is explicitly passed. This behaviour is implemented through the EnvironmentVariable attribute on each CommandOption in the CliFx framework.
CLI flag → used if explicitly passed on the command line
Environment variable → used as fallback when no CLI flag is present
Docker configuration example
When running Arius in Docker, use a .env file to pass credentials without exposing them in your shell history or docker run command.
# .env
ARIUS_ACCOUNT_NAME=mystorageaccount
ARIUS_ACCOUNT_KEY=base64encodedkeyhere==
docker run \
--env-file .env \
-v /absolute/path/to/archive:/archive \
-v /absolute/path/to/logs:/logs \
woutervanranst/arius \
archive \
--passphrase mysecretpassphrase \
--container arius
Mount a /logs volume to retain structured log output outside the container for debugging and audit purposes.