Skip to content

Commit

Permalink
Add more info in the docs about enums used in the resources (#6)
Browse files Browse the repository at this point in the history
* Add more info in the docs about enums used in the resources

* Add note on how to find which SC config fields to set
  • Loading branch information
stefannica authored Jan 24, 2025
1 parent a6e1834 commit 93471cb
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 10 deletions.
16 changes: 8 additions & 8 deletions docs/resources/service_connector.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ resource "zenml_service_connector" "gcp_connector" {
configuration = {
project_id = "my-gcp-project"
service_account_json = jsonencode({
"type": "service_account",
"type": "service-account",
"project_id": "my-gcp-project",
"private_key_id": "key-id",
"private_key": "-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n",
Expand All @@ -42,15 +42,15 @@ resource "zenml_service_connector" "gcp_connector" {
## Argument Reference

* `name` - (Required) The name of the service connector.
* `type` - (Required, Forces new resource) The type of the service connector. Valid values include: `aws`, `gcp`, `azure`, and others depending on your ZenML version.
* `type` - (Required, Forces new resource) The type of the service connector. Valid values include: `aws`, `gcp`, `azure`, and others depending on your ZenML version. You can run `zenml service-connector list-types` to get the list of available types or take a look at the [ZenML documentation](https://docs.zenml.io/how-to/infrastructure-deployment/auth-management/service-connectors-guide#explore-service-connector-types) for more information.
* `auth_method` - (Required, Forces new resource) The authentication method used by the connector. Valid values include:
* AWS: `iam-role`, `aws-access-keys`, `web-identity`
* GCP: `service-account`, `oauth2`, `workload-identity`
* Azure: `service-principal`, `managed-identity`
* Kubernetes: `kubeconfig`, `service-account`
* AWS: `iam-role`, `secret-key`, `implicit`, `sts-token`, `session-token` or `federation-token`. Run `zenml service-connector describe-type aws` or visit the [AWS Service Connector ZenML documentation page](https://docs.zenml.io/how-to/infrastructure-deployment/auth-management/aws-service-connector) for more information.
* GCP: `service-account`, `external-account`, `user-account`, `implicit`, `oauth2-token` or `impersonation`. Run `zenml service-connector describe-type gcp` or visit the [GCP Service Connector ZenML documentation page](https://docs.zenml.io/how-to/infrastructure-deployment/auth-management/gcp-service-connector) for more information.
* Azure: `service-principal`, `access-token` or `implicit`. Run `zenml service-connector describe-type azure` or visit the [Azure Service Connector ZenML documentation page](https://docs.zenml.io/how-to/infrastructure-deployment/auth-management/azure-service-connector) for more information.
* Kubernetes: `password` or `token`. Run `zenml service-connector describe-type kubernetes` or visit the [Kubernetes Service Connector ZenML documentation page](https://docs.zenml.io/how-to/infrastructure-deployment/auth-management/kubernetes-service-connector) for more information.
* `workspace` - (Optional) The workspace this connector belongs to. Defaults to "default". Forces new resource if changed.
* `resource_type` - (Optional) A resource type this connector can be used for (e.g., `s3-bucket`, `kubernetes-cluster`, `docker-registry`).
* `configuration` - (Required, Sensitive) A map of configuration key-value pairs for the connector.
* `resource_type` - (Optional) A resource type this connector can be used for (e.g., `s3-bucket`, `kubernetes-cluster`, `docker-registry`). To find out which resource types are supported by a connector, run `zenml service-connector describe-type <connector-type>`.
* `configuration` - (Required, Sensitive) A map of configuration key-value pairs for the connector. Every authentication method has its own set of required and optional configuration parameters. To find out which parameters are required and optional for a given authentication method, run `zenml service-connector describe-type <connector-type> -a <auth-method>` or visit the [Service Connector ZenML documentation page](https://docs.zenml.io/how-to/infrastructure-deployment/auth-management) for the connector type and authentication method for more information.
* `labels` - (Optional) A map of labels to associate with the connector.

## Attributes Reference
Expand Down
16 changes: 14 additions & 2 deletions docs/resources/stack_component.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,20 @@ resource "zenml_stack_component" "artifact_store" {
## Argument Reference

* `name` - (Required) The name of the stack component.
* `type` - (Required) The type of the stack component (e.g., "artifact_store", "orchestrator"). Must be one of the valid component types supported by ZenML.
* `flavor` - (Required) The flavor of the stack component (e.g., "local", "gcp", "aws").
* `type` - (Required) The type of the stack component. Must be one of the valid component types supported by ZenML:
* `alerter` - Alerter
* `annotator` - Annotator
* `artifact_store` - Artifact store
* `container_registry` - Container registry
* `data_validator` - Data validator
* `experiment_tracker` - Experiment tracker
* `feature_store` - Feature store
* `image_builder` - Image builder
* `model_deployer` - Model deployer
* `orchestrator` - Orchestrator
* `step_operator` - Step operator
* `model_registry` - Model registry
* `flavor` - (Required) The flavor of the stack component (e.g., "local", "gcp", "aws"). To find out which flavors are supported by a component type, run `zenml stack-component describe-type <component-type>` or visit the [Component Gallery section of the ZenML documentation](https://docs.zenml.io/stack-components/component-guide) for more information.
* `workspace` - (Required, Forces new resource) The name of the workspace this component belongs to.
* `configuration` - (Optional, Sensitive) A map of configuration key-value pairs for the component.
* `connector_id` - (Optional) The ID of the service connector to use with this component. Must be specified together with `connector_resource_id`.
Expand Down

0 comments on commit 93471cb

Please sign in to comment.