# air-gapped deployment, service variables

**URL:** <https://forums.balena.io/t/air-gapped-deployment-service-variables/367176>\
**Category:** General\
**Created:** [March 16, 2023, 8:15am UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176 "2023-03-16T08:15:05Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![haronaut](https://avatars.discourse-cdn.com/v4/letter/h/2acd7d/32.png) [@haronaut](https://forums.balena.io/u/haronaut)\
**Post date:** [March 16, 2023, 8:15am UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176/1 "2023-03-16T08:15:05Z")

</div>

Hi! If I want to deploy a multi-container app to a device without cloud connection, is it possible to pass the Balena Cloud environment variables to the containers without declaring them directly in the compose file?

---

<div class="post-metadata">

**Author:** ![mpous](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/mpous/32/4742_2.png) [@mpous](https://forums.balena.io/u/mpous)\
**Post date:** [March 21, 2023, 12:34pm UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176/2 "2023-03-21T12:34:22Z")

</div>

Hello @haronaut

did you try the offline updates? [Offline updates - Balena Documentation](https://docs.balena.io/learn/deploy/offline-updates/)

or preloading the services into the OS image and adding the device variables using balena CLI?

---

<div class="post-metadata">

**Author:** ![haronaut](https://avatars.discourse-cdn.com/v4/letter/h/2acd7d/32.png) [@haronaut](https://forums.balena.io/u/haronaut)\
**Post date:** [March 21, 2023, 1:13pm UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176/4 "2023-03-21T13:13:49Z")

</div>

Thanks! I can set the variables via balena CLI.

---

<div class="post-metadata">

**Author:** ![haronaut](https://avatars.discourse-cdn.com/v4/letter/h/2acd7d/32.png) [@haronaut](https://forums.balena.io/u/haronaut)\
**Post date:** [March 22, 2023, 2:06pm UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176/5 "2023-03-22T14:06:57Z")

</div>

@mpous Is there a possibility to push multiple variables all at once? I assume that every service is restarted as soon as I push a single variable.

---

<div class="post-metadata">

**Author:** ![mpous](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/mpous/32/4742_2.png) [@mpous](https://forums.balena.io/u/mpous)\
**Post date:** [April 17, 2023, 10:07pm UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176/6 "2023-04-17T22:07:27Z")

</div>

Hello, did you check if this feature is what you need? [Allow changes to variables to be batched and submitted all at once · Balena Roadmap](https://roadmap.balena.io/posts/19/allow-changes-to-variables-to-be-batched-and-submitted-all-at-once)

---

<div class="post-metadata">

**Author:** ![haronaut](https://avatars.discourse-cdn.com/v4/letter/h/2acd7d/32.png) [@haronaut](https://forums.balena.io/u/haronaut)\
**Post date:** [April 18, 2023, 5:32am UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176/7 "2023-04-18T05:32:00Z")

</div>

If this will also be available via balena cli then that’s exactly what I need.

---

<div class="post-metadata">

**Author:** ![myarmolinsky](https://avatars.discourse-cdn.com/v4/letter/m/9dc877/32.png) [@myarmolinsky](https://forums.balena.io/u/myarmolinsky)\
**Post date:** [April 18, 2023, 11:09am UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176/11 "2023-04-18T11:09:42Z")

</div>

Hi, as part of that feature, support is intended to be added in the SDK for allowing pushing multiple variable changes at once. The intention is to also have feature parity between the SDK and CLI so we should make it available in the CLI as well, although I don’t currently have an example of how this would look, nor do I have an ETA for the SDK and CLI support. I will bookmark this thread and come back to it to inform you once support for each has been added, though I advise keeping an eye on the roadmap for updates.

---

<div class="post-metadata">

**Author:** ![DonovanTroy](https://avatars.discourse-cdn.com/v4/letter/d/c67d28/32.png) [@DonovanTroy](https://forums.balena.io/u/DonovanTroy)\
**Post date:** [June 8, 2023, 9:23am UTC](https://forums.balena.io/t/air-gapped-deployment-service-variables/367176/13 "2023-06-08T09:23:47Z")

</div>

I can ensure you that it is indeed possible to pass balena cloud environment variables to containers without directly declaring them in the compose file. Balena cloud offers a feature called “device service variables” that enables you to define environment variables at the device level. These variables are then automatically passes to all containers running on the device.
