Skip to content

feat: more type to defined playbook file#2522

Merged
pixiake merged 1 commit intokubesphere:feature-gitopsfrom
redscholar:feature
Apr 3, 2025
Merged

feat: more type to defined playbook file#2522
pixiake merged 1 commit intokubesphere:feature-gitopsfrom
redscholar:feature

Conversation

@redscholar
Copy link
Copy Markdown
Contributor

@redscholar redscholar commented Apr 1, 2025

What type of PR is this?

/kind feature

What this PR does / why we need it:

more type to defined playbooks file:

// PathFormatImportPlaybook defines the directory structure for importing playbooks
	PathFormatImportPlaybook = `
|-- base-playbook.yaml
|-- [import_playbook]

|-- playbook.yaml
|-- playbooks/
|   |-- [import_playbook]

|-- [projectDir]
|-- playbooks/
|   |-- [import_playbook]
`

	// PathFormatVarsFile defines the directory structure for vars files
	PathFormatVarsFile = `
|-- base-playbook.yaml
|-- [VarsFile]	
`
	// PathFormatRole defines the directory structure for roles
	PathFormatRole = `
|-- playbooks/
|   |-- playbook.yaml
|-- roles/
|   |-- [role]/

|-- playbook.yaml
|-- roles/
|   |-- [role]/	

|-- [projectDir]
|-- roles/
|   |-- [role]/
`

	// PathFormatRoleTask defines the directory structure for role tasks
	PathFormatRoleTask = `
|-- baseRole/
|   |-- tasks/
|   |   |-- main.yaml

|-- baseRole/
|   |-- tasks/
|   |   |-- main.yml
`

	// PathFormatIncludeTask defines the directory structure for included tasks
	PathFormatIncludeTask = `
|-- [source_task]
|   |-- tasks/
|   |   |-- [include_tasks]

|-- [source_task]
|   |-- [include_tasks]

|-- [top_source_task]
|   |-- tasks/
|   |   |-- [include_tasks]

|-- [top_source_task]
|   |-- [include_tasks]

Which issue(s) this PR fixes:

Fixes #

Special notes for reviewers:

Does this PR introduced a user-facing change?

more type to defined playbook file

Additional documentation, usage docs, etc.:


@kubesphere-prow kubesphere-prow bot added kind/feature Categorizes issue or PR as related to a new feature. do-not-merge/release-note-label-needed labels Apr 1, 2025
@kubesphere-prow
Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: redscholar

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubesphere-prow kubesphere-prow bot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Apr 1, 2025
@redscholar redscholar force-pushed the feature branch 4 times, most recently from 6ab944c to cd60e95 Compare April 3, 2025 07:15
Signed-off-by: joyceliu <joyceliu@yunify.com>
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Apr 3, 2025

Quality Gate Failed Quality Gate failed

Failed conditions
20.4% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

@pixiake pixiake merged commit 2c19021 into kubesphere:feature-gitops Apr 3, 2025
5 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/feature Categorizes issue or PR as related to a new feature. release-note size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants