Skip to content

Commit

Permalink
chore: Add Path parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
shil committed Aug 5, 2024
1 parent 518908b commit 45943c6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 2 additions & 0 deletions api/v1alpha1/nimcache_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ type GITSource struct {
PullSecret string `json:"pullSecret,omitempty"`
// Model spec for caching
Model ModelSpec `json:"model,omitempty"`
// Path
Path string `json:"path"`
}

// ModelSpec is the spec required to cache selected models
Expand Down
6 changes: 5 additions & 1 deletion internal/controller/nimcache_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,11 @@ var _ = Describe("NIMCache Controller", func() {
}, time.Second*10).Should(Succeed())

nimCache.Spec.Source.NGC = nil
nimCache.Spec.Source.GIT = &appsv1alpha1.GITSource{ModelPuller: "nvcr.io/nim:test-git-puller", PullSecret: "my-secret"}
nimCache.Spec.Source.GIT = &appsv1alpha1.GITSource{
ModelPuller: "nvcr.io/nim:test-git-puller",
PullSecret: "my-secret",
Path: "https://github.com/modelx",
}

err = client.Delete(context.TODO(), job)
Expect(err).ToNot(HaveOccurred())
Expand Down

0 comments on commit 45943c6

Please sign in to comment.