Skip to content

Dataheroes CLI Commands¤

dataheroes-init¤

The dataheroes-init command provides an interactive CLI for initializing Dataheroes configuration. It allows you to configure your Dataheroes account and connection credentials.

Usage¤

dataheroes-init

This will start an interactive menu-driven interface with the following options:

  1. Activate the Dataheroes account (using email)
  2. Setup Databricks credentials
  3. Setup AWS credentials
  4. Setup GCP credentials
  5. Setup Azure credentials
  6. View current configuration
  7. Exit

Note: If you run dataheroes-init without any command-line options and no configuration file (.dataheroes.config) is found in any of the standard locations (see Configuration Storage below), the tool will skip the main menu and directly prompt you to activate your account via email. Once activated, the configuration file will be created, and subsequent runs will show the full menu.

Command-line Options¤

You can also use command-line options to set specific configuration values directly:

# Activate license with email
dataheroes-init --email=YOUR_EMAIL_ADDRESS

# Set Databricks credentials
dataheroes-init --databricks_api_key=YOUR_API_KEY --databricks_workspace_url=YOUR_WORKSPACE_URL

# Set multiple configurations at once
dataheroes-init --email=YOUR_EMAIL_ADDRESS --databricks_api_key=YOUR_API_KEY

Available Options¤

License Activation¤

  • --email: Email for license activation (required for license activation)

When using the --email option, the command will automatically attempt to activate the license with the Dataheroes licensing server.

Databricks Credentials¤

  • --databricks_api_key: Set Databricks API key
  • --databricks_workspace_url: Set Databricks workspace URL
  • --databricks_http_path: Set Databricks HTTP path (SQL warehouse path or Spark cluster path)
  • --databricks_catalog: Set Databricks catalog
  • --databricks_schema: Set Databricks schema

AWS Credentials¤

  • --aws_access_key_id: Set AWS access key ID
  • --aws_secret_access_key: Set AWS secret access key
  • --aws_region: Set AWS region

GCP Credentials¤

  • --gcp_project_id: Set GCP project ID
  • --gcp_credentials_path: Set GCP credentials path

Azure Credentials¤

  • --storage_connection_string: Sets Azure connection string that points to the storage account

Configuration Storage¤

The configuration is stored in a .dataheroes.config file. The command will use the highest priority location for the configuration file:

  1. Path specified in the DATAHEROES_CONFIG_PATH environment variable (can be a full file path or a directory containing .dataheroes.config)
  2. Current working directory (./.dataheroes.config)
  3. User's home directory (~/.dataheroes.config)

If a configuration file is found, it will be used. If multiple exist, the one with the highest priority (lowest number in the list above) is used. When saving configuration changes (either through options or the interactive menu), the highest priority existing file will be updated, or if none exist, a new file will be created in the user's home directory.

Security¤

  • When displaying existing configuration values, sensitive information is masked by showing only the last 4 characters
  • For any new input that contains sensitive information, the command will confirm with the user before saving