Skip to main content

CG DevX CLI

The CG DevX CLI simplifies the initial setup of the CG DevX reference architecture. This setup process is intended to be executed from an operator's machine and will create a local folder containing tools, temporary, and configuration files. All subsequent commands should be executed from the same machine, as they rely on data created during the setup process.

Getting Started

Required Installations

  • Python 3.10 + pip
  • Poetry version 1.6.*

If you do not have Poetry installed, follow the official installation instructions here: Poetry Installation.

# Assumed directory: GITROOT/tools
# Note: Poetry configuration and lock files are stored in the 'cli' directory.

# To install dependencies, use:
poetry install

# To activate the virtual environment, use:
# By default, Poetry creates a virtual environment in {cache-dir}/virtualenvs
poetry shell

Local development

Code Style

Run the command to validate code style:

flake8

To run provisioning using a local dev version of repository, instead of cloning GitOps template repo, you could use environment variable CGDEVX_CLI_CLONE_LOCAL=True

Build the CLI Tool

To build the CLI tool, use PyInstaller:

# Current directory: GITROOT/tools
python -m PyInstaller --onefile cli/__main__.py --name cgdevxcli

Alternatively, you can build with PyInstaller via a Python script:

# Current directory: GITROOT/tools
poetry run build

After building, you can use and distribute cgdexvcli located at GITROOT/dist/cgdevxcli.

Using CG DevX CLI

To run a Python script via Poetry, use the snippet below:

 # Current directory: GITROOT/tools
poetry run cgdevxcli

Or, use a version built using the steps above:

# Current directory: GITROOT/tools
./dist/cgdevxcli

The usage pattern is [OPTIONS] COMMAND [ARGS].

CG DevX CLI Supports the Following: Options:

  • --help Shows the help message

Commands:

  • setup - Creates a new CG DevX installation.
  • destroy - Destroys an existing CG DevX installation.
  • workload - Manages workloads with the following subcommands:
    • create - Generates configuration for key workload resources.
    • bootstrap - Bootstraps a workload with configuration templates.
    • delete - Removes configuration for key workload resources.

Arguments: Arguments are command-specific and can be supplied via the command line, environment variables, or a file.

For more details, please check CG DevX quickstart commands and workload commands

Metadata

Release files for cgdevxcli 0.6.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cgdevxcli 0.6.0
File Size Uploaded
cgdevxcli-0.6.0.tar.gz 89.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for cgdevxcli 0.6.0
File Interpreter ABI Platform
cgdevxcli-0.6.0-py3-none-any.whl Python 3 none any Details

Total release size: 206.2 kB

Release files / cgdevxcli-0.6.0.tar.gz

Download URL cgdevxcli-0.6.0.tar.gz
Size 89.3 kB
Tags Source
SHA-256 checksum
How to use checksums
942c26e058706f2aa3afa064f2560fdd3126d79b53e28c9c325b4e1a2e96f2cb
BLAKE2b-256 checksum
How to use checksums
1321f70e548936707d2e108612ffcf8c9aa3b0c6595c0cb2fdd842fb1b138962
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.12.3 Linux/6.11.0-1018-azure

Release files / cgdevxcli-0.6.0-py3-none-any.whl

Download URL cgdevxcli-0.6.0-py3-none-any.whl
Size 116.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4167883fc07a8400ef80ca32e3fbc661a4e9a749726430f7541728d139908dd7
BLAKE2b-256 checksum
How to use checksums
8b6a5869fe0d3f2d6c5c17fdbd2446ce86312d413b27da3975d54e3a1788f32e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.12.3 Linux/6.11.0-1018-azure

Release history Release notifications | RSS feed

This release

0.6.0 This release

2 release files

0.5.0

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.1

2 release files

0.3.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page