Running App Services
Before running the Edge Xpert Application Service you need a configuration file. See App Services Configuration for more information
Once you have created a configuration file you can start, stop and manage the Application Service by:
- Using the Edge Xpert UI, see Manage the Application Service in the Edge Xpert Manager
- Using the Edge Xpert CLI, described below:
Create and Start the Application Service
Create the Application Service
To create the Application Service use the p
command along with the app-service
argument, specifying the path to the configuration toml file with the --path/-p
flag. For example,
edgexpert up app-service –path <path to configuration toml file>
where the <path to configuration toml file>
points to the configuration toml file you are using.
If you do not specify the -p or –path flag then the Application Service will not be created.
Multiple configuration files can be specified using the comma character ',' as a seperator.
For example, the following command creates and starts the Application Service for app-service-config-app-1 and app-service-config-app-2.
edgexpert up app-service --path=./config-app-1.toml,./config-app-2.toml
Note
The Application Service takes its name from the configuration file name so these need to be unique.
Start the Application Service
Once the Application Service is created, for subsequent runs you can start the Application Service by using the start
command along with the app-service
argument.
If no configuration toml file is specified with the --path /-p
flag all the stopped Edge Xpert Application Services will be started.
#Start specific application service
edgexpert start app-service --path=./config-app-1.toml
#Start all stopped application services
edgexpert start app-service
Restart the Application Service
If you want to restart an Application Service that is already running you can use the restart
command along with the app-service
argument.
If no confguration file is specified with the --path /-p
flag all the running Application Services will be restarted.
# Restart specific application service
edgexpert restart app-service --path=./config-app-1.toml
# Restart all stopped application services
edgexpert restart app-service
Stop and Delete the Application Service
Stop the Application Service
To stop a running Application Service use the stop
command along with the app-service
argument.
If no configuration toml file is specified with the `--path/-p' flag all running Edge Xpert application services will stop.
# Stop specific application service
edgexpert stop app-service --path=./config-app-1.toml
# Stop all running application services
edgexpert stop app-service
Stop and Delete the Application Service
To stop and delete a running Application Service use the down
command along with the app-service
argument.
If no configuration toml file is specified with the --path/-p
flag all running Edge Xpert application services will be stopped and deleted.
# Stop and delete specific application service
edgexpert down app-service --path=./config-app-1.toml
# Stop and delete all application services
edgexpert down app-service
Delete the Application Service
To delete a stopped application service use the rm
command along with the app-service
argument.
If no configuration toml file is specified with the --path/-p
flag, all running Edge Xpert application services will be deleted.
edgexpert rm app-service --path=./config-app-1.toml
Export the Application Service Logs
To export the log of a specific application service, use the logs
command along with the app-service
argument.
edgexpert logs app-service --path=./config-app-1.toml -o /tmp
Note
The Edge Xpert Application Service lauches in secure mode when the secret store 'Vault' is up. Vault is up when either --secret
or ---api-gateway
is specified with the up
command. When the Application Services are launched in secure mode the Application Services will attempt to access secrets from the Vault. As a result, all secrets required by the Application Services should be stored in the Vault. For more details about storing secrets in the secret store, refer to Secret Store