From 5c5a6eedc063f31081cd875a0227134fdd5d793b Mon Sep 17 00:00:00 2001 From: Mikael Magnusson Date: Tue, 27 Feb 2018 17:56:49 +0100 Subject: Read description from rootfs --- build.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build.sh b/build.sh index 89d0ead..3ecaab0 100755 --- a/build.sh +++ b/build.sh @@ -131,6 +131,7 @@ build_tarball() { build_metadata() { local stat=`stat -c %Y $rootfs` local date="`date -d \"@${stat}\" +%F`" + local desc=$(tar xpf $rootfs ./etc/openwrt_release -O|grep DISTRIB_DESCRIPTION|cut -d '=' -f 2) if test ${subarch} = generic; then local arch_lxd=${arch} @@ -143,7 +144,7 @@ architecture: "$arch_lxd" creation_date: $(date +%s) properties: architecture: "$arch_lxd" - description: "OpenWrt $ver ($date)" + description: "$desc" os: "OpenWrt" release: "$ver" templates: -- cgit v1.2.3