Skip to main content

VGS Client

Project description

VGS CLI

CircleCI

Command Line Tool for programmatic configurations on VGS.

Official Documentation

Table of Contents

Requirements

Python 3 or Docker.

Installation

PyPI

Install the latest version from PyPI:

pip install vgs-cli

Run

Verify your installation by running:

vgs --version

Running in Docker

In order to run in Docker we recommend declaring the following docker-compose.yaml:

version: '3'
services:

  cli:
    image: quay.io/verygoodsecurity/vgs-cli:${VERSION:-latest}
    stdin_open: true # docker run -i
    tty: true        # docker run -t
    env_file:
      - .env
    command: bash
    ports:
      - "7745:7745"
      - "8390:8390"
      - "9056:9056"

First, you start the lightweight cli container in detached mode by executing:

docker-compose up -d cli

Then proceeding with login:

docker-compose exec cli vgs login

And now you are ready to execute any vgs cli command:

docker-compose exec cli vgs logs access -V tntmiph5i0n

To use auto login option you can declare the following .env file:

VGS_CLIENT_ID=<YOUR-CLIENT-ID>
VGS_CLIENT_SECRET=<YOUR-CLIENT-SECRET>

Alternatively, you can set the environment variables right in the docker-compose.yaml:

version: '3'
services:

  cli:
    image: quay.io/verygoodsecurity/vgs-cli:${VERSION:-latest}
    stdin_open: true # docker run -i
    tty: true        # docker run -t
    environment:
      VGS_CLIENT_ID: <YOUR-CLIENT-ID>
      VGS_CLIENT_SECRET: <YOUR-CLIENT-SECRET>
    command: bash
    ports:
      - "7745:7745"
      - "8390:8390"
      - "9056:9056"

Run a specific version:

VERSION=[VERSION] docker-compose up -d

You can turn on debugging by appending -d or --debug right after vgs:

docker-compose exec cli vgs --debug logs access -V tntmiph5i0n

Commands

Sphinx Documentation

In order to generate Sphinx documentation:

pip install -r dev-requirements.txt
cd docs
make html

Check the generated docs:

open build/html/index.html

Plugins Development

See Click - Developing Plugins.

In order to develop a plugin you need to register your commands to an entrypoint in setup.py.

Supported entrypoints:

  • vgs.plugins - for extending vgs with sub-commands
  • vgs.get.plugins - for extending vgs get with sub-commands
  • vgs.apply.plugins - for extending vgs apply with sub-commands
  • vgs.logs.plugins - for extending vgs logs with sub-commands

Example:

entry_points='''
    [vgs.plugins]
    activate=vgscliplugin.myplugin:new_command
    
    [vgs.get.plugins]
    preferences=vgscliplugin.myplugin:new_get_command
'''

Project details


Release history Release notifications | RSS feed

This version

1.6.2

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vgs-cli-1.6.2.tar.gz (17.3 kB view details)

Uploaded Source

File details

Details for the file vgs-cli-1.6.2.tar.gz.

File metadata

  • Download URL: vgs-cli-1.6.2.tar.gz
  • Upload date:
  • Size: 17.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4

File hashes

Hashes for vgs-cli-1.6.2.tar.gz
Algorithm Hash digest
SHA256 1c57268a0f8e921462617656aa1600ee7de95c91f1be6931efaedfcda158ceec
MD5 dd48a10cb7e996542e5f76485ef95807
BLAKE2b-256 7af63e24038024a485d40588f8b352aff0366f42c628c37ba9cced66c33d2721

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page