# Admin bootstrap fails

**URL:** <https://openziti.discourse.group/t/admin-bootstrap-fails/1526>\
**Category:** zrok\
**Created:** [August 18, 2023, 1:11pm UTC](https://openziti.discourse.group/t/admin-bootstrap-fails/1526 "2023-08-18T13:11:44Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Danieleb](https://avatars.discourse-cdn.com/v4/letter/d/9f8e36/32.png) [@Danieleb](https://openziti.discourse.group/u/Danieleb)\
**Post date:** [August 18, 2023, 1:11pm UTC](https://openziti.discourse.group/t/admin-bootstrap-fails/1526/1 "2023-08-18T13:11:44Z")

</div>

Hi everyone,

After having setup a fresh install of Openziti , I thought I would givet Zrok a bash but have hit a wall.

I have followed the self hosting guide on

[Self-Hosting Guide for Linux | Zrok](https://docs.zrok.io/docs/guides/self-hosting/self_hosting_guide/)

but when running zrok admin bootstrap /etc/ctrl.yml , I see that a new identity public gets added

 ![image](https://global.discourse-cdn.com/free1/uploads/netfoundry/original/2X/b/bdcdad40f946637faf6b39b774264203d7136b66.png)

however the script seems to fail.  
.  
[0.007] INFO zrok/controller/store.Open: database connected  
[0.058] INFO zrok/controller/store.(\*Store).migrate: applied 13 migrations  
[0.058] INFO zrok/controller.Bootstrap: connecting to the ziti edge management api  
[0.559] INFO zrok/controller.Bootstrap: creating identity for public frontend access  
panic: error enrolling ‘public’ identity: json: cannot unmarshal array into Go struct field EnrollmentClaims.aud of type string  
goroutine 1 [running]:  
[github.com/openziti/zrok/controller.Bootstrap](http://github.com/openziti/zrok/controller.Bootstrap)(0x0, 0xc000000004?)  
/home/runner/work/zrok/zrok/controller/bootstrap.go:53 +0x61f  
main.(\*adminBootstrap).run(0xc0004f4070, 0x0?, {0xc0004f4ef0?, 0x0?, 0x0?})  
/home/runner/work/zrok/zrok/cmd/zrok/adminBootstrap.go:39 +0xa5  
[github.com/spf13/cobra.(\*Command).execute](http://github.com/spf13/cobra.(*Command).execute)(0xc000004c00, {0xc0004f4ec0, 0x1, 0x1})  
/home/runner/go/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:944 +0x847  
[github.com/spf13/cobra.(\*Command).ExecuteC(0x3189940)](http://github.com/spf13/cobra.(*Command).ExecuteC(0x3189940))  
/home/runner/go/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:1068 +0x3bd  
[github.com/spf13/cobra.(\*Command).Execute(...)](http://github.com/spf13/cobra.(*Command).Execute(...))  
/home/runner/go/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:992  
main.main()  
/home/runner/work/zrok/zrok/cmd/zrok/main.go:98 +0x25

any ideas of what I may be doing wrong?

thanks

---

<div class="post-metadata">

**Author:** ![michael.quigley](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/michael.quigley/32/1123_2.png) [@michael.quigley](https://openziti.discourse.group/u/michael.quigley)\
**Post date:** [August 18, 2023, 4:04pm UTC](https://openziti.discourse.group/t/admin-bootstrap-fails/1526/2 "2023-08-18T16:04:02Z")

</div>

This is actually a bug in the current release. It looks like an incompatibility between the current OpenZiti version, and the OpenZiti SDK version used in `zrok`.

I’m not exactly sure which version of OpenZiti breaks `zrok`… so I’m not sure which version you could fall back to.

And just updating the OpenZiti SDK results in a different issue. So it might take me a couple of days to work out what’s going on.

Created an issue for it, and it’s on our radar:

> <https://github.com/openziti/zrok/issues/389>
>
> The bootstrap (and possibly other functions) are broken with the latest OpenZiti… \`v0.30.0\`.
> 
> \`\`\`
> \[0.040\] INFO zrok/controller.Bootstrap: creating identity for controller ziti access
> panic: error enrolling 'ctrl' identity: json: cannot unmarshal array into Go struct field EnrollmentClaims.aud of type string
> 
> goroutine 1 \[running\]:
> github.com/openziti/zrok/controller.Bootstrap(0x0, 0x0, 0xc000000004?)
> /home/runner/work/zrok/zrok/controller/bootstrap.go:48 +0x75f
> main.(\*adminBootstrap).run(0xc00012d160, 0x0?, {0xc00012db20?, 0x0?, 0x0?})
> /home/runner/work/zrok/zrok/cmd/zrok/adminBootstrap.go:41 +0xa7
> github.com/spf13/cobra.(\*Command).execute(0xc000004f00, {0xc00012daf0, 0x1, 0x1})
> /home/runner/go/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:944 +0x847
> github.com/spf13/cobra.(\*Command).ExecuteC(0x317e940)
> /home/runner/go/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:1068 +0x3bd
> github.com/spf13/cobra.(\*Command).Execute(...)
> /home/runner/go/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:992
> main.main()
> /home/runner/work/zrok/zrok/cmd/zrok/main.go:98 +0x25
> \`\`\`
> 
> Updating to the latest \`sdk-golang\` results in a different error:
> 
> \`\`\`
> \[0.034\] INFO zrok/controller.Bootstrap: creating identity for public frontend access
> panic: error creating 'public' identity: \[POST /identities\]\[400\] createIdentityBadRequest &{Error:0xc000524540 Meta:0xc00034c080}
> 
> goroutine 1 \[running\]:
> github.com/openziti/zrok/controller.Bootstrap(0x0, 0xc000000004?)
> /home/michael/Repos/nf/zrok/controller/bootstrap.go:53 +0x5f9
> main.(\*adminBootstrap).run(0xc000654830, 0x0?, {0xc000655520?, 0x0?, 0x0?})
> /home/michael/Repos/nf/zrok/cmd/zrok/adminBootstrap.go:39 +0xa5
> github.com/spf13/cobra.(\*Command).execute(0xc00036c900, {0xc0006554f0, 0x1, 0x1})
> /home/michael/local/zrok/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:944 +0x863
> github.com/spf13/cobra.(\*Command).ExecuteC(0x44d9c00)
> /home/michael/local/zrok/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:1068 +0x3a5
> github.com/spf13/cobra.(\*Command).Execute(...)
> /home/michael/local/zrok/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:992
> main.main()
> /home/michael/Repos/nf/zrok/cmd/zrok/main.go:98 +0x1a
> \`\`\`

---

<div class="post-metadata">

**Author:** ![michael.quigley](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/michael.quigley/32/1123_2.png) [@michael.quigley](https://openziti.discourse.group/u/michael.quigley)\
**Post date:** [August 18, 2023, 9:02pm UTC](https://openziti.discourse.group/t/admin-bootstrap-fails/1526/3 "2023-08-18T21:02:12Z")

</div>

`zrok v0.4.5` has been released today. This release corrects this issue.

> **[Release v0.4.5 · openziti/zrok](https://github.com/openziti/zrok/releases/tag/v0.4.5)**
>
> FEATURE: New health check endpoint (/health), which verifies that the underlying SQL store and metrics repository (InfluxDB, if configured) are operating correctly (#372)
> FIX: zrok admin bootstrap ...

---

<div class="post-metadata">

**Author:** ![Danieleb](https://avatars.discourse-cdn.com/v4/letter/d/9f8e36/32.png) [@Danieleb](https://openziti.discourse.group/u/Danieleb)\
**Post date:** [August 21, 2023, 7:26am UTC](https://openziti.discourse.group/t/admin-bootstrap-fails/1526/5 "2023-08-21T07:26:22Z")

</div>

Thanks Michael 🙂 will give zrok v0.4.5 a shot
