-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.package
52 lines (38 loc) · 1.09 KB
/
Makefile.package
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
include $(TOPDIR)/rules.mk
PKG_NAME:=loki-exporter
PKG_VERSION:=%% PKG_VERSION %%
PKG_RELEASE:=%% PKG_RELEASE %%
PKG_LICENSE:=MIT
PKG_MAINTAINER:=Andrei Belov <[email protected]>
include $(INCLUDE_DIR)/package.mk
define Package/loki-exporter
SECTION:=net
CATEGORY:=Network
TITLE:=loki-exporter
DEPENDS:=+curl
PKGARCH:=all
URL:=https://github.com/defanator/openwrt-loki-exporter
endef
define Package/loki-exporter/description
Tiny service for exporting system log to remote Loki instance,
written in pure shell.
Build ID: %% BUILD_ID %%
endef
define Package/loki-exporter/conffiles
/etc/config/loki_exporter
endef
define Build/Prepare
endef
define Build/Configure
endef
define Build/Compile
endef
define Package/loki-exporter/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) ./files/loki_exporter.sh $(1)/usr/bin/loki_exporter
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/loki_exporter.init $(1)/etc/init.d/loki_exporter
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_CONF) ./files/loki_exporter.conf $(1)/etc/config/loki_exporter
endef
$(eval $(call BuildPackage,loki-exporter))