mirror of https://github.com/databricks/cli.git
Compare commits
4 Commits
dfa6efdef2
...
95673233b9
Author | SHA1 | Date |
---|---|---|
|
95673233b9 | |
|
8d849fe868 | |
|
f2096eddcc | |
|
b151ed7572 |
4
Makefile
4
Makefile
|
@ -28,7 +28,7 @@ test:
|
|||
|
||||
cover:
|
||||
rm -fr ./acceptance/build/cover/
|
||||
CLI_GOCOVERDIR=build/cover ${GOTESTSUM_CMD} -- -coverprofile=coverage.txt ${PACKAGES}
|
||||
VERBOSE_TEST=1 CLI_GOCOVERDIR=build/cover ${GOTESTSUM_CMD} -- -coverprofile=coverage.txt ${PACKAGES}
|
||||
rm -fr ./acceptance/build/cover-merged/
|
||||
mkdir -p acceptance/build/cover-merged/
|
||||
go tool covdata merge -i $$(printf '%s,' acceptance/build/cover/* | sed 's/,$$//') -o acceptance/build/cover-merged/
|
||||
|
@ -61,6 +61,6 @@ integration: vendor
|
|||
$(INTEGRATION)
|
||||
|
||||
integration-short: vendor
|
||||
$(INTEGRATION) -short
|
||||
VERBOSE_TEST=1 $(INTEGRATION) -short
|
||||
|
||||
.PHONY: lint tidy lintcheck fmt test cover showcover build snapshot vendor schema integration integration-short acc-cover acc-showcover docs
|
||||
|
|
|
@ -30,8 +30,9 @@ import (
|
|||
)
|
||||
|
||||
var (
|
||||
KeepTmp bool
|
||||
NoRepl bool
|
||||
KeepTmp bool
|
||||
NoRepl bool
|
||||
VerboseTest bool = os.Getenv("VERBOSE_TEST") != ""
|
||||
)
|
||||
|
||||
// In order to debug CLI running under acceptance test, set this to full subtest name, e.g. "bundle/variables/empty"
|
||||
|
@ -261,7 +262,7 @@ func runTest(t *testing.T, dir, coverDir string, repls testdiff.ReplacementsCont
|
|||
// 2. The test is configured to record requests and assert on them. We need
|
||||
// a duplicate of the default server to record requests because the default
|
||||
// server otherwise is a shared resource.
|
||||
if len(config.Server) > 0 || config.RecordRequests {
|
||||
if cloudEnv == "" && (len(config.Server) > 0 || config.RecordRequests) {
|
||||
server = testserver.New(t)
|
||||
server.RecordRequests = config.RecordRequests
|
||||
server.IncludeRequestHeaders = config.IncludeRequestHeaders
|
||||
|
@ -412,7 +413,7 @@ func doComparison(t *testing.T, repls testdiff.ReplacementsContext, dirRef, dirN
|
|||
testutil.WriteFile(t, pathRef, valueNew)
|
||||
}
|
||||
|
||||
if !equal && printedRepls != nil && !*printedRepls {
|
||||
if VerboseTest && !equal && printedRepls != nil && !*printedRepls {
|
||||
*printedRepls = true
|
||||
var items []string
|
||||
for _, item := range repls.Repls {
|
||||
|
|
|
@ -10,6 +10,8 @@ description: Learn about resources supported by Databricks Asset Bundles and how
|
|||
|
||||
This article outlines supported resource types for bundles and provides details and an example for each supported type. For additional examples, see [_](/dev-tools/bundles/resource-examples.md).
|
||||
|
||||
.. tip:: To generate YAML for any existing resource, use the `databricks bundle generate` command. See [_](/dev-tools/cli/bundle-commands.md#generate).
|
||||
|
||||
## <a id="resource-types"></a> Supported resources
|
||||
|
||||
The following table lists supported resource types for bundles. Some resources can be created by defining them in a bundle and deploying the bundle, and some resources only support referencing an existing resource to include in the bundle.
|
||||
|
@ -19,53 +21,112 @@ Resources are defined using the corresponding [Databricks REST API](/api/workspa
|
|||
.. tip:: The `databricks bundle validate` command returns warnings if unknown resource properties are found in bundle configuration files.
|
||||
|
||||
|
||||
.. list-table::
|
||||
:header-rows: 1
|
||||
.. azure-aws::
|
||||
|
||||
* - Resource
|
||||
- Create support
|
||||
- Corresponding REST API object
|
||||
.. list-table::
|
||||
:header-rows: 1
|
||||
|
||||
* - [cluster](#cluster)
|
||||
- ✓
|
||||
- [Cluster object](/api/workspace/clusters/create)
|
||||
* - Resource
|
||||
- Create support
|
||||
- Corresponding REST API object
|
||||
|
||||
* - [dashboard](#dashboard)
|
||||
-
|
||||
- [Dashboard object](/api/workspace/lakeview/create)
|
||||
* - [app](#apps)
|
||||
- ✓
|
||||
- [App object](/api/workspace/apps/create)
|
||||
|
||||
* - [experiment](#experiment)
|
||||
- ✓
|
||||
- [Experiment object](/api/workspace/experiments/createexperiment)
|
||||
* - [cluster](#clusters)
|
||||
- ✓
|
||||
- [Cluster object](/api/workspace/clusters/create)
|
||||
|
||||
* - [job](#job)
|
||||
- ✓
|
||||
- [Job object](/api/workspace/jobs/create)
|
||||
* - [dashboard](#dashboards)
|
||||
-
|
||||
- [Dashboard object](/api/workspace/lakeview/create)
|
||||
|
||||
* - [model (legacy)](#model-legacy)
|
||||
- ✓
|
||||
- [Model (legacy) object](/api/workspace/modelregistry/createmodel)
|
||||
* - [experiment](#experiments)
|
||||
- ✓
|
||||
- [Experiment object](/api/workspace/experiments/createexperiment)
|
||||
|
||||
* - [model_serving_endpoint](#model-serving-endpoint)
|
||||
- ✓
|
||||
- [Model serving endpoint object](/api/workspace/servingendpoints/create)
|
||||
* - [job](#jobs)
|
||||
- ✓
|
||||
- [Job object](/api/workspace/jobs/create)
|
||||
|
||||
* - [pipeline](#pipeline)
|
||||
- ✓
|
||||
- [Pipeline object](/api/workspace/pipelines/create)
|
||||
* - [model (legacy)](#models)
|
||||
- ✓
|
||||
- [Model (legacy) object](/api/workspace/modelregistry/createmodel)
|
||||
|
||||
* - [quality_monitor](#quality-monitor)
|
||||
- ✓
|
||||
- [Quality monitor object](/api/workspace/qualitymonitors/create)
|
||||
* - [model_serving_endpoint](#model_serving_endpoints)
|
||||
- ✓
|
||||
- [Model serving endpoint object](/api/workspace/servingendpoints/create)
|
||||
|
||||
* - [registered_model](#registered-model) (<UC>)
|
||||
- ✓
|
||||
- [Registered model object](/api/workspace/registeredmodels/create)
|
||||
* - [pipeline](#pipelines)
|
||||
- ✓
|
||||
- [Pipeline object]](/api/workspace/pipelines/create)
|
||||
|
||||
* - [schema](#schema) (<UC>)
|
||||
- ✓
|
||||
- [Schema object](/api/workspace/schemas/create)
|
||||
* - [quality_monitor](#quality_monitors)
|
||||
- ✓
|
||||
- [Quality monitor object](/api/workspace/qualitymonitors/create)
|
||||
|
||||
* - [volume](#volume) (<UC>)
|
||||
- ✓
|
||||
- [Volume object](/api/workspace/volumes/create)
|
||||
* - [registered_model](#registered_models) (<UC>)
|
||||
- ✓
|
||||
- [Registered model object](/api/workspace/registeredmodels/create)
|
||||
|
||||
* - [schema](#schemas) (<UC>)
|
||||
- ✓
|
||||
- [Schema object](/api/workspace/schemas/create)
|
||||
|
||||
* - [volume](#volumes) (<UC>)
|
||||
- ✓
|
||||
- [Volume object](/api/workspace/volumes/create)
|
||||
|
||||
.. gcp::
|
||||
|
||||
.. list-table::
|
||||
:header-rows: 1
|
||||
|
||||
* - Resource
|
||||
- Create support
|
||||
- Corresponding REST API object
|
||||
|
||||
* - [cluster](#clusters)
|
||||
- ✓
|
||||
- [Cluster object](/api/workspace/clusters/create)
|
||||
|
||||
* - [dashboard](#dashboards)
|
||||
-
|
||||
- [Dashboard object](/api/workspace/lakeview/create)
|
||||
|
||||
* - [experiment](#experiments)
|
||||
- ✓
|
||||
- [Experiment object](/api/workspace/experiments/createexperiment)
|
||||
|
||||
* - [job](#job)
|
||||
- ✓
|
||||
- [Job object](/api/workspace/jobs/create)
|
||||
|
||||
* - [model (legacy)](#models)
|
||||
- ✓
|
||||
- [Model (legacy) object](/api/workspace/modelregistry/createmodel)
|
||||
|
||||
* - [model_serving_endpoint](#model_serving_endpoints)
|
||||
- ✓
|
||||
- [Model serving endpoint object](/api/workspace/servingendpoints/create)
|
||||
|
||||
* - [pipeline](#pipelines)
|
||||
- ✓
|
||||
- [Pipeline object]](/api/workspace/pipelines/create)
|
||||
|
||||
* - [quality_monitor](#quality_monitors)
|
||||
- ✓
|
||||
- [Quality monitor object](/api/workspace/qualitymonitors/create)
|
||||
|
||||
* - [registered_model](#registered_models) (<UC>)
|
||||
- ✓
|
||||
- [Registered model object](/api/workspace/registeredmodels/create)
|
||||
|
||||
* - [schema](#schemas) (<UC>)
|
||||
- ✓
|
||||
- [Schema object](/api/workspace/schemas/create)
|
||||
|
||||
* - [volume](#volumes) (<UC>)
|
||||
- ✓
|
||||
- [Volume object](/api/workspace/volumes/create)
|
||||
|
|
|
@ -1,25 +1,25 @@
|
|||
github.com/databricks/cli/bundle/config.Artifact:
|
||||
"build":
|
||||
"description": |-
|
||||
An optional set of non-default build commands to run locally before deployment.
|
||||
An optional set of build commands to run locally before deployment.
|
||||
"executable":
|
||||
"description": |-
|
||||
The executable type. Valid values are `bash`, `sh`, and `cmd`.
|
||||
"files":
|
||||
"description": |-
|
||||
The source files for the artifact.
|
||||
The relative or absolute path to the built artifact files.
|
||||
"path":
|
||||
"description": |-
|
||||
The location where the built artifact will be saved.
|
||||
The local path of the directory for the artifact.
|
||||
"type":
|
||||
"description": |-
|
||||
Required. The type of the artifact.
|
||||
Required if the artifact is a Python wheel. The type of the artifact. Valid values are `whl` and `jar`.
|
||||
"markdown_description": |-
|
||||
Required. The type of the artifact. Valid values are `whl`.
|
||||
github.com/databricks/cli/bundle/config.ArtifactFile:
|
||||
"source":
|
||||
"description": |-
|
||||
Required. The path of the files used to build the artifact.
|
||||
Required. The artifact source file.
|
||||
github.com/databricks/cli/bundle/config.Bundle:
|
||||
"cluster_id":
|
||||
"description": |-
|
||||
|
@ -28,7 +28,7 @@ github.com/databricks/cli/bundle/config.Bundle:
|
|||
The ID of a cluster to use to run the bundle. See [_](/dev-tools/bundles/settings.md#cluster_id).
|
||||
"compute_id":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
Deprecated. The ID of the compute to use to run the bundle.
|
||||
"databricks_cli_version":
|
||||
"description": |-
|
||||
The Databricks CLI version to use for the bundle.
|
||||
|
@ -225,7 +225,7 @@ github.com/databricks/cli/bundle/config.Root:
|
|||
"description": |-
|
||||
Specifies a list of path globs that contain configuration files to include within the bundle.
|
||||
"markdown_description": |-
|
||||
Specifies a list of path globs that contain configuration files to include within the bundle. See [_](/dev-tools/bundles/settings.md#include)
|
||||
Specifies a list of path globs that contain configuration files to include within the bundle. See [_](/dev-tools/bundles/settings.md#include).
|
||||
"permissions":
|
||||
"description": |-
|
||||
Defines a permission for a specific entity.
|
||||
|
@ -414,57 +414,47 @@ github.com/databricks/cli/bundle/config/resources.Permission:
|
|||
"user_name":
|
||||
"description": |-
|
||||
The name of the user that has the permission set in level.
|
||||
github.com/databricks/cli/bundle/config/resources.Pipeline:
|
||||
"allow_duplicate_names":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
"dry_run":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
"run_as":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
github.com/databricks/cli/bundle/config/variable.Lookup:
|
||||
"alert":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the alert for which to retrieve an ID.
|
||||
"cluster":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the cluster for which to retrieve an ID.
|
||||
"cluster_policy":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the cluster_policy for which to retrieve an ID.
|
||||
"dashboard":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the dashboard for which to retrieve an ID.
|
||||
"instance_pool":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the instance_pool for which to retrieve an ID.
|
||||
"job":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the job for which to retrieve an ID.
|
||||
"metastore":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the metastore for which to retrieve an ID.
|
||||
"notification_destination":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the notification_destination for which to retrieve an ID.
|
||||
"pipeline":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the pipeline for which to retrieve an ID.
|
||||
"query":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the query for which to retrieve an ID.
|
||||
"service_principal":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the service_principal for which to retrieve an ID.
|
||||
"warehouse":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The name of the warehouse for which to retrieve an ID.
|
||||
github.com/databricks/cli/bundle/config/variable.TargetVariable:
|
||||
"default":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The default value for the variable.
|
||||
"description":
|
||||
"description": |-
|
||||
The description of the variable.
|
||||
|
@ -485,7 +475,7 @@ github.com/databricks/cli/bundle/config/variable.Variable:
|
|||
Defines a custom variable for the bundle. See [_](/dev-tools/bundles/settings.md#variables).
|
||||
"default":
|
||||
"description": |-
|
||||
PLACEHOLDER
|
||||
The default value for the variable.
|
||||
"description":
|
||||
"description": |-
|
||||
The description of the variable
|
||||
|
|
Loading…
Reference in New Issue