Difference between revisions of "Umbrel - Installing BoS"
m (Telegram Bot) |
|||
Line 1: | Line 1: | ||
==Installing BOS== | ==Installing BOS== | ||
These are the commands to enter in a command line interface for Umbrel - (once you have ssh'd into your umbrel, you can follow these steps): | These are the commands to enter in a command-line interface for Umbrel - (once you have ssh'd into your umbrel, you can follow these steps): | ||
Step 1: Install npm | === Step 1: Install npm === | ||
<code>sudo apt install npm </code> | <code>sudo apt install npm </code> | ||
Line 9: | Line 9: | ||
Step 2: Install Balance of Satoshis | === Step 2: Install Balance of Satoshis === | ||
<code> sudo npm install -g balanceofsatoshis | <code> sudo npm install -g balanceofsatoshis | ||
Line 26: | Line 26: | ||
Step 3: Create the credentials file: | === Step 3: Create the credentials file: === | ||
<code> sudo nano credentials.json </code> | <code> sudo nano credentials.json </code> | ||
Line 41: | Line 41: | ||
} | } | ||
</code> | </code> | ||
=== Step 4: Installing Telegram Bot === | |||
Gp to Telegram | |||
Start chat with [https://t.me/BotFather @BotFather] | |||
press | |||
<code>/start | |||
/newbot | |||
</code> | |||
Decide A bot name <code>NodeAliasNew</code> | |||
Decide a bot user name for telegram <code>BotName_bot</code> | |||
You will get a long alphanumeric API KEY for the bot, Note that. You can always retrieve it using <code>/mybot</code> with BotFather | |||
Now you will be at a connect key prompt. Go to next step before pressing anything. | |||
Now come back to your node | |||
On your SSH session | |||
bos telegram | |||
at first prompt type API key (alpha numeric) received from BotFather | |||
In telegram go to your bot (link in BotFather window usually @BotName_bot | |||
type <code>/connect</code> | |||
you will get a numeric key | |||
type that numeric key on the second prompt in your ssh session with <code> bos telegram </code> | |||
You should get a connected message in your Telegram Bot as well as on SSH session. | |||
Verify by typing <code>/version</code> in your telegram bot and you should see the version number of bos. | |||
Press Ctrl-C in SSH session with <code> bos telegram </code> | |||
Now run it as | |||
<code> | |||
nohup bos telegram --connect <numeric key from telegram bot> | |||
</code> | |||
This will run your telegram bot even if you come out of your ssh session. | |||
Instead of nohuup you can also run it under TMUX if you are familiar. |
Revision as of 15:20, 7 August 2021
Installing BOS
These are the commands to enter in a command-line interface for Umbrel - (once you have ssh'd into your umbrel, you can follow these steps):
Step 1: Install npm
sudo apt install npm
Step 2: Install Balance of Satoshis
sudo npm install -g balanceofsatoshis
sudo apt update
curl -sL https://deb.nodesource.com/setup_16.x | sudo -E bash -
sudo apt-get install -y nodejs
mkdir -p .bos/umbrel/
cd .bos/umbrel
Step 3: Create the credentials file:
sudo nano credentials.json
and paste the following inside:
{
"cert_path": "/home/umbrel/umbrel/lnd/tls.cert",
"macaroon_path": "/home/umbrel/umbrel/lnd/data/chain/bitcoin/mainnet/admin.macaroon",
"socket": "localhost:10009"
}
Step 4: Installing Telegram Bot
Gp to Telegram
Start chat with @BotFather
press
/start
/newbot
Decide A bot name NodeAliasNew
Decide a bot user name for telegram BotName_bot
You will get a long alphanumeric API KEY for the bot, Note that. You can always retrieve it using /mybot
with BotFather
Now you will be at a connect key prompt. Go to next step before pressing anything.
Now come back to your node
On your SSH session bos telegram at first prompt type API key (alpha numeric) received from BotFather
In telegram go to your bot (link in BotFather window usually @BotName_bot
type /connect
you will get a numeric key
type that numeric key on the second prompt in your ssh session with bos telegram
You should get a connected message in your Telegram Bot as well as on SSH session.
Verify by typing /version
in your telegram bot and you should see the version number of bos.
Press Ctrl-C in SSH session with bos telegram
Now run it as
nohup bos telegram --connect <numeric key from telegram bot>
This will run your telegram bot even if you come out of your ssh session.
Instead of nohuup you can also run it under TMUX if you are familiar.