Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

best approach of image versioning in yocto

What is the best approach for maintaining image versions in Yocto.

I mean suppose we build an image and given it to customer, in future we provided bug fixes to the customer..

How can we know which version of yocto image customer is using.. Is there any standard way to achieve this..

Thanks for your time. Appreciate your efforts..

like image 998
md.jamal Avatar asked Oct 11 '18 09:10

md.jamal


People also ask

How do I build a Yocto image in Ubuntu?

For example, we build the Yocto image dr-yocto:18.04 by calling in the directory /public/Work/dr-yocto. I use the Ubuntu version for the tag and the directory path, because the same Ubuntu version works for several Yocto versions.

Can I use Yocto Project images with Toradex?

Check the Yocto Project documentation for more information. Toradex provides some reference images which can be built on their own or then directly be installed with the Toradex Easy Installer. But these images are considered reference images and should not be used in products directly, instead one should derive a custom image from them.

What version of Ubuntu should I use with Yocto?

For example, Yocto 2.4 Rocko was released in October 2017. If we use Ubuntu 18.04 or newer for Rocko builds, the builds will fail with strange errors. The same build will work without any problems, if we use Ubuntu 17.04 or older. In the Docker container, we can run the Ubuntu version that best matches the Yocto version.

What is the Yocto Project?

Is this page helpful? "The Yocto Project is an open source collaboration project that provides templates, tools and methods to help you create custom Linux-based systems for embedded and IOT products, regardless of the hardware architecture." (quoted from: About the Yocto Project ).


1 Answers

You are interested in os-release recipe. This gives provision to add version details to the image. This recipe installs a file /etc/os-release in the target.

If you are interested in adding custom fields based on your application or purpose of the image, you can add extra fields in OS_RELEASE_FIELDS variable in os-release.bbappend in your custom layer. For example,

OS_RELEASE_FIELDS += "BUILD_VERSION"
BUG_FIXED_VERSION = "1.0.0-B1"
BUILD_VERSION = "${BUG_FIXED_VERSION}"

This adds the build id into /etc/os-release and you can increment the versions based on bug fix or new delivery.

like image 134
Parthiban Avatar answered Oct 23 '22 00:10

Parthiban