# Ubuntu Core and snap packages in production

**URL:** <https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002>\
**Category:** ROS General\
**Created:** [June 4, 2018, 5:24am UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002 "2018-06-04T05:24:23Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![msadowski](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/msadowski/32/33950_2.png) [@msadowski](https://discourse.openrobotics.org/u/msadowski)\
**Post date:** [June 4, 2018, 5:24am UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/1 "2018-06-04T05:24:23Z")

</div>

Hi!

I’ve been wondering if anyone in the community has experience of using snap packages in their ROS enabled projects? I’ve been trying really hard to find some projects but didn’t succeed in finding anything else than couple of blog posts.

Did anyone of you evaluate using snaps in robotics? Are there any huge advantages or disadvantages one should be aware of?

Thanks in advance for any advice you might offer!

---

<div class="post-metadata">

**Author:** ![awesomebytes](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/awesomebytes/32/497_2.png) [@awesomebytes](https://discourse.openrobotics.org/u/awesomebytes)\
**Post date:** [June 4, 2018, 8:33am UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/2 "2018-06-04T08:33:51Z")

</div>

I have no sources for what I’m gonna say but I remember connecting ROS components with snaps was impossible/a pain. As snaps were by default isolated (like a Docker image if you use Docker) you could not connect, say, a snap running roscore and a snap running something else like the navigation stack.

Maybe things got fixed with time, but I haven’t heard more about.

---

<div class="post-metadata">

**Author:** ![carlosjoserg](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/carlosjoserg/32/258_2.png) [@carlosjoserg](https://discourse.openrobotics.org/u/carlosjoserg)\
**Post date:** [June 4, 2018, 8:54am UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/3 "2018-06-04T08:54:23Z")

</div>

There is a related post from last year: [From ROS prototype to production on Ubuntu Core - ROS General - Open Robotics Discourse](http://discourse.ros.org/t/from-ros-prototype-to-production-on-ubuntu-core/1612) in case you are interested.

I’ve looked into it, but not actually tried it.

---

<div class="post-metadata">

**Author:** ![msadowski](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/msadowski/32/33950_2.png) [@msadowski](https://discourse.openrobotics.org/u/msadowski)\
**Post date:** [June 4, 2018, 10:59am UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/4 "2018-06-04T10:59:49Z")

</div>

I’ve been following this set of tutorials to get to know snap better. After following it and going through some pains (e.g. serial port access, build times on armhf platform) I started to wonder what other people have experienced.

I can see how snap, if project is architectured right, can solve some of the deployment issues however for development it seems like a lot of burden, especially in cases where you want to develop in incremental steps and test on the robot as you go.

---

<div class="post-metadata">

**Author:** ![msadowski](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/msadowski/32/33950_2.png) [@msadowski](https://discourse.openrobotics.org/u/msadowski)\
**Post date:** [June 4, 2018, 11:02am UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/5 "2018-06-04T11:02:44Z")

</div>

I would imagine, after following the tutorials, you would need to put all the nodes that you require in a single launch file. This could work but doesn’t seem too modular.

---

<div class="post-metadata">

**Author:** ![kyrofa](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/kyrofa/32/9577_2.png) [@kyrofa](https://discourse.openrobotics.org/u/kyrofa)\
**Post date:** [June 4, 2018, 3:51pm UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/6 "2018-06-04T15:51:13Z")

</div>

Hey there @msadowski, thanks for opening a thread! I’m a ROS nut, but also one of the snapcraft maintainers, so I hope that I can answer your questions.

> [@awesomebytes](#):
>
> I have no sources for what I’m gonna say but I remember connecting ROS components with snaps was impossible/a pain. As snaps were by default isolated (like a Docker image if you use Docker) you could not connect, say, a snap running roscore and a snap running something else like the navigation stack.

This was true in the past, but less so today. Please see this [write-up](https://kyrofa.com/posts/distributing-a-ros-system-among-multiple-snaps). I’ll admit it’s still not the easiest thing, but I know of a few companies using it.

> [@msadowski](#):
>
> however for development it seems like a lot of burden, especially in cases where you want to develop in incremental steps and test on the robot as you go.

Yeah, it’s a bit like packaging your ROS system as debs just in order to test on the robot: no one really does that either. Put any sort of packaging step in the development iteration loop and things slow down pretty quickly. Snaps are currently very much a deployment/update tool (get a prototype working outside of snaps, then productize it using snaps). We’re actually working on making iteration a lot better this cycle, and you’ll see some improvements already in the next release, but we’re not there yet. It will still never be as easy as just running from source, though.

---

<div class="post-metadata">

**Author:** ![fkromer](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/fkromer/32/2446_2.png) [@fkromer](https://discourse.openrobotics.org/u/fkromer)\
**Post date:** [June 4, 2018, 4:46pm UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/7 "2018-06-04T16:46:26Z")

</div>

> [@kyrofa](#):
>
> This was true in the past, but less so today. Please see this [write-up](https://kyrofa.com/posts/distributing-a-ros-system-among-multiple-snaps). I’ll admit it’s still not the easiest thing, but I know of a few companies using it.

I know slightly of topic: For ROS2 the whole procedure should be way easier right?

---

<div class="post-metadata">

**Author:** ![kyrofa](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/kyrofa/32/9577_2.png) [@kyrofa](https://discourse.openrobotics.org/u/kyrofa)\
**Post date:** [June 4, 2018, 5:08pm UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/8 "2018-06-04T17:08:46Z")

</div>

> [@fkromer](#):
>
> I know slightly of topic: For ROS2 the whole procedure should be way easier right?

Excellent question! Indeed, since roscore is no longer necessary for handshaking, splitting nodes between snaps becomes far easier. ROS2 still uses workspaces, though, so it’s not as clean as it could be. Depending on how things are configured, you may still end up needing to split a workspace between multiple snaps.

---

<div class="post-metadata">

**Author:** ![msadowski](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.openrobotics.org/msadowski/32/33950_2.png) [@msadowski](https://discourse.openrobotics.org/u/msadowski)\
**Post date:** [June 5, 2018, 9:08am UTC](https://discourse.openrobotics.org/t/ubuntu-core-and-snap-packages-in-production/5002/9 "2018-06-05T09:08:49Z")

</div>

Thanks for the write up, it’s really helpful! I can’t wait to see what you will come up with next with Snap and ROS! If there was a way to have incremental builds I think this could allow for using snaps even during the development (although I can imagine it would be quite difficult to pull off).
