# Balena container registry not working for browser-aarch64

**URL:** <https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363>\
**Category:** balenaHub\
**Created:** [September 14, 2024, 9:33pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363 "2024-09-14T21:33:51Z")\
**Posts on this page:** 19\
**Page:** 1

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 14, 2024, 9:33pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/1 "2024-09-14T21:33:51Z")

</div>

Balena browser-aarch64 block fails to download… [balenaHub - IoT embedded device apps, edge computing resources, and developer tools](https://hub.balena.io/blocks/1916869/browser-aarch64)

 ![image](https://global.discourse-cdn.com/balena/original/2X/7/70f20d8cd1077834e934fed95302c0707f987fb8.jpeg)

Is there something wrong with the container registry?

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 14, 2024, 9:49pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/2 "2024-09-14T21:49:02Z")

</div>

Also happens with other versions such as 2.7.0

 ![Screenshot_20240914_224746_Chrome](https://global.discourse-cdn.com/balena/original/2X/e/ebbb1e602d871bb0001a0540a434d429298e2a48.jpeg)

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 14, 2024, 10:12pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/3 "2024-09-14T22:12:06Z")

</div>

Could this be the same issue as described here?

> <https://github.com/balena-labs-projects/xserver/pull/25>
>
> This is used as a block, which means it doesn't need a docker-compose file. The …docker-compose file is useful as an example, but when it deploys it deploys from the docker-compose.yml file, which prevents the block from pulling effectively. 
> 
> See: https://github.com/balena-labs-projects/xserver/issues/23

> [@xserver image: Pull Access Denied](https://forums.balena.io/t/xserver-image-pull-access-denied/366366):
>
> I tried to change the xserver service in my Balena project from balenablocks to balenalabs. Is it correct that balenalabs is newer than balenablocks ? Or which one do you recommend ? The following error occurs when trying to go from balenablocks to balenalabs version of xserver: Before, I had the following inside the docker-compose.yml File: xserver: image: balenablocks/xserver restart: always privileged: true labels: io.balena.features.dbus: "1" …

---

<div class="post-metadata">

**Author:** ![chris021](https://avatars.discourse-cdn.com/v4/letter/c/58f4c7/32.png) [@chris021](https://forums.balena.io/u/chris021)\
**Post date:** [September 15, 2024, 9:15am UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/4 "2024-09-15T09:15:47Z")

</div>

I think something is broken on the registry side. Hopefully the Balena team will sort it after the weekend. I’ve had lots of issues with images coming from bh.cr the last few days stumpd me for a bit… I see your running [balena-ads-b]. you can comment out the kiosk and everything else will build fine.

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 15, 2024, 1:22pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/5 "2024-09-15T13:22:14Z")

</div>

Yeah it’s not me that’s using it but I’m helping maintain balena-ads-b and it’s causing builds to fall.

Basically balena builder is failing to properly pass the ARG in the FROM field to pull the image from bh.cr for the build.

More info in this comment here…

> <https://github.com/ketilmo/balena-ads-b/issues/160#issuecomment-2351199867>
>
> I’m using the blue button to update my release but it fails on kiosk with the fo…llowing error. 
> 
> !\[IMG\_0554\](https://github.com/user-attachments/assets/0a720e6d-7634-424c-b9bb-1f79f0cf5876)

We have a workaround but it seems that the parsing of the Dockerfile is not following the correct logic for how Dockerfile is supposed to work with ARGs allowed before the first FROM and allowed to be referenced therein.

---

<div class="post-metadata">

**Author:** ![klutchell](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/klutchell/32/861_2.png) [@klutchell](https://forums.balena.io/u/klutchell)\
**Post date:** [September 16, 2024, 3:35pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/6 "2024-09-16T15:35:11Z")

</div>

Hey @shawaj , thanks for raising this issue! I was able to reproduce the following error on our cloud builders (per the linked Github issue).

```Dockerfile
ARG BROWSER_VERSION=2.9.0
FROM bh.cr/balenalabs/browser-%%BALENA_ARCH%%/$BROWSER_VERSION AS base

```

```auto
[main] Step 1/2 : ARG BROWSER_VERSION=2.9.0
[main] Step 2/2 : FROM bh.cr/balenalabs/browser-aarch64/$BROWSER_VERSION AS base
[main] pull access denied for bh.cr/balenalabs/browser-aarch64/2.9.0, repository does not exist or may require 'docker login': denied: requested access to the resource is denied

```

but this works

```Dockerfile
ARG BROWSER_VERSION=2.9.0
FROM bh.cr/balenalabs/browser-%%BALENA_ARCH%%/2.9.0 AS base

```

```auto
[main] Step 1/2 : ARG BROWSER_VERSION=2.9.0
[main] Step 2/2 : FROM bh.cr/balenalabs/browser-aarch64/2.9.0 AS base
[main] ---> 78d9a6af0336
[main] Successfully built 78d9a6af0336

```

I’m going to see if I can sort out when this was introduced and how to resolve it.

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 16, 2024, 4:58pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/7 "2024-09-16T16:58:00Z")

</div>

Much appreciated @klutchell 🙂

Yeah it’s a really weird one because it clearly is parsing the ARG for the error message, but not for the actual pulling of the image!

---

<div class="post-metadata">

**Author:** ![klutchell](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/klutchell/32/861_2.png) [@klutchell](https://forums.balena.io/u/klutchell)\
**Post date:** [September 16, 2024, 6:22pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/8 "2024-09-16T18:22:15Z")

</div>

@shawaj do you have an approximate date when this used to work?

I see that some aspects of automatic authentication do not work when ARGS are included in the image tag, but that shouldn’t apply to public blocks such as this and it seems that bit of behaviour has not changed.

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 16, 2024, 10:28pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/9 "2024-09-16T22:28:06Z")

</div>

I don’t know if it used to work or not in this particular scenario with Balena. Just that it works in a Dockerfile with docker.

For example it’s even used by the browser block in its own Dockerfile:

> <https://github.com/balena-io-experimental/browser/blob/f9902c56f8d2eddd034b45cc7c2de751ce9b611c/Dockerfile.template#L3>

In balena-ads-b we only just recently changed to this particular logic to get renovate bot to work in the repo. But were surprised to see it not work.

---

<div class="post-metadata">

**Author:** ![klutchell](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/klutchell/32/861_2.png) [@klutchell](https://forums.balena.io/u/klutchell)\
**Post date:** [September 16, 2024, 10:44pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/10 "2024-09-16T22:44:51Z")

</div>

The example Dockerfile you shared in your last comment is pulling from Dockerhub, and from what I can tell this issue only affects the use of ARGS in the image name when it is coming from `bh.cr/`. Anything from Dockerhub or other registries should be able to resolve just fine with ARGS in the name.

Can you confirm that is what you are seeing as well?

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 16, 2024, 11:13pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/11 "2024-09-16T23:13:16Z")

</div>

Oh I haven’t tried it with any other registry as we need to get it from bh.cr I?

Or are you saying the browser-aarch64 package is also available from DockerHub?

---

<div class="post-metadata">

**Author:** ![klutchell](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/klutchell/32/861_2.png) [@klutchell](https://forums.balena.io/u/klutchell)\
**Post date:** [September 16, 2024, 11:46pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/12 "2024-09-16T23:46:12Z")

</div>

Oh I just meant any other image that IS available on Dockerhub for testing. Don’t worry if you haven’t tried. I tried using ARGS with images from Dockerhub and Github Container Registry and had no issues, so it only seems to impact bh.cr.

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 17, 2024, 1:27am UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/13 "2024-09-17T01:27:07Z")

</div>

Strange! Is that expected behaviour for bh.cr?

---

<div class="post-metadata">

**Author:** ![klutchell](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/klutchell/32/861_2.png) [@klutchell](https://forums.balena.io/u/klutchell)\
**Post date:** [September 17, 2024, 10:53pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/14 "2024-09-17T22:53:11Z")

</div>

@shawaj ARGS in the image name should be correctly supported by the builder now. Can you give it another try?

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 18, 2024, 12:11am UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/15 "2024-09-18T00:11:19Z")

</div>

All working now, thanks @klutchell - fantastic support from balena as always 🙂

P.S. If you have a minute to look at this as well it would be much appreciated… [balena wifi-connect not working correctly](https://forums.balena.io/t/balena-wifi-connect-not-working-correctly/371182)

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 20, 2024, 6:18pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/16 "2024-09-20T18:18:14Z")

</div>

@klutchell this seems to be broken again now…

```auto
Error: Some services failed to build:
Error: Service: kiosk
Error: Error: pull access denied for bh.cr/balenalabs/browser-aarch64/2.9.0, repository does not exist or may require 'docker login': denied: requested access to the resource is denied

```

From run here - [Merge pull request #138 from Teko012/add/osupdate · ketilmo/balena-ads-b@385e91f · GitHub](https://github.com/ketilmo/balena-ads-b/actions/runs/10964193518/job/30447435026)

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 20, 2024, 6:24pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/17 "2024-09-20T18:24:20Z")

</div>

weirdly - I ran it from github two more times and on it was “third time lucky” - so it seems to maybe be a bit inconsistent/temperamental.

So a bit strange.

---

<div class="post-metadata">

**Author:** ![klutchell](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/klutchell/32/861_2.png) [@klutchell](https://forums.balena.io/u/klutchell)\
**Post date:** [September 20, 2024, 6:39pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/18 "2024-09-20T18:39:32Z")

</div>

Interesting…

My best guess at this point is that something got cached when the first pull failed due to network issues.

```auto
Error: Error: Get "https://registry-proxy.balena-cloud.com/v2/balenalabs/browser-aarch64/2.9.0/manifests/latest": Get "https://api.balena-cloud.com/auth/v1/token?scope=repository%3Abalenalabs%2Fbrowser-aarch64%2F2.9.0%3Apull&service=registry2.balena-cloud.com": net/http: request canceled (Client.Timeout exceeded while awaiting headers)

```

You can see the request to get a token from our API timed out for whatever reason. And since it’s the API that caches the access requests, it might have worked after a 15 minute timeout for cache expiry, or even just hitting a different API pod by chance.

---

<div class="post-metadata">

**Author:** ![shawaj](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/shawaj/32/8203_2.png) [@shawaj](https://forums.balena.io/u/shawaj)\
**Post date:** [September 21, 2024, 4:18pm UTC](https://forums.balena.io/t/balena-container-registry-not-working-for-browser-aarch64/371363/19 "2024-09-21T16:18:14Z")

</div>

Ah ok, that makes sense.

Will keep an eye on it and report back if we see it again. Maybe we were just unlucky that time!
