diff --git a/glances.firewalld b/glances.firewalld new file mode 100644 index 0000000..b24ca64 --- /dev/null +++ b/glances.firewalld @@ -0,0 +1,7 @@ + + + glances + Glances system monitor web service + + + diff --git a/glances.service b/glances.service new file mode 100644 index 0000000..235a2a7 --- /dev/null +++ b/glances.service @@ -0,0 +1,11 @@ +[Unit] +Description=Glances +After=network.target + +[Service] +ExecStart=/usr/bin/glances -w +Restart=on-abort +RemainAfterExit=yes + +[Install] +WantedBy=multi-user.target diff --git a/python-Glances.changes b/python-Glances.changes index c319f40..6de92cc 100644 --- a/python-Glances.changes +++ b/python-Glances.changes @@ -1,3 +1,70 @@ +------------------------------------------------------------------- +Tue Jul 13 11:43:41 UTC 2021 - Antonio Larrosa + +- Add a new glances-common package that contains a service file + to start the glances server from systemd and a firewalld service + file so the default port can be easily opened in the firewall. + +------------------------------------------------------------------- +Tue Jul 13 11:04:02 UTC 2021 - Antonio Larrosa + +- Update to 3.2.1 + * Missing network data in influxdb export + +- Update to 3.2.0 + * Enhancement and development requests: + * Improve CPU consumption + - Make the refresh rate configurable per plugin #1870 + - Add caching for processing username and cmdline + - Correct and improve refresh time method + - Set refresh rate for global CPU percent + - Set the dafault refresh rate of system stats to 60 seconds + - Default refresh time for sensors is refresh rate * 2 + - Improve history perf + - Change main curses loop + - Improve Docker client connection + - Update Flame profiling + * Get system sensors temperatures thresholds #1864 + * Filter data exported from Docker plugin + * Make the Docker API connection timeout configurable + * Add --issue to Github issue template + * Add release-note in the Makefile + * Add some comments in cpu_percent + * Add some comments to the processlist.py + * Set minimal version for PSUtil to 5.3.0 + * Add comment to default glances.conf file + * Improve code quality #820 + * Update WebUI for security vuln + * Bugs corrected: + * Quit from help should return to main screen, not exit #1874 + * AttributeError: 'NoneType' object has no attribute 'current' + #1875 + * Merge pull request #1873 from metayan/fix-history-add + * Correct filter + * Correct Flake8 issue in plugins + * Spelling correction in docs #1886 + * Starting an alias with a number causes a crash #1885 + * Network interfaces not applying in web UI #1884 + * Docker containers information missing with Docker 20.10.x + #1878 + * Get system sensors temperatures thresholds #1864 + +- Changes from 3.1.7 + * Enhancements and bug corrected: + * Security audit - B411 #1025 + * PU temperature not shown in webview #1849 + * Remove shell=True for actions (following Bandit issue report) + #1851 + * eplace Travis by Github action #1850 (by nicolargo) + * /api/3/processlist/pid/3936'use this api can't get right + info,all messy code #1828 + * efactor the way importants stats are displayed #1826 + * e-apply the Add hide option to sensors plugin #1596 + * mart plugin error while start glances as root #1806 + * lugin quicklook takes more than one seconds to update #1820 + * eplace Pystache by Chevron 2/2 See #1817 + * oc. No SMART screenshot. #1799 + ------------------------------------------------------------------- Sat Apr 10 19:52:11 UTC 2021 - Michael Ströder diff --git a/python-Glances.spec b/python-Glances.spec index dcb628b..9706516 100644 --- a/python-Glances.spec +++ b/python-Glances.spec @@ -19,27 +19,31 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} %define skip_python2 1 Name: python-Glances -Version: 3.1.6.2 +Version: 3.2.1 Release: 0 Summary: A cross-platform curses-based monitoring tool License: LGPL-3.0-only URL: https://github.com/nicolargo/glances Source: https://github.com/nicolargo/glances/archive/v%{version}.tar.gz +Source2: glances.service +Source3: glances.firewalld Patch0: adjust-data-files.patch Patch1: remove-shebang.patch Patch2: skip-online-tests.patch Patch3: fix-tests.patch Patch4: unitest-wait-for-server.patch BuildRequires: %{python_module bottle} +BuildRequires: %{python_module defusedxml} BuildRequires: %{python_module future} -BuildRequires: %{python_module psutil >= 5.6.3} +BuildRequires: %{python_module psutil >= 5.3.0} BuildRequires: %{python_module requests} BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: python-rpm-macros Requires: python-bottle +Requires: python-defusedxml Requires: python-future -Requires: python-psutil >= 5.6.3 +Requires: python-psutil >= 5.3.0 Requires: python-requests Requires(post): update-alternatives Requires(postun):update-alternatives @@ -56,6 +60,19 @@ large amount of monitoring information through a curses or Web based interface. The information dynamically adapts depending on the size of the user interface. +%package -n glances-common +Summary: Service and firewalld files for glances +Requires: glances + +%description -n glances-common +Glances is a cross-platform monitoring tool which presents a +large amount of monitoring information through a curses or Web +based interface. The information dynamically adapts depending on the +size of the user interface. + +This packages contains the service file to start a glances server +from systemd and a firewalld file to open the default port. + %prep %setup -q -n glances-%{version} %autopatch -p1 @@ -69,6 +86,14 @@ size of the user interface. %python_clone -a %{buildroot}%{_bindir}/glances %python_expand %fdupes %{buildroot}%{$python_sitelib} +mkdir -p %{buildroot}%{_sbindir} +ln -sf service %{buildroot}%{_sbindir}/rcglances +mkdir -p %{buildroot}%{_unitdir} +install -D -m 644 %{SOURCE2} %{buildroot}%{_unitdir}/ + +mkdir -p %{buildroot}%{_prefix}/lib/firewalld/services +install -D -m 644 %{SOURCE3} %{buildroot}%{_prefix}/lib/firewalld/services/glances.xml + %check export LANG=en_US.UTF-8 %python_exec unitest.py @@ -81,6 +106,18 @@ export LANG=en_US.UTF-8 %postun %python_uninstall_alternative glances +%pre -n glances-common +%service_add_pre glances.service + +%post -n glances-common +%service_add_post glances.service + +%preun -n glances-common +%service_del_preun glances.service + +%postun -n glances-common +%service_del_postun glances.service + %files %{python_files} %license COPYING %doc NEWS.rst README.rst @@ -88,4 +125,11 @@ export LANG=en_US.UTF-8 %python_alternative %{_mandir}/man1/glances.1%{?ext_man} %{python_sitelib}/* +%files -n glances-common +%dir %{_prefix}/lib/firewalld +%dir %{_prefix}/lib/firewalld/services +%{_prefix}/lib/firewalld/services/glances.xml +%{_unitdir}/glances.service +%{_sbindir}/rcglances + %changelog diff --git a/v3.1.6.2.tar.gz b/v3.1.6.2.tar.gz deleted file mode 100644 index 31f7278..0000000 --- a/v3.1.6.2.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:1eddc35a887159096eb4ca3e09dd144f5e60f4879b1e662478dbc18b39d77817 -size 6775046 diff --git a/v3.2.1.tar.gz b/v3.2.1.tar.gz new file mode 100644 index 0000000..51d9861 --- /dev/null +++ b/v3.2.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:51d4cfe411beb24ca520e029278243110c04e2df6f6f2f1d851976e09d1b1cd5 +size 6851329