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

Move generated promo step type definitions to pkg #3293

Open
jessesuen opened this issue Jan 15, 2025 · 0 comments
Open

Move generated promo step type definitions to pkg #3293

jessesuen opened this issue Jan 15, 2025 · 0 comments

Comments

@jessesuen
Copy link
Member

Proposed Feature

Currently the golang versions of native promotion steps are auto generated to the internal/directives directory:
https://github.com/akuity/kargo/blob/main/internal/directives/zz_config_types.go

For example:

type GitCloneConfig struct {
	// The commits, branches, or tags to check out from the repository and the paths where they
	// should be checked out. At least one must be specified.
	Checkout []Checkout `json:"checkout"`
	// Indicates whether to skip TLS verification when cloning the repository. Default is false.
	InsecureSkipTLSVerify bool `json:"insecureSkipTLSVerify,omitempty"`
	// The URL of a remote Git repository to clone. Required.
	RepoURL string `json:"repoURL"`
}

We should move these outside of internal into pkg so they can be publically consumed.

Motivation

Anyone who is programmatically construct a Kargo object from its CRD types, or the reverse: unmarshalling them into an golang object, do not have access to these types since they are in the internal directory.

Suggested Implementation

Change the path where these are generated and the corresponding import statements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants