# Raspberry pi 3 application incompatible with raspberry pi 0 application

**URL:** <https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874>\
**Category:** Product support\
**Tags:** raspberrypi3\
**Created:** [January 3, 2019, 1:32am UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874 "2019-01-03T01:32:43Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![bathtubed](https://avatars.discourse-cdn.com/v4/letter/b/ba9def/32.png) [@bathtubed](https://forums.balena.io/u/bathtubed)\
**Post date:** [January 3, 2019, 1:32am UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874/1 "2019-01-03T01:32:43Z")

</div>

So I have a Pi 3 B+ and a Pi 0 w. The intention was to develop my application in local development mode on my Pi 3, then move over the hat to the Pi 0 and install the application in normal production mode on the Pi 0 w.

I’ve discovered that the devices are not considered compatible in the same application, however.

What is the reason for this, and what is the recommended way of implementing a scheme like this?

Is making two applications and pushing to both the only solution?

---

<div class="post-metadata">

**Author:** ![hahaha](https://avatars.discourse-cdn.com/v4/letter/h/87869e/32.png) [@hahaha](https://forums.balena.io/u/hahaha)\
**Post date:** [January 3, 2019, 11:21pm UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874/4 "2019-01-03T23:21:01Z")

</div>

Hi!

I think the reason is that starting from Raspi 2 onwards there is another ARM CPU, effectively making it a completely different compilation target.

- Raspberry Pi v1 & ZERO: ARMv6hf
- Raspberry Pi 2 + 3: ARMv7hf

You can have a look at the Raspberry PI images available:  
[https://www.balena.io/docs/reference/base-images/base-images/#armv6hf-](https://www.balena.io/docs/reference/base-images/base-images/#armv6hf-)

EDIT: so, yes, possibly the only way would be to have two different application and push to both git remote

hope this helps

---

<div class="post-metadata">

**Author:** ![bathtubed](https://avatars.discourse-cdn.com/v4/letter/b/ba9def/32.png) [@bathtubed](https://forums.balena.io/u/bathtubed)\
**Post date:** [January 3, 2019, 11:38pm UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874/6 "2019-01-03T23:38:09Z")

</div>

I guess each application only has a single compilation target makes sense, but it would seem like a commonly desired feature to be able to push portable code to multiple device types.

Fortunately for me, I am able to delete the raspberry pi 3 application from balena cloud entirely, and I can just use local pushing to test on my Pi 3.

---

<div class="post-metadata">

**Author:** ![xginn8](https://avatars.discourse-cdn.com/v4/letter/x/8baadc/32.png) [@xginn8](https://forums.balena.io/u/xginn8)\
**Post date:** [January 3, 2019, 11:43pm UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874/8 "2019-01-03T23:43:00Z")

</div>

Hi @bathtubed and @hahaha,

We have support for exactly this sort of design pattern. We provide a special Dockerfile template to allow our builders to inject your Dockerfile with the appropriate values for architecture and machine name, depending on which application you are pushing to. [Here is the corresponding documentation](https://www.balena.io/docs/learn/develop/dockerfile/#dockerfile-templates) for that feature, please try it out and let us know how it works for you!

Thanks for using balena!

---

<div class="post-metadata">

**Author:** ![hahaha](https://avatars.discourse-cdn.com/v4/letter/h/87869e/32.png) [@hahaha](https://forums.balena.io/u/hahaha)\
**Post date:** [January 3, 2019, 11:45pm UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874/9 "2019-01-03T23:45:42Z")

</div>

> [@bathtubed](#):
>
> be able to push portable code to multiple device types

that would be a very useful feature but I’m afraid there’s no such thing between Raspis 1 and 2+3 (would be somehow like asking to have portable code between Linux and Windows).

If I understand correctly how Balena works, they build and deploy a single Docker container on your device. A Docker container is nothing but a chroot environment, sort of a “directory” completely isolated from the rest of your device filesystem. They _must_ build multiple container for different architectures.

---

<div class="post-metadata">

**Author:** ![hahaha](https://avatars.discourse-cdn.com/v4/letter/h/87869e/32.png) [@hahaha](https://forums.balena.io/u/hahaha)\
**Post date:** [January 3, 2019, 11:46pm UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874/10 "2019-01-03T23:46:40Z")

</div>

oh cool thanks @xginn8 for the heads-up! I’m new to balena too and that is pretty interesting!

---

<div class="post-metadata">

**Author:** ![bathtubed](https://avatars.discourse-cdn.com/v4/letter/b/ba9def/32.png) [@bathtubed](https://forums.balena.io/u/bathtubed)\
**Post date:** [January 4, 2019, 12:27am UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874/11 "2019-01-04T00:27:49Z")

</div>

I know about and use the templating feature. However, to actually deploy this code to multiple types of devices, I still need to create two balenaCloud applications, where I duplicate my environment variables and push to both.

What’s the point of the `.template` if I still need to push to each device type anyway?

---

<div class="post-metadata">

**Author:** ![dt-rush](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/dt-rush/32/1405_2.png) [@dt-rush](https://forums.balena.io/u/dt-rush)\
**Post date:** [January 4, 2019, 12:48am UTC](https://forums.balena.io/t/raspberry-pi-3-application-incompatible-with-raspberry-pi-0-application/4874/16 "2019-01-04T00:48:23Z")

</div>

We have support for multiple architectures per app on our roadmap, but for now you can [get multiple device types which share an architecture on a single app](https://www.balena.io/blog/evolve-your-fleet-manage-multiple-device-types-in-one-application/).

Now, if you have multiple apps (one for armv7 devices, one for armv8) necessitated by the (present) limitation on architecture-homogeneous apps, you can still benefit from the `.template` file being a means to deploy your single codebase to the apps. You can also make use of the [CLI & SDK](https://www.balena.io/docs/learn/manage/serv-vars/#managing-with-the-cli-sdk) to synchronize deployment of environment variables to the apps.
