mirror of https://github.com/databricks/cli.git
1fc903943d
## Changes <!-- Summary of your changes that are easy to understand --> 1. Log os.Args and bricks version before every command execution 2. After a command execution, logs the error and exit code ## Tests <!-- How is this tested? --> Manually, case 1: Run `bricks version` successfully ``` shreyas.goenka@THW32HFW6T bricks % bricks version --log-level=info --log-file stderr time=2023-04-12T00:15:04.011+02:00 level=INFO source=root.go:34 msg="process args: [bricks, version, --log-level=info, --log-file, stderr]" time=2023-04-12T00:15:04.011+02:00 level=INFO source=root.go:35 msg="version: 0.0.0-dev+375eb1c50283" 0.0.0-dev+375eb1c50283 time=2023-04-12T00:15:04.011+02:00 level=INFO source=root.go:68 msg="exit code: 0" ``` case 2: Run `bricks bundle deploy` in a working dir where `bundle.yml` does not exist ``` shreyas.goenka@THW32HFW6T bricks % bricks bundle deploy --log-level=info --log-file=stderr time=2023-04-12T00:19:16.783+02:00 level=INFO source=root.go:34 msg="process args: [bricks, bundle, deploy, --log-level=info, --log-file=stderr]" time=2023-04-12T00:19:16.784+02:00 level=INFO source=root.go:35 msg="version: 0.0.0-dev+375eb1c50283" Error: unable to locate bundle root: bundle.yml not found time=2023-04-12T00:19:16.784+02:00 level=ERROR source=root.go:64 msg="unable to locate bundle root: bundle.yml not found" time=2023-04-12T00:19:16.784+02:00 level=ERROR source=root.go:65 msg="exit code: 1" ``` |
||
---|---|---|
.github | ||
.vscode | ||
bundle | ||
cmd | ||
docs | ||
folders | ||
internal | ||
libs | ||
python | ||
sandbox | ||
.gitignore | ||
.goreleaser.yaml | ||
Makefile | ||
README.md | ||
go.mod | ||
go.sum | ||
main.go | ||
main_test.go |
README.md
Bricks CLI 🧱
Where's "data"? Secured by the unity catalog. Projects build lifecycle is secured by bricks
🧱
This is an early PoC at this stage. make build
(or download the latest from releases page).
Reuses authentication from Databricks CLI. And terraform provider. See details here: https://registry.terraform.io/providers/databrickslabs/databricks/latest/docs#environment-variables
Supports:
- Databricks CLI
- Databricks CLI Profiles
- Azure CLI Auth
- Azure MSI Auth
- Azure SPN Auth
- Google OIDC Auth
- Direct
DATABRICKS_HOST
,DATABRICKS_TOKEN
orDATABRICKS_USERNAME
+DATABRICKS_PASSWORD
variables.
What works:
./bricks fs ls /
./bricks test
./bricks launch test.py
What doesn't work:
- Everything else.
This project reuses some code from Databricks Terraform Provider