This tool should help to simply distribute applications to a raspberry pi and provide a simple lifecycle management.
usage: tap <command> [<args>]
apps List all applications
upload <app-name> <artifact-name> Upload new application
delete <app-name> Delete application
start <app-name> Start application
stop <app-name> Stop application
env <app-name> run Show run script of the application
env <app-name> vars Show variables of the application
set-env <app-name> <env-file> Uses <env-file> as environment file for the application
An application is a folder which contains the application artifacts and an executable file run.sh
,
which starts the application.
With the set-env
command, you can define environment variables which are accessible by the run script
or by your application. The environment parameters will not be overwritten, when you upload your application
for an update.
Define variables in the following way (don't miss the 'export'):
export VAR_NAME="VALUE"
This tool is just a bunch of shell scripts on the client. All the work is done via ssh
and scp
. On the
server side, there are just the application artifacts and some needed config files, which are created for the
purpose.
Add the src/
directory to the PATH
.
You have to configure some values in the file src/tap.cfg
user
: the ssh userremoteHost
: the host to connect toremotePort
: the port of the remote hostremoteAppBase
: the folder in which all the applications should be stored
You have to authorize your ssh key on your raspberry:
ssh-copy-id -i ~/.ssh/<mykey> <user>@<host>
You have to create the remoteAppBase
folder on the server manually.
To get this thing running ssh
and scp
is used multiple times for a command. So, to not enter
the credentials every time, enter your credentials for the ssh-agent:
ssh-add
If there is no running ssh-agent, start it before with (and ssh-add
again):
eval "$(ssh-agent)"
- Bash on client side (should also work with Windows Subsystem for Linux)
- Raspberry Pi in local network
- as a developer I want to deploy and manage my own application on the raspberry
- I want to use my windows notebook to
upload
,start
,stop
, ... applications on the raspberry - I don't want to
ssh
every time to the raspberry to do this stuff