Installing and using the V3 stack as a private service - I've got stuck


(Mrpackethead) #1

Hi, i’ve been trying today to install the V3 gateway stack, but running into a problem at step 1.
Docker, docker-compose are installed, and i’m using the docker-compose.yml file that is in teh git repo.
Im getting this error. ( debian 9 server )

admin@ip-172-31-30-168:~$ docker-compose pull
ERROR: yaml.scanner.ScannerError: mapping values are not allowed here
in “./docker-compose.yml”, line 529, column 26
admin@ip-172-31-30-168:~$

Any ideas whats causing this…


#2

see also the slack channel for V3 - https://thethingsnetwork.slack.com/messages/CFVF7R4AH/


(Mrpackethead) #4

So, I’ve bumbled through this… having never used docker before, its a first!

I’ve installed the v3 stack on an Amazon EC2 micro.t2 instance which is running debian version 9. The instructions are mostly good, In the getting started guide, it says to use the provided. docker-compose.yml . I had assumed ( wrongly ) that docker would pull all the files it needs when you use this. that is not the case, you needed to have cloned the github repo first. (doh). Once you’ve done that, then the instructions work as expected.

I’ll submit a pull request with the addition of a single line in the README.md file under prerequisites;

  • Clone the lorawan stack from github

git clone https://github.com/TheThingsNetwork/lorawan-stack.git

because it was installed in AWS, I did need to consider what network ports are configured for the security groups. The details are usefully in docs/networking.md

While I was able to register a single App, and a device, and point a single gateway to it, Its a bit more ‘raw’ than the public interface ( which is very polished ).

Things i need to work out;

How do you set up the network server so it runs like a service ( like any normal service ) any time it gets rebooted
How to see joins/data etc like you can on the public interface
how to more effectively add/remove devices/apps etc. It seems quite long winded to use the docker-compose commands. I have not figured out how to use the CLI on this.

Anyway it seems like progress


(Mrpackethead) #5

I’m still struggling with the CLI. I hope someone is able to point me in the right direction.

I followed the instructions at https://github.com/TheThingsNetwork/lorawan-stack/blob/master/doc/gettingstarted.md#login to login.

This is what i did, and the response i got. Since I dont’ have a local browser on the server, i connected to this address using the url https://mypublicip:8885[ can you modify something so it uses publicly reachable names? ]

admin@ip-172-31-30-168:~/lorawan-stack$ docker-compose exec stack ttn-lw-cli login
INFO Please go to https://localhost:8885/oauth/authorize?client_id=cli&response_type=code
INFO Waiting for your authorization…
oauth/authorize?client_id=cli&response_type=code
INFO Got OAuth access token
admin@ip-172-31-30-168:~/lorawan-stack$

The message “Got OAuth access token” was displayed in the web browser, and the on the console of the Server, i get the prompt back.

Whats next? How do i use this CLI? Are the commands for the CLI like the ones suggested like this?

docker-compose exec stack ttn-lw-cli end-devices create --device-id dev1 --dev-eui 0004A30B001C0530 --join-eui 800000000000000C --application-id app1 --frequency_plan_id EU_863_870 --root_keys.app_key.key 752BAEC23EAE7964AF27C325F4C23C9A --lorawan_phy_version 1.0.2-b --lorawan_version 1.0.2

Is there any more documetation? At this point i’m stuck, my google foo has run out of power, ( I’m thinking i’m searching for the wrong thign ).