Skip to main content

CLI Setup

Minimum System Requirements

The system requirements are general guidelines and may vary depending upon the size of the Coalesce project. Projects with a large number of nodes may have higher system requirements.

  • OS: 64-bit Windows 10, macOS 11, Linux kernel version 5.0+
  • Processor: AWS t2.medium vCPU or equivalent / Apple M1 / Intel Core i3-6100 / AMD Ryzen 3 1200 or better
  • RAM: 1 GB+ RAM
  • Storage: 250 MB+ free space
  • Network: Access to Snowflake Instance and Coalesce Cloud
  • Node Version: v20.x

Installation Prerequisites

Windows

Before installing, you'll need to install git. You can download git from https://gitforwindows.org/.

Installation

To install Coalesce CLI globally, run: npm install -g @coalescesoftware/coa. If you need to update run,npm upgrade -g @coalescesoftware/coa.

Generate Your Token

  1. Sign into Coalesce.

  2. Click on the Deploy tab at the top.

  3. Hover over Generate Access Token and copy the token that appears.

    Generate Coalesce access token
SSO Users and Environments

SSO users will need a new token for each new environment created.

Set up Your Configuration File

In your operating system's home directory, create a hidden folder .coa and an empty file with no extension called config inside.

Copy and paste the following information into your config file. Fill in the information based on your Snowflake instance. If you are a PrivateLink or Non-U.S. based customer, you can set your domain by using the domain field

In Coalesce, profiles allow you to run commands against different configurations, making it possible to tailor settings for various environments, such as testing or production. Each CLI command includes the --profile option, which enables you to specify a profile for the scenario you're working with. If no profile is specified, the system defaults to using the [default] profile. While you must have a [default] profile, additional profiles can be named and configured as needed for different scenarios.

Default Profile

The default profile is required

[default]
token=yourtoken
domain=your deployment server. For example, https://app.eu.coalescesoftware.io
snowflakeAuthType=Basic or KeyPair
snowflakePassword=password
snowflakeKeyPairKey=path to the file containing the key (if using KeyPair)
snowflakeKeyPairPass=private key passphrase (if using KeyPair and if applicable)
snowflakeRole=SYSADMIN (or other role)
snowflakeUsername=username
snowflakeWarehouse=COMPUTE_WH
environmentID=one of your non-dev environments

[testing]
token=yourtoken
domain=your deployment server. For example, https://app.eu.coalescesoftware.io
snowflakeAuthType=Basic or KeyPair
snowflakePassword=password
snowflakeKeyPairKey=path to the file containing the key (if using KeyPair)
snowflakeKeyPairPass=private key passphrase (if using KeyPair and if applicable)
snowflakeRole=SYSADMIN (or other role)
snowflakeUsername=username
snowflakeWarehouse=COMPUTE_WH
environmentID=one of your non-dev environments

Create a Plan

You can use the CLI for many different actions. Some of the main uses are Deploy Using the CLI and Refreshing an Environment.

A plan details the target environment, nodes, jobs, and other information needed deploy or refresh.

coa plan

This will generate a coa-plan.json. You can review this file, but we don't recommend editing directly. If you want to make changes, make them using the API or the Coalesce app. Then commit your changes and regenerate your plan.

Authentication

The CLI stores basic authentication credentials locally.

What's Next?