summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2018-12-30 08:03:29 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2018-12-31 07:31:52 +0000
commit57a22c395cd4156a087d70cd4604592e32a99da7 (patch)
treea7f70922bbf612c6f962123f229a2d0a9810a3c6
parentBuilding on linux only, building on kfreebsd doesn't really work at the moment. (diff)
downloadnetdata-57a22c395cd4156a087d70cd4604592e32a99da7.tar.xz
netdata-57a22c395cd4156a087d70cd4604592e32a99da7.zip
Writing exact package version into web/version.txt.
The update-check is not run automatically and the update-button is not shown on Debian. If the update-check is triggered manually, it expects version.txt to contain something, therefore on Debian it contained '0'. As it does not matter what value is in there, there is no gain in writing an inaccurate one either. Therefore, let's write the exact package version in it. Note: version.txt is by default exposed to the web via http://localhost:19999/version.txt. Anyone who can access netdata can also see what exact version you're running. Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
-rwxr-xr-xdebian/rules6
1 files changed, 4 insertions, 2 deletions
diff --git a/debian/rules b/debian/rules
index 56e9db248..02f2b2858 100755
--- a/debian/rules
+++ b/debian/rules
@@ -5,6 +5,8 @@
DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
TOP = $(CURDIR)/debian/netdata
+VERSION := $(shell dpkg-parsechangelog -SVersion)
+
export DH_VERBOSE = 1
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
@@ -32,8 +34,8 @@ override_dh_install-arch: $(MULTIARCH_INSTALL)
override_dh_install-indep:
dh_install
- # Deactivate automatic update check
- echo 0 > $(TOP)-data/usr/share/netdata/web/version.txt
+ # Setting package version (update check)
+ echo $(VERSION) > $(TOP)-data/usr/share/netdata/web/version.txt
override_dh_fixperms-arch:
dh_fixperms