mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-16 04:13:31 +00:00
rclone: sync upstream (#8024)
* rclone-webui: cleanup Makefile * rclone: import init files from luci * rclone: add missing dependencies * luci-app-rclone: move init files to packages Co-authored-by: Tianling Shen <cnsztl@immortalwrt.org>
This commit is contained in:
parent
86cec76891
commit
c14b434216
@ -1,32 +1,29 @@
|
||||
####
|
||||
# File: /Makefile
|
||||
# Project: luci-app-rclone
|
||||
# File Created: Wednesday, 9th October 2019 1:39:36 pm
|
||||
# Author: ElonH[EH](elonhhuang@gmail.com)
|
||||
# License: GNU General Public License v3.0 or later(http://www.gnu.org/licenses/gpl-3.0-standalone.html)
|
||||
# Copyright (C) 2019 [ElonH]
|
||||
####
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
#
|
||||
# Copyright (C) 2019 ElonH <elonhhuang@gmail.com>
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=luci-app-rclone
|
||||
PKG_VERSION:=1.4.1
|
||||
PKG_RELEASE:=1
|
||||
PKG_LICENSE:=GPLv3.0+
|
||||
|
||||
PKG_LICENSE:=GPLv3.0+
|
||||
PKG_MAINTAINER:=ElonH <elonhhuang@gmail.com>
|
||||
|
||||
PKG_CONFIG_DEPENDS:= \
|
||||
CONFIG_PACKAGE_$(PKG_NAME)_INCLUDE_rclone-webui \
|
||||
CONFIG_PACKAGE_$(PKG_NAME)_INCLUDE_rclone-ng \
|
||||
CONFIG_PACKAGE_$(PKG_NAME)_INCLUDE_fuse-utils
|
||||
|
||||
CONFIG_PACKAGE_$(PKG_NAME)_INCLUDE_rclone-ng
|
||||
|
||||
LUCI_TITLE:=LuCI support for Rclone
|
||||
LUCI_PKGARCH:=all
|
||||
LUCI_DEPENDS:=+rclone \
|
||||
+PACKAGE_$(PKG_NAME)_INCLUDE_rclone-webui:rclone-webui-react \
|
||||
+PACKAGE_$(PKG_NAME)_INCLUDE_rclone-ng:rclone-ng \
|
||||
+PACKAGE_$(PKG_NAME)_INCLUDE_fuse-utils:fuse-utils
|
||||
+PACKAGE_$(PKG_NAME)_INCLUDE_rclone-ng:rclone-ng
|
||||
|
||||
define Package/$(PKG_NAME)/conffiles
|
||||
/etc/config/rclone
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/config
|
||||
config PACKAGE_$(PKG_NAME)_INCLUDE_rclone-webui
|
||||
@ -36,10 +33,6 @@ config PACKAGE_$(PKG_NAME)_INCLUDE_rclone-webui
|
||||
config PACKAGE_$(PKG_NAME)_INCLUDE_rclone-ng
|
||||
bool "Include rclone-ng (another webui)"
|
||||
default y
|
||||
|
||||
config PACKAGE_$(PKG_NAME)_INCLUDE_fuse-utils
|
||||
bool "Include fuse-utils (mount cloud storage)"
|
||||
default y
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/conffiles
|
||||
|
@ -1,58 +1,41 @@
|
||||
####
|
||||
# File: /rclone-ng/Makefile
|
||||
# Project: Rclone-OpenWrt
|
||||
# File Created: Friday, 5th June 2020 12:37:26 am
|
||||
# Author: ElonH[EH](elonhhuang@gmail.com)
|
||||
# License: GNU General Public License v3.0 or later(http://www.gnu.org/licenses/gpl-3.0-standalone.html)
|
||||
# Copyright (C) 2020 [ElonH]
|
||||
####
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
#
|
||||
# Copyright (C) 2020 ElonH <elonhhuang@gmail.com>
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=rclone-ng
|
||||
PKG_VERSION:=0.5.0
|
||||
PKG_RELEASE:=1
|
||||
PKG_RELEASE:=$(AUTORELEASE)
|
||||
|
||||
PKG_SOURCE:=RcloneNg-v$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://github.com/ElonH/RcloneNg/releases/download/v$(PKG_VERSION)/
|
||||
PKG_HASH:=0b4916ddd0bacb5b358dc8d36b64c30f4182c0ace3eb06cda94b6578c419dcd9
|
||||
|
||||
PKG_LICENSE:=GPLv3
|
||||
PKG_LICENSE:=MIT
|
||||
PKG_LICENSE_FILE:=LICENSE
|
||||
PKG_MAINTAINER:=ElonH <elonhhuang@gmail.com>
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
PKG_SOURCE:=RcloneNg-v$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://github.com/ElonH/RcloneNg/releases/download/v$(PKG_VERSION)/
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_HASH:=0b4916ddd0bacb5b358dc8d36b64c30f4182c0ace3eb06cda94b6578c419dcd9
|
||||
TAR_CMD:=$(HOST_TAR) -C $(PKG_BUILD_DIR) $(TAR_OPTIONS)
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=net
|
||||
CATEGORY:=Network
|
||||
SUBMENU:=File Transfer
|
||||
SUBMENU:=Cloud Manager
|
||||
TITLE:=An angular web application for rclone
|
||||
URL:=https://github.com/ElonH/RcloneNg
|
||||
PKGARCH:=all
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description
|
||||
An angular web application for rclone
|
||||
endef
|
||||
|
||||
define Build/Prepare
|
||||
mkdir -vp $(PKG_BUILD_DIR)
|
||||
tar -xzf $(DL_DIR)/$(PKG_SOURCE) -C $(PKG_BUILD_DIR)
|
||||
endef
|
||||
|
||||
define Build/Configure
|
||||
define Package/rclone-ng
|
||||
SECTION:=net
|
||||
CATEGORY:=Network
|
||||
SUBMENU:=Cloud Manager
|
||||
TITLE:=An angular web application for rclone
|
||||
URL:=https://github.com/ElonH/RcloneNg
|
||||
DEPENDS:=+rclone
|
||||
PKGARCH:=all
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
echo "$(PKG_NAME) Compile Skiped!"
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
define Package/rclone-ng/install
|
||||
$(INSTALL_DIR) $(1)/www
|
||||
$(CP) $(PKG_BUILD_DIR)/RcloneNg $(1)/www
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)))
|
||||
$(eval $(call BuildPackage,rclone-ng))
|
||||
|
@ -6,7 +6,7 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=rclone-webui-react
|
||||
PKG_VERSION:=2.0.5
|
||||
PKG_RELEASE:=1
|
||||
PKG_RELEASE:=$(AUTORELEASE)
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).zip
|
||||
PKG_SOURCE_URL:=https://github.com/rclone/rclone-webui-react/releases/download/v$(PKG_VERSION)/currentbuild.zip?
|
||||
@ -21,21 +21,20 @@ include $(INCLUDE_DIR)/package.mk
|
||||
UNZIP_CMD:=unzip -q -d $(PKG_BUILD_DIR) $(DL_DIR)/$(PKG_SOURCE)
|
||||
|
||||
define Package/rclone-webui-react
|
||||
SECTION:=net
|
||||
CATEGORY:=Network
|
||||
SUBMENU:=Cloud Manager
|
||||
TITLE:=A reactjs based web UI for rclone
|
||||
URL:=https://github.com/rclone/rclone-webui-react
|
||||
DEPENDS:=+rclone
|
||||
PKGARCH:=all
|
||||
SECTION:=net
|
||||
CATEGORY:=Network
|
||||
SUBMENU:=Cloud Manager
|
||||
TITLE:=A reactjs based web UI for rclone
|
||||
URL:=https://github.com/rclone/rclone-webui-react
|
||||
DEPENDS:=+rclone
|
||||
PKGARCH:=all
|
||||
endef
|
||||
|
||||
define Package/rclone-webui-react/description
|
||||
A full fledged UI for the rclone cloud sync tool.
|
||||
A full fledged UI for the rclone cloud sync tool.
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
true
|
||||
endef
|
||||
|
||||
define Package/rclone-webui-react/install
|
||||
|
@ -42,7 +42,7 @@ define Package/rclone
|
||||
SUBMENU:=File Transfer
|
||||
TITLE:=rsync for cloud storage
|
||||
URL:=https://rclone.org
|
||||
DEPENDS:=$(GO_ARCH_DEPENDS)
|
||||
DEPENDS:=$(GO_ARCH_DEPENDS) +ca-bundle +fuse-utils
|
||||
endef
|
||||
|
||||
define Package/rclone/description
|
||||
@ -65,6 +65,10 @@ ifeq ($(CONFIG_RCLONE_COMPRESS_GOPROXY),y)
|
||||
export GOPROXY=https://goproxy.baidu.com
|
||||
endif
|
||||
|
||||
define Package/rclone/conffiles
|
||||
/etc/config/rclone
|
||||
endef
|
||||
|
||||
# Disable CGO due to ld linker issue
|
||||
GO_PKG_TARGET_VARS:=$(filter-out CGO_ENABLED=%,$(GO_PKG_TARGET_VARS)) CGO_ENABLED=0
|
||||
|
||||
@ -75,5 +79,14 @@ ifeq ($(CONFIG_RCLONE_COMPRESS_UPX),y)
|
||||
endif
|
||||
endef
|
||||
|
||||
define Package/rclone/install
|
||||
$(call GoPackage/Package/Install/Bin,$(1))
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/config/
|
||||
$(INSTALL_CONF) $(CURDIR)/files/rclone.config $(1)/etc/config/rclone
|
||||
$(INSTALL_DIR) $(1)/etc/init.d/
|
||||
$(INSTALL_BIN) $(CURDIR)/files/rclone.init $(1)/etc/init.d/rclone
|
||||
endef
|
||||
|
||||
$(eval $(call GoBinPackage,rclone))
|
||||
$(eval $(call BuildPackage,rclone))
|
||||
|
@ -77,7 +77,7 @@ start_service() {
|
||||
[ "$enabled" == "1" ] || { _info "Instance \"rclone\" disabled."; return 1; }
|
||||
_info "Instance \"rclone\" start."
|
||||
procd_open_instance
|
||||
procd_set_param command /usr/bin/$APP rcd -vv
|
||||
procd_set_param command /usr/bin/$APP rcd -vv
|
||||
procd_append_param command "--rc-addr=$addr:$port"
|
||||
procd_append_param command "--rc-user=$username" "--rc-pass=$password"
|
||||
procd_append_param command "--config=$config_path"
|
Loading…
Reference in New Issue
Block a user