Skip to content

Commit

Permalink
create pod template metadata if it doesn't exist
Browse files Browse the repository at this point in the history
  • Loading branch information
drmorr0 committed Oct 28, 2023
1 parent 770c3e2 commit 29414db
Show file tree
Hide file tree
Showing 3 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
@@ -1,6 +1,6 @@
GO_ARTIFACTS=sk-cloudprov sk-vnode
RUST_ARTIFACTS=sk-ctrl sk-driver sk-tracer
ARTIFACTS ?= $(GO_ARTIFACTS) $(RUST_ARTIFACTS) skctl
ARTIFACTS ?= $(GO_ARTIFACTS) $(RUST_ARTIFACTS)

COVERAGE_DIR=$(BUILD_DIR)/coverage
GO_COVER_FILE=$(COVERAGE_DIR)/go-coverage.txt
Expand Down
1 change: 1 addition & 0 deletions driver/runner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ fn build_virtual_obj(
vobj.metadata.namespace = Some(virtual_ns.into());
klabel_insert!(vobj, VIRTUAL_LABEL_KEY => "true");

jsonutils::patch_ext::add(pod_spec_template_path, "metadata", &json!({}), &mut vobj.data, false)?;
jsonutils::patch_ext::add(
&format!("{}/metadata", pod_spec_template_path),
"annotations",
Expand Down
1 change: 1 addition & 0 deletions k8s/sk_tracer.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
podSpecTemplatePath: /spec/template
batch.volcano.sh/v1alpha1.Job:
podSpecTemplatePath: /spec/tasks/*/template
trackLifecycle: true
"""
CONFIGMAP_NAME = "tracer-config"

Expand Down

0 comments on commit 29414db

Please sign in to comment.