diff options
author | Doug Chimento | 2021-04-02 11:27:29 +0300 |
---|---|---|
committer | Doug Chimento | 2021-04-02 11:27:29 +0300 |
commit | b7e8949bb05080198f6ff097050aab6f112e55ca (patch) | |
tree | aac0af2515613373378eace61684352407611ba7 | |
download | aur-b7e8949bb05080198f6ff097050aab6f112e55ca.tar.gz |
init btc-rpc-explorer aur package
-rw-r--r-- | .SRCINFO | 20 | ||||
-rw-r--r-- | PKGBUILD | 29 | ||||
-rw-r--r-- | btc-rpc-explorer.default | 121 | ||||
-rw-r--r-- | btc-rpc-explorer.service | 17 |
4 files changed, 187 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..b2f5fb6d9000 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,20 @@ +pkgbase = btc-rpc-explorer + pkgdesc = Simple, database-free Bitcoin blockchain explorer, via RPC to Bitcoin Core + pkgver = 2.2.0 + pkgrel = 1 + url = https://github.com/janoside/btc-rpc-explorer + arch = any + license = MIT + makedepends = npm + depends = nodejs>=10 + noextract = btc-rpc-explorer-2.2.0.tgz + backup = etc/default/btc-rpc-explorer + source = https://registry.npmjs.org/btc-rpc-explorer/-/btc-rpc-explorer-2.2.0.tgz + source = btc-rpc-explorer.service + source = btc-rpc-explorer.default + sha256sums = f2eabe5e21d9ab7ccef4c0b1a2894ef6c3bc0911a5f704320aff02809a9db7ab + sha256sums = f19d942b6b6789c7deeb076e70eaf140e65a18d9cfe9ceab30cf2c33120e25f3 + sha256sums = 98a6cdcf741807d2cc98825b074a882e520563b7b6528c24d2abd090bc007d0a + +pkgname = btc-rpc-explorer + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..fe05bf9777da --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,29 @@ +# Maintainer: Douglas Chimento <dchimento@gmail.com> +_npmname=btc-rpc-explorer +_npmver=2.2.0 +pkgname=${_npmname} +pkgver=${_npmver} +pkgrel=1 +pkgdesc="Simple, database-free Bitcoin blockchain explorer, via RPC to Bitcoin Core" +arch=(any) +url="https://github.com/janoside/btc-rpc-explorer" +license=("MIT") +depends=("nodejs>=10") +makedepends=("npm") +optdepends=() +backup=("etc/default/${pkgname}") +source=("https://registry.npmjs.org/$_npmname/-/$_npmname-$_npmver.tgz" ${pkgname}.service ${pkgname}.default ) +noextract=("$_npmname-$_npmver.tgz") +sha256sums=('f2eabe5e21d9ab7ccef4c0b1a2894ef6c3bc0911a5f704320aff02809a9db7ab' + 'f19d942b6b6789c7deeb076e70eaf140e65a18d9cfe9ceab30cf2c33120e25f3' + '98a6cdcf741807d2cc98825b074a882e520563b7b6528c24d2abd090bc007d0a') + +package() { + chown -R root:root "${pkgdir}" + npm install -g --prefix "${pkgdir}/usr" --cache "${srcdir}/npm-cache" "${srcdir}/$_npmname-$_npmver.tgz" + + install -Dm640 ${pkgname}.default "${pkgdir}/etc/default/${pkgname}" + install -Dm644 ${pkgname}.service "${pkgdir}/usr/lib/systemd/system/${pkgname}.service" + echo "u ${pkgname} - - /var/lib/${pkgname}" | install -Dm644 /dev/stdin "${pkgdir}"/usr/lib/sysusers.d/"${pkgname}".conf + echo "d /var/lib/${pkgname} 0750 ${pkgname} ${pkgname} -" | install -Dm644 /dev/stdin "${pkgdir}/usr/lib/tmpfiles.d/${pkgname}.conf" +} diff --git a/btc-rpc-explorer.default b/btc-rpc-explorer.default new file mode 100644 index 000000000000..ee5a3d2c2561 --- /dev/null +++ b/btc-rpc-explorer.default @@ -0,0 +1,121 @@ +# Optional logging settings, uncomment one of these example lines or add your own. +# See comments after each for more info. +# Default: "btcexp:app,btcexp:error" +#DEBUG=* # Enable all logging, including middleware +#DEBUG=btcexp:* # Enable all logging specific to btc-rpc-explorer +#DEBUG=btcexp:app,btcexp:error # Default + +# The base URL. If you want to run it elsewhere than on /, for example /btc-rpc-explorer/ - note that the value should include starting and ending "/" +# Default: / +#BTCEXP_BASEURL=/ +#BTCEXP_BASEURL=/explorer/ + +# The active coin. Only officially supported value is "BTC". +# Default: BTC +#BTCEXP_COIN=BTC + +# Host/Port to bind to +# Defaults: shown +#BTCEXP_HOST=127.0.0.1 +#BTCEXP_PORT=3002 + +# Bitcoin RPC Credentials (URI -OR- HOST/PORT/USER/PASS) +# Defaults: +# - [host/port]: 127.0.0.1:8332 +# - [username/password]: none +# - cookie: '~/.bitcoin/.cookie' +# - timeout: 5000 (ms) +#BTCEXP_BITCOIND_URI=bitcoin://rpcusername:rpcpassword@127.0.0.1:8332?timeout=10000 +#BTCEXP_BITCOIND_HOST=127.0.0.1 +#BTCEXP_BITCOIND_PORT=8332 +#BTCEXP_BITCOIND_USER=rpcusername +#BTCEXP_BITCOIND_PASS=rpcpassword +#BTCEXP_BITCOIND_COOKIE=/path/to/bitcoind/.cookie +#BTCEXP_BITCOIND_RPC_TIMEOUT=5000 + +# Select optional "address API" to display address tx lists and balances +# Options: electrumx, blockchain.com, blockchair.com, blockcypher.com +# If electrumx set, the BTCEXP_ELECTRUMX_SERVERS variable must also be +# set. +# Default: none +#BTCEXP_ADDRESS_API=(electrumx|blockchain.com|blockchair.com|blockcypher.com) + +# Optional ElectrumX Servers. See BTCEXP_ADDRESS_API. This value is only +# used if BTCEXP_ADDRESS_API=electrumx +#BTCEXP_ELECTRUMX_SERVERS=tls://electrumx.server.com:50002,tcp://127.0.0.1:50001,... + +# Use the Electrumx server as an external txindex. This is only available in Electrs. +#BTCEXP_ELECTRUM_TXINDEX=true + +# Set number of concurrent RPC requests. Should be lower than your node's "rpcworkqueue" value. +# Note that Bitcoin Core's default rpcworkqueue=16. +# Default: 10 +#BTCEXP_RPC_CONCURRENCY=10 + +# Disable app's in-memory RPC caching to reduce memory usage +# Default: false (i.e. in-memory cache **enabled**) +#BTCEXP_NO_INMEMORY_RPC_CACHE=true + +# Optional redis server for RPC caching +# Default: none +#BTCEXP_REDIS_URL=redis://localhost:6379 + +# Default: hash of credentials +#BTCEXP_COOKIE_SECRET=0000aaaafffffgggggg + +# Whether public-demo aspects of the site are active +# Default: false +#BTCEXP_DEMO=true + +# Set to false to enable resource-intensive features, including: +# UTXO set summary querying +# (default value is true, i.e. resource-intensive features are disabled) +#BTCEXP_SLOW_DEVICE_MODE=false + +# Privacy mode disables: +# Exchange-rate queries, IP-geolocation queries +# Default: false +#BTCEXP_PRIVACY_MODE=true + +# Don't request currency exchange rates +# Default: true (i.e. no exchange-rate queries made) +#BTCEXP_NO_RATES=true + +# Password protection for site via basic auth (enter any username, only the password is checked) +# Default: none +#BTCEXP_BASIC_AUTH_PASSWORD=mypassword + +# File where the SSO token is stored; ignored if BTCEXP_BASIC_AUTH_PASSWORD is provided. +# Enables SSO if present. +# Default: none +#BTCEXP_SSO_TOKEN_FILE=/var/run/btc-rpc-explorer/sso_token + +# URL of an optional external SSO provider +# This is ignored if SSO is not enabled (see BTCEXP_SSO_TOKEN_FILE) +# Default: none +#BTCEXP_SSO_LOGIN_REDIRECT_URL=/my-sso-provider/login + +# Enable to allow access to all RPC methods +# Default: false +#BTCEXP_RPC_ALLOWALL=true + +# Custom RPC method blacklist +# Default: (see config.js) +#BTCEXP_RPC_BLACKLIST=signrawtransaction,sendtoaddress,stop,... + +# Optional API keys +# Default: none +#BTCEXP_GANALYTICS_TRACKING=UA-XXXX-X +#BTCEXP_SENTRY_URL=https://00000fffffff@sentry.io/XXXX +#BTCEXP_IPSTACK_APIKEY=000000fffffaaaaa + +# Optional value for "max_old_space_size" +# Default: 1024 +#BTCEXP_OLD_SPACE_MAX_SIZE=2048 + +# The number of recent blocks to search for transactions when txindex is disabled +#BTCEXP_NOTXINDEX_SEARCH_DEPTH=3 + +# Show tools list in a sub-nav at top of screen +# Default: true +BTCEXP_UI_SHOW_TOOLS_SUBHEADER=true diff --git a/btc-rpc-explorer.service b/btc-rpc-explorer.service new file mode 100644 index 000000000000..0131246bbfc7 --- /dev/null +++ b/btc-rpc-explorer.service @@ -0,0 +1,17 @@ +[Unit] +Description=Simple, database-free Bitcoin blockchain explorer, via RPC to Bitcoin Core +Wants=network.target +Documentation=https://github.com/janoside/btc-rpc-explorer + +[Service] +Type=simple +User=btc-rpc-explorer +Group=btc-rpc-explorer +WorkingDirectory=/var/lib/btc-rpc-explorer +EnvironmentFile=/etc/default/btc-rpc-explorer +ExecStart=btc-rpc-explorer +KillSignal=SIGINT +Restart=on-failure + +[Install] +WantedBy=multi-user.target |