Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Import_cluster_template module #197

Merged

Conversation

rsuplina
Copy link
Contributor

No description provided.

@rsuplina rsuplina requested a review from a team January 18, 2024 12:09
@wmudge wmudge added this to the Release 4.3.1 milestone Jan 24, 2024
@wmudge wmudge added the enhancement New feature or request label Jan 24, 2024

except FileNotFoundError:
self.cm_cluster_template_output = (f"Error: File '{self.template}' not found.")
self.file_not_found = True
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please call self.module.fail_json here rather than in line 180

plugins/modules/cm_import_cluster_template.py Outdated Show resolved Hide resolved
plugins/modules/cm_import_cluster_template.py Outdated Show resolved Hide resolved
plugins/modules/cm_import_cluster_template.py Outdated Show resolved Hide resolved

DOCUMENTATION = r"""
---
module: cm_import_cluster_template
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be simply cluster -- importing a cluster template is just one function of this module. The initial implementation can only include this functionality, but going forward, we should then add reconciliation and update logic. (This will be calls to PUT ​/clusters​/{clusterName}.)

Signed-off-by: rsuplina <[email protected]>
wmudge and others added 15 commits January 26, 2024 09:26
Add pytest resources.
Add unit tests for assemble_cluster_template module

Signed-off-by: Webster Mudge <[email protected]>
Signed-off-by: Webster Mudge <[email protected]>
Short-circuit merger for initial fragment.

Signed-off-by: Webster Mudge <[email protected]>
Add 'regex' alias.
Update API docs.

Signed-off-by: Webster Mudge <[email protected]>
Signed-off-by: Webster Mudge <[email protected]>
Relocate merge logic and update processing flow
@@ -50,22 +50,29 @@
type: bool
required: False
default: False
clusterName:
description:
- Name of Cloudera Manager Cluster
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just "Name of cluster"

@wmudge wmudge merged commit 4ff475c into cloudera-labs:devel Feb 29, 2024
4 checks passed
@wmudge wmudge modified the milestones: Release 4.3.1, Release 4.4.0 May 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request validated
Development

Successfully merging this pull request may close these issues.

2 participants