Description: Newslash's statics exporter for prometheus
Newsslash is 'news lashing discussion platform'. This package include configuration files for srad.jp.
+Package: newslash-searchd
+Architecture: any
+Depends:
+ python, gunicorn, python-lucene, python-mysql.connector
+Description: Newslash's search daemon
+ Newsslash is 'news lashing discussion platform'. This package include configuration files for srad.jp.
SRAD=newslash-sradjp
UTILS=newslash-utils
EXPORTER=newslash-prometheus-exporter
+SEARCHD=newslash-searchd
SRCDIR=src/newslash_web
UTILSDIR=src/utils
CORE_DEST=$(CURDIR)/debian/$(CORE)/usr/share/newslash
CORE_ETC=$(CURDIR)/debian/$(CORE)/etc/newslash
EXPORTERDIR=src/prometheus-newslash-exporter
+SEARCHD_DIR=src/ns_search
ASSETS_DEST=$(CURDIR)/debian/$(ASSETS)/usr/share/newslash
SRAD_DEST=$(CURDIR)/debian/$(SRAD)/usr/share/newslash
UTILS_DEST=$(CURDIR)/debian/$(UTILS)/usr/share/newslash-utils
EXPORTER_DEST=$(CURDIR)/debian/$(EXPORTER)/usr/share/newslash-prometheus-exporter
+SEARCHD_DEST=$(CURDIR)/debian/$(SEARCHD)/usr/share/newslash-searchd
+SEARCHD_ETC=$(CURDIR)/debian/$(SEARCHD)/etc/newslash
install/$(CORE)::
cd $(SRCDIR); \
install -pDm 755 $(EXPORTERDIR)/newslash-exporter.py $(EXPORTER_DEST)/newslash-exporter.py
install -pDm 644 $(EXPORTERDIR)/newslash-prometheus-exporter.service \
$(CURDIR)/debian/$(EXPORTER)/lib/systemd/system/newslash-prometheus-exporter.service
+
+install/$(SEARCHD)::
+ mkdir -p -m 755 $(SEARCHD_DEST)/modules
+ mkdir -p -m 755 $(SEARCHD_ETC)
+ cd $(SEARCHD_DIR); for target in newslash_db newslash_searchd newslash_index lucene_wrapper; do \
+ mkdir -p $(SEARCHD_DEST)/modules/$$target ; \
+ find $$target -name '*.py' -exec install -pDm 644 {} $(SEARCHD_DEST)/modules/{} \; ; \
+ done
+ install -pDm 755 $(SEARCHD_DIR)/searchd.py $(SEARCHD_DEST)/modules/
+ install -pDm 755 $(SEARCHD_DIR)/searchd_cli.py $(SEARCHD_DEST)/modules/
+ install -pDm 644 $(SEARCHD_DIR)/searchd.conf.example $(SEARCHD_ETC)/
+
+