diff options
-rw-r--r-- | healthcheck/Makefile | 49 | ||||
-rw-r--r-- | healthcheck/files/cron | 2 | ||||
-rw-r--r-- | python-crontab/Makefile | 45 | ||||
-rw-r--r-- | python-humanize/Makefile | 42 | ||||
-rw-r--r-- | python-rich/Makefile | 41 |
5 files changed, 179 insertions, 0 deletions
diff --git a/healthcheck/Makefile b/healthcheck/Makefile new file mode 100644 index 0000000..8faa1fb --- /dev/null +++ b/healthcheck/Makefile @@ -0,0 +1,49 @@ +# +# Copyright (C) 2021 CZ.NIC, z. s. p. o. (https://www.nic.cz/) +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=healthcheck +PKG_SOURCE_URL:=https://gitlab.nic.cz/turris/healthcheck.git +PKG_SOURCE_BRANCH:=dev + +PKG_MAINTAINER:=CZ.NIC <packaging@turris.cz> +PKG_LICENSE:=GPL-3.0-or-later +PKG_LICENSE_FILES:=COPYING + +include $(INCLUDE_DIR)/autopkg-branch.mk +include $(INCLUDE_DIR)/package.mk +include $(TOPDIR)/feeds/packages/lang/python/python3-package.mk + +define Package/healthcheck + SECTION:=utils + CATEGORY:=Utilities + TITLE:=Healthcheck + URL:=https://gitlab.nic.cz/turris/healthcheck + DEPENDS:=\ + +python3-humanize \ + +python3-rich \ + +python3-crontab \ + +python3-uci + VARIANT:=python3 +endef + +define Package/healthcheck/description + Turris router health checking tool. +endef + +define Py3Package/healthcheck/install + $(INSTALL_DIR) $(1)/usr/bin + $(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/ + + $(INSTALL_DIR) $(1)/etc/cron.d + $(INSTALL_CONF) ./files/cron $(1)/etc/cron.d/healthcheck +endef + +$(eval $(call Py3Package,healthcheck)) +$(eval $(call BuildPackage,healthcheck)) +$(eval $(call BuildPackage,healthcheck-src)) diff --git a/healthcheck/files/cron b/healthcheck/files/cron new file mode 100644 index 0000000..32907f5 --- /dev/null +++ b/healthcheck/files/cron @@ -0,0 +1,2 @@ +MAILTO="" +0-59/4 * * * * root LANG="$(uci -q get foris.settings.lang || echo en)" healthcheck --periodic diff --git a/python-crontab/Makefile b/python-crontab/Makefile new file mode 100644 index 0000000..2835b1b --- /dev/null +++ b/python-crontab/Makefile @@ -0,0 +1,45 @@ +# +# Copyright (C) 2021 CZ.NIC, z. s. p. o. (https://www.nic.cz/) +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=python-crontab +PKG_VERSION:=0.23.0 +PKG_RELEASE:=1 + +PKG_LICENSE:=LGPLv3 +PKG_LICENSE_FILES:=LICENSE + +PYPI_NAME:=crontab +PKG_HASH:=ca79dede9c2f572bb32f38703e8fddcf3427e86edc838f2ffe7ae4b9ee2b0733 + +include $(TOPDIR)/feeds/packages/lang/python/pypi.mk +include $(INCLUDE_DIR)/package.mk +include $(TOPDIR)/feeds/packages/lang/python/python3-package.mk + +PYTHON3_PKG_SETUP_ARGS := + +define Package/python3-crontab + SECTION:=lang-python + CATEGORY:=Languages + SUBMENU:=Python + TITLE:=Parse and use crontab schedules in Python + URL:=https://github.com/josiahcarlson/parse-crontab + DEPENDS:=+python3-light + VARIANT:=python3 +endef + +define Package/python3-crontab/description + This package intends to offer a method of parsing crontab schedule entries and + determining when an item should next be run. More specifically, it calculates a + delay in seconds from when the .next() method is called to when the item should + next be executed. +endef + +$(eval $(call Py3Package,python3-crontab)) +$(eval $(call BuildPackage,python3-crontab)) +$(eval $(call BuildPackage,python3-crontab-src)) diff --git a/python-humanize/Makefile b/python-humanize/Makefile new file mode 100644 index 0000000..6c08041 --- /dev/null +++ b/python-humanize/Makefile @@ -0,0 +1,42 @@ +# +# Copyright (C) 2021 CZ.NIC, z. s. p. o. (https://www.nic.cz/) +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=python-humanize +PKG_VERSION:=3.13.1 +PKG_RELEASE:=1 + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=LICENSE + +PYPI_NAME:=humanize +PKG_HASH:=12f113f2e369dac7f35d3823f49262934f4a22a53a6d3d4c86b736f50db88c7b + +include $(TOPDIR)/feeds/packages/lang/python/pypi.mk +include $(INCLUDE_DIR)/package.mk +include $(TOPDIR)/feeds/packages/lang/python/python3-package.mk + +define Package/python3-humanize + SECTION:=lang-python + CATEGORY:=Languages + SUBMENU:=Python + TITLE:=Python humanize utilities + URL:=https://github.com/jmoiron/humanize + DEPENDS:=+python3-light + VARIANT:=python3 +endef + +define Package/python3-periphery/description + This modest package contains various common humanization utilities, like + turning a number into a fuzzy human-readable duration ("3 minutes ago") or into + a human-readable size or throughput. +endef + +$(eval $(call Py3Package,python3-humanize)) +$(eval $(call BuildPackage,python3-humanize)) +$(eval $(call BuildPackage,python3-humanize-src)) diff --git a/python-rich/Makefile b/python-rich/Makefile new file mode 100644 index 0000000..924eae2 --- /dev/null +++ b/python-rich/Makefile @@ -0,0 +1,41 @@ +# +# Copyright (C) 2021 CZ.NIC, z. s. p. o. (https://www.nic.cz/) +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=python-rich +PKG_VERSION:=10.15.2 +PKG_RELEASE:=1 + +PKG_LICENSE:=MIT +PKG_LICENSE_FILES:=LICENSE + +PYPI_NAME:=rich +PKG_HASH:=1dded089b79dd042b3ab5cd63439a338e16652001f0c16e73acdcf4997ad772d + +include $(TOPDIR)/feeds/packages/lang/python/pypi.mk +include $(INCLUDE_DIR)/package.mk +include $(TOPDIR)/feeds/packages/lang/python/python3-package.mk + +define Package/python3-rich + SECTION:=lang-python + CATEGORY:=Languages + SUBMENU:=Python + TITLE:=Render rich text and more to the terminal + URL:=https://github.com/willmcgugan/rich + DEPENDS:=+python3-light + VARIANT:=python3 +endef + +define Package/python3-rich/description + Render rich text, tables, progress bars, syntax highlighting, markdown and more + to the terminal. +endef + +$(eval $(call Py3Package,python3-rich)) +$(eval $(call BuildPackage,python3-rich)) +$(eval $(call BuildPackage,python3-rich-src)) |