Skip to content

Commit

Permalink
Merge pull request #24 from Avarei/add-cache-dir
Browse files Browse the repository at this point in the history
Add cache dir
  • Loading branch information
Avarei committed Jul 5, 2024
2 parents 2e42033 + 924a159 commit 98be9dc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ generate: pkl-resolve pkl-resolve-hack

.PHONY: build-image
build-image:
docker build --build-arg -t runtime .
docker build -t runtime .
crossplane xpkg build -f package --embed-runtime-image=runtime -o .out/function-pkl.xpkg

.PHONY: push-image
Expand Down
2 changes: 2 additions & 0 deletions internal/function/fn.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ func (f *Function) RunFunction(ctx context.Context, req *fnv1beta1.RunFunctionRe
case "local":
evaluator, err = f.EvaluatorManager.NewProjectEvaluator(ctx, in.Spec.Local.ProjectDir,
pkl.PreconfiguredOptions,
pkl.WithDefaultCacheDir,
reader.WithCrossplane(&reader.CrossplaneReader{
ReaderScheme: "crossplane",
Request: &helper.CompositionRequest{
Expand All @@ -77,6 +78,7 @@ func (f *Function) RunFunction(ctx context.Context, req *fnv1beta1.RunFunctionRe
default:
evaluator, err = f.EvaluatorManager.NewEvaluator(ctx,
pkl.PreconfiguredOptions,
pkl.WithDefaultCacheDir,
reader.WithCrossplane(&reader.CrossplaneReader{
ReaderScheme: "crossplane",
Request: &helper.CompositionRequest{
Expand Down

0 comments on commit 98be9dc

Please sign in to comment.