1.0.10 • Published 8 months ago

@lukekarrys/r2d2 v1.0.10

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

R2D2

Ring my R2D2 phone.

   .-""-.
  /[O] __\
 _|__o LI|_
/ | ==== | \
|_| ==== |_|
 ||" ||  ||
 ||LI  o ||
 ||'----'||
/__|    |__\

Usage

Here's how I have this running currently, future Luke:

Sync Files to Server

ssh server "cd /volume1/docker && rm -rf r2d2/ && mkdir r2d2 && cd r2d2 && curl -L https://github.com/lukekarrys/R2D2/tarball/main | tar xzvf - --strip-components=1"

Alternatively run this from this repo on your local machine, to copy everything over before pushing:

rsync -avh . /Volumes/docker/r2d2 --delete --exclude="node_modules/"

Env Vars

ADMIN_USER=USERNAME
ADMIN_SECRET=PASSWORD

Configure and Run Docker Container

./build.sh
./run.sh # ./run.sh --interactive locally to debug stuff

CLI

This connects directly to the Asterisk Manager Interface running inside the Docker container:

npx @lukekarrys/r2d2@latest -h $HOST -u USERNAME -p PASSWORD

Web

Send a POST request to port 8000 on the Docker container with a username and password:

curl $HOST:8000/call -X POST -d "username=USERNAME&password=PASSWORD"

If you only want to be able to hit it via this URL, you can not expose port 5038 in the Dockerfile and run.sh script. The server and AMI are running in the same container.

Obihai Setup

Server server instructions

SIP sip instructions

History

I originally wrote this in 2014 (see the blog post). I wanted to get it working again, so now it's a Docker container and CLI that can be run via npx.

1.0.10

8 months ago

1.0.9

1 year ago

1.0.8

1 year ago

1.0.7

1 year ago

1.0.6

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

1 year ago

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago