diff --git a/reposync_scheduler.nomad b/reposync_scheduler.nomad
index 22798c02c4c6dd706bbd6e93a7b032fb8bd006bb..272f3e7d092c30b641469a707918fd7f13023e11 100644
--- a/reposync_scheduler.nomad
+++ b/reposync_scheduler.nomad
@@ -30,7 +30,7 @@ job "reposync_scheduler" {
       }
       template {
         data        = <<EOF
-          NOMAD_TOKEN="{{ with secret "nomad/creds/write" }}{{.Data}}{{end}}"
+          NOMAD_TOKEN="{{ with secret "nomad/creds/write" }}{{.Data.secret_id}}{{end}}"
         EOF
         destination = "secrets/nomad_token.env"
         env         = true