# How can I sign Starlark or Jsonnet configs?

**URL:** <https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646>\
**Category:** Drone Support\
**Created:** [September 10, 2020, 10:57am UTC](https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646 "2020-09-10T10:57:21Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![aknudsen](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/aknudsen/32/5067_2.png) [@aknudsen](https://drone.discourse.group/u/aknudsen)\
**Post date:** [September 10, 2020, 10:57am UTC](https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646/1 "2020-09-10T10:57:21Z")

</div>

I need to sign a .drone.jsonnet configuration file, and potentially a Starlark config also (we are currently using both, although might standardize on the former). How can I do this? When I tried, it looked as if the server tried to interpret the Jsonnet code as YAML, and failed to parse.

Update: I also tried the following:

1. Convert Jsonnet to YAML
2. Sign YAML
3. Put signature in Jsonnet code

That approach doesn’t work either, the server doesn’t accept the signature.

---

<div class="post-metadata">

**Author:** ![bradrydzewski](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/bradrydzewski/32/3513_2.png) [@bradrydzewski](https://drone.discourse.group/u/bradrydzewski)\
**Post date:** [September 10, 2020, 2:54pm UTC](https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646/2 "2020-09-10T14:54:17Z")

</div>

the system does not currently support signing non-yaml files

---

<div class="post-metadata">

**Author:** ![aknudsen](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/aknudsen/32/5067_2.png) [@aknudsen](https://drone.discourse.group/u/aknudsen)\
**Post date:** [September 10, 2020, 3:10pm UTC](https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646/3 "2020-09-10T15:10:30Z")

</div>

OK thanks for clarifying that. Can we expect this to be implemented anytime soon, or might it eventually be something we could provide a patch for ourselves?

---

<div class="post-metadata">

**Author:** ![bradrydzewski](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/bradrydzewski/32/3513_2.png) [@bradrydzewski](https://drone.discourse.group/u/bradrydzewski)\
**Post date:** [September 10, 2020, 4:10pm UTC](https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646/4 "2020-09-10T16:10:02Z")

</div>

For non-yaml files this would need to be handled differently. We would need to store the signature in a separate file. For example, if you had a `drone.jsonnet` file we would store the signature in separate a `drone.jsonnet.sig` file. This is not something that is on our current roadmap, but we can send this over to our product team for consideration and prioritization.

---

<div class="post-metadata">

**Author:** ![aknudsen](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/aknudsen/32/5067_2.png) [@aknudsen](https://drone.discourse.group/u/aknudsen)\
**Post date:** [September 10, 2020, 4:55pm UTC](https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646/5 "2020-09-10T16:55:54Z")

</div>

If you could try to prioritize and implement this, it would be fantastic. We plan to use Jsonnet heavily at Grafana Labs to configure Drone and we might need signing, so this would be very helpful to us.

---

<div class="post-metadata">

**Author:** ![m-ueberall](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/m-ueberall/32/6713_2.png) [@m-ueberall](https://drone.discourse.group/u/m-ueberall)\
**Post date:** [November 5, 2021, 6:34pm UTC](https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646/6 "2021-11-05T18:34:35Z")

</div>

I second this with respect to `.drone.star`. 😃

---

<div class="post-metadata">

**Author:** ![alexander-LBC](https://yyz1.discourse-cdn.com/flex003/user_avatar/drone.discourse.group/alexander-lbc/32/4279_2.png) [@alexander-LBC](https://drone.discourse.group/u/alexander-LBC)\
**Post date:** [November 24, 2021, 9:44am UTC](https://drone.discourse.group/t/how-can-i-sign-starlark-or-jsonnet-configs/3646/7 "2021-11-24T09:44:19Z")

</div>

We also depend heavily on starlark and it’d be great to see this implemented
