now running btsync as user "btsync" and with a config file
This commit is contained in:
parent
e4e6a0da5c
commit
352d9161d5
@ -1,8 +1,8 @@
|
||||
AUX btsync.service 101 SHA256 937a6c410d7ac4e6f4a41f1dc336526d7da9785ab748c4c699072cfe4d2ef925 SHA512 d4a3d7e9a5cde85583e2972f067502e36de440e7f0335d8ed300f8006697bebb362f38db2467793f1eccb414f71d4e681914f6cc8dc3bb2f5754165e48acc4ee WHIRLPOOL 5b5503eaec550f6a46c758e59a5b43ca3f2483f6804eeed3fcefb5e9c3955f063e0c3a9daa03f29438aa69fbb19a9c36c67543648fb605e83e1c2cad93807bfc
|
||||
AUX config 1810 SHA256 5e2405ad3931123d1c1d05d2e45ed5c57e3dc23a16e46b87a6129434185cedd9 SHA512 f894c0456a71c72f9d90f31b24e853595e0360d18e1a9c5e448ff30e93e4366310896144cf4c72ba6de3d8d0dfc904024fbb6ed765cc3eb55f2baaf5f7de6644 WHIRLPOOL 46b4352e79ad560c3e0b5f644c6a4fa264e1484f065f0a8f95785d92bc2635d9ad20c50478d76564f07672496878515b825d75eb84b8a29bc7d48ec3331244a5
|
||||
AUX btsync.service 223 SHA256 38cd401694c27ddaedee6378b837802805d89efd6ab88a8163d26f0c1646bd5f SHA512 9fdb4b201381adc41b3c5f19ac40e5b56713d810e4548f0825aa6c86a6750cb75550f7a0873ecdc5db7d95aed636cba873b31480e777257b641a6e74be4b3164 WHIRLPOOL b1b748a9b72308014e2378e23e838887057c276259973c6fe1751b3f4e2005d4f09b9a034c7631d0cab3bb3e09b3be5dc5734ff251776db739542c3e770a650c
|
||||
AUX config 1803 SHA256 e3508d0f6cfb6e686bf8edc4feba031ee15f5f080e1719f263a1340a3c3c9a49 SHA512 4fcd57bf912f7cb35c079d902e05e9239ad3333b6a5075b913efc73074eb9640238022b829147766b28c00837ed495ed3aa7c711ce3b2967cbf90c216cf34e0b WHIRLPOOL 08d90413e31673c433f6e3c362b96e84231d87ee6331cde60410f69cd4d6b4915a99a2f30dad7024268608d4750a11f7e258721211484b213c7fa9321b3d6a61
|
||||
AUX init.d/btsync 804 SHA256 023bd5c1f36b17af6c81343279fb7a4314e9172663ed8da35fb6731ecc47cb76 SHA512 4238f89b41019fb73f5a328e05d687785d946b80694787a17ffdcc020be71df7a7751479659f82c890e674679bc5b5b4b208a9c48b8926433f9d979fab3cb983 WHIRLPOOL ab167800ebc416474614866ae9c708e8546c6abcb25dc464c95c67f4f2355ce77503f6045572c55772e8fba00a15b0db8cbcbd09dc16abae1d5eb5447c705575
|
||||
DIST btsync_arm-1.1.70.tar.gz 1279220 SHA256 d79b3cf1881fcab95614693569c950d07dd93ffb70cefd901963dec54b75a05b SHA512 321079de894170eafdd8f923f2e1bfd0909904d350b678707f67566ed0afd1ef8af333270b791d6a429774d7e454da4ef064b417be36b338de2e53599e699bd3 WHIRLPOOL f6499199eae078bc7609aa190a61800866dffbc40fcf08f1ae65456ab6ebf36123e5542b3bbff39f0e61d7ae7161d97684ebed3f091145a90e6eb0b789d3db41
|
||||
DIST btsync_i386-1.1.70.tar.gz 1367784 SHA256 25161852b8eaddf50ae385771f79bac47818467bc5cabc539a64d985e8af4dc6 SHA512 ac18a91a2d9549388541c2c7dabcae1e8b04534115d3c7e5d93b3fe984c801ebdeed931d63d59e7e7e767587fe42d2bb80e6833127b4cf475d30130314f5c864 WHIRLPOOL a5b12b32a521b7f730b8e9cd1505ac4b7ccd56f0d5f91a1988192b32a539a48380d040d6485327153051708c4d5919d517202d90aaf3c8033bdb730b72981314
|
||||
DIST btsync_powerpc-1.1.70.tar.gz 1451029 SHA256 7d68783020627a019363c20d776aaf017bde023886989cac4bd96528fdae9faf SHA512 7f0e22d1cf10e7ebbae78e43cbd84d4d4de2b20478a6605534ee4c04ade68b2bbdea33049a9861cfd53badc4e7e7b2ff24e35c3156d3cf62a8828300094ba5ba WHIRLPOOL ab33985672e29c69c7aaa9729c93dd35a78152fde6b64adaba8a04f93f3ef4006defe240d127e33f6f348a7b825a3ce2e642228f43beb64ecd2fb811f300bdf3
|
||||
DIST btsync_x64-1.1.70.tar.gz 1449204 SHA256 7197ac1a23ff593b1cc6ef124cb2555376aac4637f368483ed2e0d5230b3dec2 SHA512 768f960935cacd1ccc655e9182ada0ddf61d4b8fd0dc8a5386182a46014e6bd11f1743a78884f17b9d3b04d6668bb98c56bce8019c902a216ed26d65a60492c7 WHIRLPOOL 6261713d643ef0eb9816837975a0d0af534819cf978de8370b088c93bd86770f3053c0976e27aee32fc00b0ecf1a9a01cf083e95c1325dcd632896a6e6b5bf2c
|
||||
EBUILD btsync-1.1.70.ebuild 1071 SHA256 bab2a3146a266774901ed3dc8fae1298bba0fcb9db88cffbd7f62c533d3ff940 SHA512 76924af233e5aedb9b67decb77c421894aac25f7bb151df9575f400b0f6cff5c3762a0707da5c52d70422e7c4ded7a766e9e0c7a38964bcfa35565f87057b299 WHIRLPOOL b0900b18360e6eb71450e93db143ad4c33a09d7417ab988958a3cb668425bd20062647cd18965c79703a689badfee9638afe74f008d50457e41eadf06f79199f
|
||||
EBUILD btsync-1.1.70.ebuild 1034 SHA256 bbde434f5d386a5ae287e66e3df6528118618062a912ec7382b2045473571b60 SHA512 d82ab18e2b612230cfa999bad7d76176890732ddee833ecef86a80d41a707d7885970b26bf921c4d745d824f70d86a8a5b20cca25c44d711cb490ac8dd956209 WHIRLPOOL ec5bd5f2b904f31a4b5d9ce595b76b8890071069aa576839bac71f079b8a04ef664ec142c7286b56e67dc9f7f8230a5b933d857654390e83ea2ab823089ea071
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
EAPI="4"
|
||||
|
||||
inherit systemd
|
||||
inherit systemd user
|
||||
|
||||
DESCRIPTION="Automatically sync files via secure, distributed technology."
|
||||
HOMEPAGE="http://labs.bittorrent.com/experiments/sync.html"
|
||||
@ -22,20 +22,21 @@ IUSE=""
|
||||
DEPEND=""
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
QA_PREBUILT="opt/btsync/${PN}"
|
||||
QA_PREBUILT="opt/${PN}/${PN}"
|
||||
|
||||
S="${WORKDIR}"
|
||||
|
||||
pkg_setup() {
|
||||
enewgroup btsync
|
||||
enewuser btsync -1 -1 -1 "btsync"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
mkdir -p ${D}/opt/${PN} && cd ${D}/opt/${PN}
|
||||
mkdir -p ${D}/etc/{init.d,${PN}}
|
||||
|
||||
cp ${S}/btsync .
|
||||
cp ${S}/LICENSE.TXT .
|
||||
cp ${FILESDIR}/config ${D}/etc/${PN}
|
||||
cp ${FILESDIR}/init.d/${PN} ${D}/etc/init.d/
|
||||
|
||||
# Set more secure permissions
|
||||
chmod 755 ${D}/etc/init.d/btsync
|
||||
systemd_dounit "${FILESDIR}"/${PN}.service
|
||||
}
|
||||
exeinto "/opt/${PN}"
|
||||
doexe btsync
|
||||
insinto "/etc/${PN}"
|
||||
doins "${FILESDIR}/config"
|
||||
doinitd "${FILESDIR}/init.d/${PN}"
|
||||
systemd_dounit "${FILESDIR}"/btsync.service
|
||||
fowners -R btsync:btsync /opt/${PN}
|
||||
}
|
||||
|
@ -1,7 +1,12 @@
|
||||
[Unit]
|
||||
Description=Bittorent Sync service
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/opt/btsync/btsync --nodaemon
|
||||
User=btsync
|
||||
Group=btsync
|
||||
ExecStart=/opt/btsync/btsync --config /etc/btsync/config --nodaemon
|
||||
Restart=on-abort
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
||||
|
@ -7,11 +7,10 @@
|
||||
where binary is located.
|
||||
otherwise user-defined directory will be used
|
||||
*/
|
||||
"storage_path" : ".sync",
|
||||
"storage_path" : "/opt/btsync",
|
||||
|
||||
// uncomment next line if you want to set location of pid file
|
||||
"pid_file" : "/var/run/btsync.pid",
|
||||
|
||||
// "pid_file" : "/var/run/btsync.pid",
|
||||
|
||||
"check_for_updates" : true,
|
||||
"use_upnp" : true, // use UPnP for port mapping
|
||||
@ -29,8 +28,8 @@
|
||||
"webui" :
|
||||
{
|
||||
"listen" : "0.0.0.0:8888",
|
||||
// "login" : "admin",
|
||||
// "password" : "password"
|
||||
"login" : "",
|
||||
"password" : ""
|
||||
}
|
||||
|
||||
/* !!! if you set shared folders in config file WebUI will be DISABLED !!!
|
||||
|
Loading…
x
Reference in New Issue
Block a user