1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

iotlab-support: use iotlab command to check credentials

Since the `iotlab-term` target uses `tmux` error messages are not really
printed, so it took me a while to find out why at some sites this target
wasn't working for me anymore.

If the IoT-LAB password was changed, just checking if `.iotlabrc`
exists isn't enough, so I use `iotlab-experiment` to check if I'm logged
in properly to prompt the password input in case I'm not.
This commit is contained in:
Martine Lenders 2018-07-17 13:02:50 +02:00
parent 7f6fe21b93
commit ad65aadb37

View File

@ -72,7 +72,8 @@ iotlab-stop: $(IOTLAB_AUTH) iotlab-check-exp
$(Q)iotlab-experiment stop -i $(IOTLAB_EXP_ID)
iotlab-term: iotlab-check-exp
$(Q)ssh -t $(IOTLAB_AUTHORITY) "test -f ~/.iotlabrc || iotlab-auth -u $(IOTLAB_USER)"
$(Q)ssh -t $(IOTLAB_AUTHORITY) "iotlab-experiment get -r > /dev/null || \
iotlab-auth -u $(IOTLAB_USER)"
$(Q)ssh -t $(IOTLAB_AUTHORITY) \
"tmux attach -t riot-$(IOTLAB_EXP_ID) || tmux new -s riot-$(IOTLAB_EXP_ID) \