summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikael Magnusson <mikma@users.sourceforge.net>2018-02-27 17:56:49 +0100
committerMikael Magnusson <mikma@users.sourceforge.net>2018-02-27 17:56:49 +0100
commit5c5a6eedc063f31081cd875a0227134fdd5d793b (patch)
tree03f9481a05eb41a1f275305b025f8dda7bf94aa7
parentf0bb073ff2e2317641b0bc731b5bd13a5194bd1a (diff)
Read description from rootfs
-rwxr-xr-xbuild.sh3
1 files changed, 2 insertions, 1 deletions
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: