mirror of
https://github.com/novatiq/packages.git
synced 2026-04-30 07:28:39 +01:00
xray-core: add init script
Add init script so the users could run it with their configs quickly. Signed-off-by: Tianling Shen <cnsztl@project-openwrt.eu.org>
This commit is contained in:
+16
-1
@@ -75,6 +75,11 @@ define Package/xray-geodata/description
|
||||
This includes GEO datas used for xray-core.
|
||||
endef
|
||||
|
||||
define Package/xray-core/conffiles
|
||||
/etc/xray/
|
||||
/etc/config/xray
|
||||
endef
|
||||
|
||||
GEOIP_VER:=202101280019
|
||||
GEOIP_FILE:=geoip.dat.$(GEOIP_VER)
|
||||
|
||||
@@ -105,10 +110,20 @@ endef
|
||||
|
||||
define Package/xray-core/install
|
||||
$(call GoPackage/Package/Install/Bin,$(PKG_INSTALL_DIR))
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/bin/
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/main $(1)/usr/bin/xray
|
||||
$(LN) xray $(1)/usr/bin/v2ray
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/xray/
|
||||
$(INSTALL_CONF) $(CURDIR)/files/config.json.example $(1)/etc/xray/
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/config/
|
||||
$(INSTALL_CONF) $(CURDIR)/files/xray.conf $(1)/etc/config/xray
|
||||
$(INSTALL_DIR) $(1)/etc/init.d/
|
||||
$(INSTALL_BIN) $(CURDIR)/files/xray.init $(1)/etc/init.d/xray
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/capabilities/
|
||||
$(INSTALL_DATA) $(CURDIR)/files/xray.capabilities $(1)/etc/capabilities/xray.json
|
||||
endef
|
||||
|
||||
define Package/xray-example/install
|
||||
|
||||
Reference in New Issue
Block a user