Version naming/branding for in-house builds

瀏覽次數:18 次
跳到第一則未讀訊息

Christian Svensson

未讀,
2022年1月6日 清晨5:12:372022/1/6
收件者:sonicproject
Hello,

An organization I am part of has a fork of sonic-buildimage that we use for in-house builds that include patches that have not been accepted upstream yet.
We follow the same branch naming as Azure/sonic-buildimage (e.g. 202111) and we also use the same Azure Pipelines[1] scripts to run our builds.

The issue we face is that this results in images with version information extremely similar to official upstream images.
Example: 202012.19-08de2b148 is our build version, while the latest upstream is 202012.63280-1eec2bc25.
The for an operator that is more confusing than it needs to be.

We would like to be able to set an environment variable to "brand" or tag a version as a certain organization.
My current hack is this[2] which changes the format to ${branch_name}-${BUILD_ORG}.${BUILD_NUMBER}-${commit} but
I would be happy with any format that the community accepts. My biggest concern about making something like this up for
myself is to break potential version string parsing that may happen now or in the future.

Thoughts?


Regards,

Yuval-Mellanox

未讀,
2022年1月6日 上午8:32:322022/1/6
收件者:sonicproject
will overriding the $SONIC_IMAGE_VERSION during the make suffice your requirement ?

Christian Svensson

未讀,
2022年1月6日 上午9:00:122022/1/6
收件者:Yuval-Mellanox、sonicproject
Hi,

Thanks for the suggestion!
In theory yes that would work - but In that case I would have to introduce an extra script step in the CI build that basically does what sonic_get_version does in order to calculate what to set that variable to.
Seems like a lot of extra work, it's easier to carry a patch to modify functions.sh in that case.

--
You received this message because you are subscribed to the Google Groups "sonicproject" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sonicproject...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sonicproject/5d8fc7ca-9bba-42f7-b22f-49b3dc12ec87n%40googlegroups.com.
回覆所有人
回覆作者
轉寄
0 則新訊息