CLI Reference
LakeXpress works in two steps:
- Create a sync configuration with
config create. It is stored in the LakeXpress DB. - Run it with
sync, as often as needed.
The other commands manage the LakeXpress DB (lxdb), show run status (status) and remove stale runs (cleanup).
This section describes the syntax and options of each command. For complete, ready-to-run commands, see Examples & Recipes.
Commands
| Command | Purpose |
|---|---|
lxdb init, drop, truncate, locks, release-locks | Manage the LakeXpress DB |
config create, list, delete | Manage sync configurations |
sync, sync[export], sync[publish] | Run a sync configuration |
status | Show syncs and runs |
cleanup | Remove stale or failed runs |
run | Run a legacy YAML configuration |
Command Line Structure
usage: LakeXpress [-h] [-v | --version] [--no_banner]
COMMAND [SUBCOMMAND] [OPTIONS]
-h, --version and --no_banner can be placed before the command. All other options go after the command, for example LakeXpress sync --log_level DEBUG ....
Common Options
Every command accepts these options. The pages of each command list only its own options.
| Option | Description |
|---|---|
-a, --auth_file PATH | Credentials JSON file. Required by every command except run |
--lxdb_auth_id ID | Entry of the credentials file for the LakeXpress DB. Required by every command except run |
--log_level LEVEL | DEBUG, INFO (default), WARNING or ERROR |
--log_dir PATH | Directory for the run log files, created if needed (default: current directory). Used by sync, sync[export] and run. See Logging |
--no_progress | Disable the progress bars (export and publish) |
--no_banner | Do not print the startup banner |
--quiet_fbcp | Do not copy FastBCP log lines into the LakeXpress logs (statistics are still recorded) |
--license TEXT | License text (alternative to the LAKEXPRESS_LICENSE environment variable) |
--license_file PATH | Path to a license file |
-h, --help | Show the help of the command and exit |
LakeXpress --version (or -v) shows the version and the date the binary was built.
License Resolution
LakeXpress looks for a license in this order:
LAKEXPRESS_LICENSEenvironment variable--license--license_file- Default file locations:
- Linux:
~/.lakexpress/license.lic - Windows:
%APPDATA%/LakeXpress/license.lic - Current directory:
./license.lic
- Linux:
There is no license-free trial: the free 30-day trial is a license file from arpe.io. Without a valid license, every command except --help and --version exits with code 13 (LICENSE_ERROR).
The license file also carries the FastBCP and ADBC driver licenses: keep it whole, as delivered.
Examples
A license file outside the default locations. Add --license_file to every command, after the command name:
./LakeXpress sync \
-a credentials.json \
--lxdb_auth_id lxdb_postgres \
--sync_id <SYNC_ID> \
--license_file /opt/lakexpress/license/LakeXpress.lic
.\LakeXpress.exe sync `
-a credentials.json `
--lxdb_auth_id lxdb_postgres `
--sync_id <SYNC_ID> `
--license_file C:\licenses\LakeXpress.lic
Scheduled jobs (cron, Task Scheduler, Airflow). Use an absolute path: the job's working directory and home directory are often not the ones of your interactive session, so the default locations may not be found.
# crontab: daily sync at 02:00
0 2 * * * cd /opt/lakexpress && ./LakeXpress sync -a /opt/lakexpress/credentials.json --lxdb_auth_id lxdb_postgres --sync_id <SYNC_ID> --license_file /opt/lakexpress/license/LakeXpress.lic --no_banner --no_progress
CI and containers: the LAKEXPRESS_LICENSE environment variable. It holds the license text itself, for example from a CI secret, so no file has to be copied onto the machine:
export LAKEXPRESS_LICENSE="$(cat /opt/lakexpress/license/LakeXpress.lic)"
./LakeXpress sync -a credentials.json --lxdb_auth_id lxdb_postgres --sync_id <SYNC_ID>
$env:LAKEXPRESS_LICENSE = Get-Content -Raw C:\licenses\LakeXpress.lic
.\LakeXpress.exe sync -a credentials.json --lxdb_auth_id lxdb_postgres --sync_id <SYNC_ID>
In a container, either set LAKEXPRESS_LICENSE from your secret store, or mount the file read-only and point to it:
docker run --rm \
-v /opt/lakexpress/license/LakeXpress.lic:/license/LakeXpress.lic:ro \
<your-lakexpress-image> \
sync -a /config/credentials.json --lxdb_auth_id lxdb_postgres --sync_id <SYNC_ID> \
--license_file /license/LakeXpress.lic
LAKEXPRESS_LICENSEcomes first in the lookup order: when it is set,--licenseand--license_fileare ignored, even if the variable holds an invalid license (exit 13). Unset it (unset LAKEXPRESS_LICENSE,Remove-Item Env:LAKEXPRESS_LICENSE) if a command does not pick up the file you pass.- Prefer
--license_fileorLAKEXPRESS_LICENSEto--license "<text>": a command-line argument is visible to other users of the machine in the process list (ps, Task Manager).