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

feat(bakery): add includeCRDs in Helm Bake request #4324

Merged
merged 2 commits into from
Nov 8, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ public class HelmBakeManifestRequest extends BakeManifestRequest {
@JsonProperty("rawOverrides")
private Boolean rawOverrides;

@JsonProperty("includeCRDs")
private Boolean includeCRDs;

@JsonProperty("helmChartFilePath")
private String helmChartFilePath;

Expand All @@ -59,6 +62,7 @@ public HelmBakeManifestRequest(
this.setNamespace(bakeManifestContext.getNamespace());
this.setInputArtifacts(inputArtifacts);
this.setRawOverrides(bakeManifestContext.getRawOverrides());
this.setIncludeCRDs(bakeManifestContext.getIncludeCRDs());
this.setHelmChartFilePath(bakeManifestContext.getHelmChartFilePath());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ public class BakeManifestContext {
private final String outputName;
private final String namespace;
private final Boolean rawOverrides;
private final Boolean includeCRDs;
@Nullable private final String kustomizeFilePath;
@Nullable private final String helmChartFilePath;
// There does not seem to be a way to auto-generate a constructor using our current version of
Expand All @@ -52,7 +53,8 @@ public BakeManifestContext(
@Nullable @JsonProperty("inputArtifact") CreateBakeManifestTask.InputArtifact inputArtifact,
@Nullable @JsonProperty("kustomizeFilePath") String kustomizeFilePath,
@Nullable @JsonProperty("helmChartFilePath") String helmChartFilePath,
@JsonProperty("rawOverrides") Boolean rawOverrides) {
@JsonProperty("rawOverrides") Boolean rawOverrides,
@JsonProperty("includeCRDs") Boolean includeCRDs) {
this.inputArtifacts = Optional.ofNullable(inputArtifacts).orElse(new ArrayList<>());
// Kustomize stage configs provide a single input artifact
if (this.inputArtifacts.isEmpty() && inputArtifact != null) {
Expand All @@ -67,5 +69,6 @@ public BakeManifestContext(
this.kustomizeFilePath = kustomizeFilePath;
this.helmChartFilePath = helmChartFilePath;
this.rawOverrides = rawOverrides;
this.includeCRDs = includeCRDs;
}
}