Skip to content

Commit

Permalink
feat: add cone option to content.git / fix: reduce size of CRDs (#309)
Browse files Browse the repository at this point in the history
* feat: add `cone` option to content.git
* fix: reduce size of CRDs
  • Loading branch information
rangoo94 authored Dec 19, 2024
1 parent 0330347 commit 6a33aef
Show file tree
Hide file tree
Showing 5 changed files with 115 additions and 2,769 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ manifests-create: controller-gen ## Generate WebhookConfiguration, ClusterRole a

manifests-clean: yq
@for file in testworkflows.testkube.io_testworkflows.yaml testworkflows.testkube.io_testworkflowtemplates.yaml testworkflows.testkube.io_testworkflowexecutions.yaml; do \
for key in securityContext volumes dnsPolicy affinity tolerations hostAliases dnsConfig topologySpreadConstraints schedulingGates resourceClaims volumeMounts fieldRef resourceFieldRef configMapKeyRef secretKeyRef; do \
for key in securityContext volumes dnsPolicy affinity tolerations hostAliases dnsConfig topologySpreadConstraints schedulingGates resourceClaims volumeMounts fieldRef resourceFieldRef configMapKeyRef secretKeyRef pvcs matchExpressions matchLabels env envFrom readinessProbe; do \
yq --no-colors -i "del(.. | select(has(\"$$key\")).$$key | .. | select(has(\"description\")).description)" "config/crd/bases/$$file"; \
done; \
yq --no-colors -i \
Expand Down
2 changes: 2 additions & 0 deletions api/testworkflows/v1/content_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ type ContentGit struct {
AuthType testsv3.GitAuthType `json:"authType,omitempty" expr:"template"`
// where to mount the fetched repository contents (defaults to "repo" directory in the data volume)
MountPath string `json:"mountPath,omitempty" expr:"template"`
// enable cone mode for sparse checkout with paths
Cone bool `json:"cone,omitempty" expr:"ignore"`
// paths to fetch for the sparse checkout
Paths []string `json:"paths,omitempty" expr:"template"`
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,7 @@ spec:
description: test workflow execution id
type: string
executionPath:
description: all test workflow execution ids starting
from the root
description: all test workflow execution ids starting from the root
type: string
name:
description: actor name
Expand Down Expand Up @@ -103,7 +102,7 @@ spec:
- internal
type: string
required:
- type
- type
type: object
required:
- actor
Expand Down Expand Up @@ -365,14 +364,13 @@ spec:
description: test workflow execution id
type: string
executionPath:
description: all test workflow execution ids starting
from the root
description: all test workflow execution ids starting from the root
type: string
name:
description: actor name
type: string
type:
description: supported actors for test workflow running context'
description: supported actors for test workflow running context
enum:
- cron
- testtrigger
Expand Down
Loading

0 comments on commit 6a33aef

Please sign in to comment.