Skip to content

Commit

Permalink
Added remir
Browse files Browse the repository at this point in the history
  • Loading branch information
Kixunil committed Nov 6, 2020
1 parent 9116492 commit abedef7
Show file tree
Hide file tree
Showing 8 changed files with 98 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ endif

.DELETE_ON_ERROR:

SOURCES=bitcoin bitcoin-rpc-proxy electrs electrum lnd nbxplorer btcpayserver ridetheln selfhost tor-extras thunderhub btc-rpc-explorer lndconnect lnpbp-testkit selfhost-dashboard
SOURCES=bitcoin bitcoin-rpc-proxy electrs electrum lnd nbxplorer btcpayserver ridetheln selfhost tor-extras thunderhub btc-rpc-explorer lndconnect lnpbp-testkit selfhost-dashboard remir

include common_vars.mk

Expand All @@ -39,7 +39,7 @@ clean:
include common_rules.mk

build-dep:
sudo apt-get build-dep -a $(DEB_ARCH) $(realpath $(BITCOIN_DIR) $(BITCOIN_RPC_PROXY_BUILD_DIR) $(ELECTRS_BUILD_DIR) $(ELECTRUM_BUILD_DIR) $(TOR_EXTRAS_BUILD_DIR) $(LND_BUILD_DIR) $(NBXPLORER_BUILD_DIR) $(BTCPAYSERVER_BUILD_DIR) $(SELFHOST_BUILD_DIR) $(RIDETHELN_BUILD_DIR) $(LNPBP_TESTKIT_BUILD_DIR))
sudo apt-get build-dep -a $(DEB_ARCH) $(realpath $(BITCOIN_DIR) $(BITCOIN_RPC_PROXY_BUILD_DIR) $(ELECTRS_BUILD_DIR) $(ELECTRUM_BUILD_DIR) $(TOR_EXTRAS_BUILD_DIR) $(LND_BUILD_DIR) $(NBXPLORER_BUILD_DIR) $(BTCPAYSERVER_BUILD_DIR) $(SELFHOST_BUILD_DIR) $(RIDETHELN_BUILD_DIR) $(LNPBP_TESTKIT_BUILD_DIR) $(REMIR_BUILD_DIR))

test: $(TEST_DEPS)

Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,7 @@ Supported and planned applications
- [ ] joinmarket
- [ ] joinmarket-mainnet
- [x] lnpbp-testkit (framework for testing LNP/BP applications)
- [x] remir (a simple server for controlling IR devices; not freedom related, but why not?)
- [ ] translations
- [x] all services for regtest
- [ ] all services for signet
Expand Down
9 changes: 9 additions & 0 deletions build_rules/remir.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
pkg_name_upper: REMIR
pkg_name_snake: remir
source_name: remir

clone_url: https://github.com/Kixunil/remir
git_tag: v$(REMIR_VERSION)
fingerprint: 3D9E81D3CA76CDCBE768C4B4DC6B4F8E60B8CF4C
verify_tag: true
build_system: python3
15 changes: 15 additions & 0 deletions docs/user-level.md
Original file line number Diff line number Diff line change
Expand Up @@ -245,3 +245,18 @@ BTC RPC Explorer is a very powerful Bitcoin explorer that uses your own full nod
* **You must have a working domain pointing to your node for `selfhost-clearnet` to work!**
* `selfhost-clearnet-certbot` is installed by default and **needs a working e-mail address** for receiving **important security notifications**!
* `selfhost-clearnet-certbot` will create a TLS certificate for you so that HTTPS works.

### remir

#### About

A simple server for controlling IR-enabled devices.

#### Usage

Your device MUST have a LIRC-capable IR transmitter!
I recommend using Raspberry Pi with `lirc_rpi` configured.
Just install the package and either pick a password or let it generate a random one.
The password will also be stored in /var/run/remir/password.
After you've configured LIRC, open your browser using selfhost domain, followed by
`remir` root path (default is `/remir`) followed by slash and the password.
6 changes: 6 additions & 0 deletions pkg_specs/python3-remir.sps
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name = "python3-remir"
architecture = "all"
summary = "A simple server for controlling IR-enabled devices."
depends = ["${python3:Depends}", "${misc:Depends}", "lirc"]
recommends = ["remir"]
add_files = ["/usr/bin/remir", "/usr/lib/python3.7/dist-packages/remir", "/usr/lib/python3.7/dist-packages/remir-0.1.0.egg-info"]
5 changes: 5 additions & 0 deletions pkg_specs/remir.changelog
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
remir (0.1.0-1) buster; urgency=medium

* Added Debian package

-- Martin Habovstiak <[email protected]> Fri, 6 Nov 2020 14:40:50 +0100
53 changes: 53 additions & 0 deletions pkg_specs/remir.sps
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name = "remir"
summary = "A simple server for controlling IR-enabled devices. (service package)"
bin_package = "python3-remir"
binary = "/usr/bin/remir"
conf_param = "--conf"
user = { group = true, create = { home = false } }
recommends = ["selfhost"]
extra_triggers = ["/etc/lirc/lircd.conf.d"]
extra_service_config = """
Restart=always
RuntimeDirectory=remir
"""

[config."remir.toml"]
format = "toml"

[config."remir.toml".ivars.password]
type = "string"
default = ""
priority = "high"
summary = "Password to access remir (empty generates random)"
ignore_empty = true

[config."remir.toml".ivars.port]
type = "bind_port"
default = "8123"
priority = "medium"
summary = "Port for remir to listen on"

[config."remir.toml".ivars.bind_address]
type = "bind_host"
default = "127.0.0.1"
priority = "medium"
summary = "Address for remir to listen on"
ignore_empty = true

[config."../selfhost/apps/remir.conf"]
format = "yaml"
external = true
with_header = true

[config."../selfhost/apps/remir.conf".ivars.root_path]
type = "string"
default = "/remir"
priority = "medium"
summary = "Web prefix of web path to remir"

[config."../selfhost/apps/remir.conf".evars.remir.port]
name = "port"

[config."../selfhost/apps/remir.conf".hvars.rewrite]
type = "bool"
constant = "true"
7 changes: 7 additions & 0 deletions pkg_specs/remir.sss
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name = "remir"
section = "net"
build_depends = ["python3-all", "dh-python", "python3-setuptools", "python3-bottle", "python3-toml"]
packages = ["python3-remir", "remir"]
skip_debug_symbols = true
with = ["python3"]
buildsystem = "pybuild"

0 comments on commit abedef7

Please sign in to comment.