In your Nerves system’s mix.exs, look in the :artifact_sites. For private repositories, you need to use :github_api rather than :github_release. The site spec should look something like:
Hopefully you’ll see the line in the mix.exs, but let me know if you need more details.
Also, your timing is pretty good, since I just ran into this as well when converting a public repo to private and forgetting about the site update.
If you don’t mind switching your :nerves dependency to point to the main branch on GitHub, you can try out my recent changes that improve the error message and fix some issues in that area. In fact, if you’re ok with try out some new code, I’d be curious if my recent updates fix your issue or would have helped you resolve it on your own.
I tried this, but it use HTTP to pull the package, however we use SSH. So i would like to fetch it using SSH it self.
Let me tell you what I’m trying to do doing. We used nerves_system_bbb and created another private repos with some customization. Our nerves app should pull the tar.gz from this repo, but it failed
Then i created public repo i still see the same issue
I used the method you mentioned here i got this message
Missing token
For private releases, you must authenticate the request to fetch release assets.
You can do this in a few ways:
\* export or set GITHUB_TOKEN=<your-token>
\* set \`token: <get-token-function>\` for this GitHub repository in your Nerves system mix.exs
I don’t think you have a choice with GitHub. I’m pretty sure HTTPS is the only option for downloading releases artifacts. At least, I couldn’t find any information about using SSH except for git access, and release artifacts aren’t stored in git.
If you know a way for using SSH, you’re welcome to file an issue with a pointer to the documentation. The code for downloading archives isn’t that large, and you could probably prototype something that shells out to commandline ssh as a proof of concept.