argos/docs/cli.md

4 KiB
Raw Blame History

Command-line interface

The argos cli

Usage: argos [OPTIONS] COMMAND [ARGS]...

Options:
  --help  Show this message and exit.

Commands:
  agent    Get and run tasks to the provided server.
  server
  version

Agent command

Usage: argos agent [OPTIONS] SERVER_URL AUTH

  Get and run tasks to the provided server. Will wait for new tasks.

  Usage: argos agent https://argos.example.org "auth-token-here"

  Alternatively, you can use the following environment variables to avoid
  passing arguments to the agent on the command line:

      ARGOS_AGENT_SERVER_URL=https://argos.example.org
      ARGOS_AGENT_TOKEN=auth-token-here

Options:
  --max-tasks INTEGER             Number of concurrent tasks this agent can run
  --wait-time INTEGER             Waiting time between two polls on the server
                                  (seconds)
  --log-level [DEBUG|INFO|WARNING|ERROR|CRITICAL]
  --help                          Show this message and exit.

Server commands

Usage: argos server [OPTIONS] COMMAND [ARGS]...

Options:
  --help  Show this message and exit.

Commands:
  cleandb         Clean the database (to run routinely)
  generate-token  Generate a token, which can be used as an agents...
  migrate         Run database migrations
  reload-config   Read tasks configuration and add/delete tasks in database...
  start           Starts the server

Server start

Usage: argos server start [OPTIONS]

  Starts the server

Options:
  --host TEXT     Host to bind
  --port INTEGER  Port to bind
  --config TEXT   Path the the configuration file
  --reload        Enable hot reloading
  --help          Show this message and exit.

Server migrate

Usage: argos server migrate [OPTIONS]

  Run database migrations

Options:
  --config TEXT  Path the the configuration file
  --help  Show this message and exit.

Server cleandb

Usage: argos server cleandb [OPTIONS]

  Clean the database (to run routinely)

  - Removes old results from the database.
  - Removes locks from tasks that have been locked for too long.

Options:
  --max-results INTEGER       Number of results per task to keep
  --max-lock-seconds INTEGER  The number of seconds after which a lock is
                              considered stale, must be higher than 60 (the
                              checks have a timeout value of 60 seconds)
  --config TEXT  Path the the configuration file
  --help                      Show this message and exit.

Server reload-config

Usage: argos server reload-config [OPTIONS]

  Read tasks configuration and add/delete tasks in database if needed

Options:
  --config TEXT  Path the the configuration file
  --help  Show this message and exit.

Server generate-token command

Usage: argos server generate-token [OPTIONS]

  Generate a token, which can be used as an agents authentication token.

  Its actually an UUID

Options:
  --help  Show this message and exit.