summaryrefslogtreecommitdiffstats
path: root/meta-phosphor
diff options
context:
space:
mode:
authorPatrick Williams <patrick@stwcx.xyz>2017-03-02 22:24:41 -0600
committerPatrick Williams <patrick@stwcx.xyz>2017-03-06 19:43:51 +0000
commitd0380a646ed0c71b3743919f91b2f45f845f4832 (patch)
tree3d3a0eee291b728afae2c31d1c50464f6e6013ba /meta-phosphor
parente8c604b0ac9792cff7f8ed6bb62b3781d2d6dc34 (diff)
downloadtalos-openbmc-d0380a646ed0c71b3743919f91b2f45f845f4832.tar.gz
talos-openbmc-d0380a646ed0c71b3743919f91b2f45f845f4832.zip
obmc-phosphor-image: disable /etc/version file
The /etc/version file is created by image generation with the timestamp of when the image was built. This is not useful to users and they should instead use /etc/os-release. There appears to be no way to disable the version file. Per the following email, delete it as part of the ROOTFS_POSTPROCESS_COMMAND: https://www.mail-archive.com/yocto@yoctoproject.org/msg33555.html Fixes openbmc/openbmc#1232. Change-Id: I78b3f31477c8490312be253eb363c4aafadf486c Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Diffstat (limited to 'meta-phosphor')
-rw-r--r--meta-phosphor/classes/obmc-phosphor-image.bbclass7
1 files changed, 7 insertions, 0 deletions
diff --git a/meta-phosphor/classes/obmc-phosphor-image.bbclass b/meta-phosphor/classes/obmc-phosphor-image.bbclass
index c31b7d724..3b5b5595b 100644
--- a/meta-phosphor/classes/obmc-phosphor-image.bbclass
+++ b/meta-phosphor/classes/obmc-phosphor-image.bbclass
@@ -89,3 +89,10 @@ IMAGE_FSTYPES += "${@image_overlay_enabled(d, "overlay")}"
inherit ${@image_overlay_enabled(d, "image-overlay")}
do_image_complete[depends] += "obmc-phosphor-debug-tarball:do_image_complete"
+
+# The /etc/version file is misleading and not useful. Remove it.
+# Users should instead rely on /etc/os-release.
+remove_etc_version() {
+ rm ${IMAGE_ROOTFS}${sysconfdir}/version
+}
+ROOTFS_POSTPROCESS_COMMAND += "remove_etc_version ; "
OpenPOWER on IntegriCloud