Setting Environment Variables for the Aspera CLI

You can use environment variables to make your interaction with the Aspera CLI smoother. The CLI provides for environment variables around program password, content encryption, Aspera on Cloud client ID and secret, private key, HTTP proxy credentials, and FASP proxy credentials.

Password for the Aspera CLI

To set an environment variable with the value of your password, to be used with all aspera commands, run the following command:

> set ASPERA_PASS=my_password
Note: If your system uses PowerShell, the syntax to set the environment variable is slightly different:
> $env:ASPERA_PASS = "my_password"

Encryption/Decryption Passphrase

If you plan to use encryption on the content you are transferring, you can set an environment variable for your encryption/decryption passphrase. Run the following command:

> set ASPERA_SCP_FILEPASS=my_decryption_passphrase

Client ID, Client Secret, and Private Key for Aspera on Cloud

When you use the Aspera CLI with the Aspera on Cloud (AoC) SaaS, the CLI is a client application to AoC, and must have a client ID, client secret, and the private key portion of a public/private keypair.

  • For the client ID and secret, you can use the default, "global" values that are provided with the CLI in the sample configuration file, or you can generate your own.
  • For the private key, see Configuring for Aspera on Cloud for instructions on generating a keypair and handling its public and private portions.
If you do not want to use the default client ID and client secret, do not want to store your custom client ID and secret in the configuration file, or if you do not want to store the private key on disk (for example, if your security policies prohibit this practice), you can instead set environment variables to pass these values to the application. Do the following:
  1. Set the environment variables.
    > set ACLI_CLIENT_ID=my_client_id
    > set ACLI_CLIENT_SECRET=my_client_secret
    > set ACLI_PRIVATE_KEY64=my_private_key
  2. Confirm that the environment variables are set.
    > echo $ACLI_CLIENT_ID
    > echo $ACLI_CLIENT_SECRET
    > echo $ACLI_PRIVATE_KEY64
  3. [Optional] Remove the private key .pem file from your CLI installation's etc directory.

If you don't set environment variables for the client ID, client secret, and private key, the CLI reverts to finding them in the .aspera_cli_conf configuration file. See Configuring for Aspera on Cloud for instructions on editing the configuration file.

HTTP Proxy Credentials

If your content is to be transferred through an HTTP proxy server, and if that server is configured to require a username and password, you can set environment variables for these credentials. Run the following commands:

> set PROXY_USERNAME=my_http_proxy_username
> set PROXY_PASSWORD=my_http_proxy_password

Aspera Proxy Credentials

If your content is to be transferred through an Aspera proxy server, and if that server is configured to require a username and password, you can set environment variables for these credentials. Run the following commands:

> set FASP_USERNAME=my_aspera_proxy_username
> set FASP_PASSWORD=my_aspera_proxy_password