Skip to content

Latest commit

 

History

History
84 lines (63 loc) · 2.91 KB

client.md

File metadata and controls

84 lines (63 loc) · 2.91 KB

RUN-DSP client usage

Introduction

RUN-DSP comes with its own client subcommand. This command will execute miscellaneous tasks on your RUN-DSP instance. These will vary from dataspace operations to administrative functions, even though only dataspace operations are implemented at this time.

Dependencies

The client depends on a running RUN-DSP instance, with the control service enabled, as this client does all its operations via or on this instance. This client will not do dataspace operations itself, but offloads those to RUN-DSP.

Client configuration

The client is configurable via a configuration file, environment variables, and command line flags. Some flags (like json output) are flags only.

Command line flags

You can see all command line options and subcommands by running:

./run-dsp client --help

All subcommands also accept the --help flag.

Configuration file

We supply a reference configuration file that documents all configuration keys, and their corresponding environment variables. RUN-DSP will by default search for the configuration in /etc/run-dsp/run-dsp.toml, but you can supply any with the -c flag.

Usage examples

All client subcommands inherit the client connection configuration from the client subcommand. This is normally configured in the configuration file or via environment variables, but can also be given via flags. For example like this:

./run-dsp client \
    --address run-dsp.example.org:8080 \
    --authorization-metadata "Bearer abcde" \
    --ca-cert ./ca.pem \
    --client-cert ./client.pem \
    --client-cert-key ./client.key \
    getcatalog http://participant.example.org

In the following examples we assume that the client connection is set in the default configuration file.

To get the catalog from participant.example.org:

./run-dsp client getcatalog http://participant.example.org

To get information about a single dataset with ID 5918b04a-1989-44f6-bbc0-a4df4d21ba67 from participant.example.org:

./run-dsp client getdataset http://participant.example.org urn:uuid:5918b04a-1989-44f6-bbc0-a4df4d21ba67`

To download the dataset with ID 5918b04a-1989-44f6-bbc0-a4df4d21ba67 from participant.example.org:

./run-dsp client downloaddataset http://participant.example.org urn:uuid:5918b04a-1989-44f6-bbc0-a4df4d21ba67`