Skip to main content

CAST AI SE CLI (cast-ai-se-cli package | se-cli tool)

PyPI version License Code Style

GitHub Issues GitHub release

Introduction / Overview

This project aims to serve as swiss knife intended to serve CAST AI SEs. Assisting with demo environment prep, providing snapshot analysis and many others in the future. The CLI tool is based on a modular architecture and leverages API orchestration tools package -> cast-ai-se-tools

Table of Contents

Installation

To install, run:
pip install cast-ai-se-cli
or forced:
pip install cast-ai-se-cli --force-reinstall

To upgrade, run:
pip install --upgrade cast-ai-se-cli
or forced:
pip install --upgrade --force-reinstall cast-ai-se-cli

Usage

For some of the functions(commands) the tool offers a configuration file is required (config.json).
First time running the tool if file is not found, the tool would create an empty template file.
The user is required to fill fields required to automate sequences related to the chosen command.
The template comes with additional default parameters that can found here

High-Level:

CLI commands:

se-cli demo <prep|off> <eks|aks|gcp> [--cluster_id <cluster_id>] [-h|--help] [-d|--debug]
se-cli snapshot <analyze> <brief|detailed> [--cluster_id <cluster_id>] [-h|--help] [-d|--debug]
se-cli audit <analyze> [--cluster_id <cluster_id>] [-h|--help] [-d|--debug]

CLI commmands explained:

se-cli demo <prep|off> <eks|aks|gcp>
  • demo command is used to either prep a demo environment:
    Use the config.json data to get the cluster into a specific node count (default=7)
    with specific replicated demo replicas (default=2) and then delete previous nodes Turning off a cluster would be invoking the hibernation cronjob.

  • The subcommand <eks|aks|gcp> is to determine which cluster will be prep`ed or turned off.\

    se-cli snapshot <brief|detailed>

  • snapshot command is used to either generate a brief or detailed report of workloads that have some effect on scheduling:

  • nodeSelector

  • topologySpreadConstraints

  • affinity

  • runtimeClassName

  • pdb`s

Workloads analyzed:

  • deployments
  • replicaSets
  • daemonSets
  • statefulSets
  • jobs

The detailed report includes the namespaces and names of workloads

Options:

-h, --help  Show this help message and exit.
-d, --debug  Enable debug logging.
-c, --cluster_id <cluster_id>  (Optional) Specify the cluster ID for the demo environment.

Command->Outcome:

se-cli demo prep :

Alt Text

se-cli demo off :

Alt Text

Hitting a timeout:

Alt Text

se-cli audit analyze :

Contributing

Contributions are welcome! To contribute, follow these steps:

git clone project as first step create features/fixes by applying a simple <TYPE(fix/feature...)>/<INITIATING_USER>-<FEATURE/FIX-NAME> branch do not forget to update version and open a PR Please make sure CI process that enforces light flake8 lint passes (flak8 and other helper script can be found in helper_script folder)

License

This project is licensed under the APACHE License.

Roadmap

  • Version 0.1.0: First semi-major release end of 2023 Q4 - tested and vetted demo functionality
  • Version 0.2.0: Second semi-major release to support snapshots analysis
  • Version 0.3.0: Third semi-major to integrate with solution-engineering tool
  • Version 1.0.0: First Major release tested and vetter all other previous releases (end of 2024 Q1)

Metadata

Release files for cast-ai-se-cli 0.0.34

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

Source distribution (sdist)

Source distribution for cast-ai-se-cli 0.0.34
File Size Uploaded Provenance
cast_ai_se_cli-0.0.34.tar.gz 16.3 kB Without provenance Details

Release files / cast_ai_se_cli-0.0.34.tar.gz

Download URL cast_ai_se_cli-0.0.34.tar.gz
Size 16.3 kB
Tags Source
SHA-256 checksum
How to use checksums
71295022d84617b93ebd2a714811cf6d794f58eb6a92d095c462f01d3312138e
BLAKE2b-256 checksum
How to use checksums
a166ccb78d42074febb9b64b960b5da9be34a768ad87caf8bbe1f91cdd03b1d5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.11.10

Security for cast-ai-se-cli 0.0.34

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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