Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce Flux Operator CLI #154

Open
wants to merge 7 commits into
base: main
Choose a base branch
from
Open

Introduce Flux Operator CLI #154

wants to merge 7 commits into from

Conversation

stefanprodan
Copy link
Member

@stefanprodan stefanprodan commented Jan 24, 2025

Implement a CLI for building ResourceSet templates locally and for listing, reconciling, suspending and resuming ResourceSets in-cluster.

Examples:

  # Build the given ResourceSet and print the generated objects
  flux-operator build resourceset -f my-resourceset.yaml

  # Build a ResourceSet by providing the inputs from a file
  flux-operator build resourceset -f my-resourceset.yaml \
    --inputs-from my-resourceset-inputs.yaml

  # Pipe the ResourceSet manifest to the build command
  cat my-resourceset.yaml | flux-operator build rset -f -

  # Build a ResourceSet and print a diff of the generated objects
  flux-operator build resourceset -f my-resourceset.yaml | \
    kubectl diff --server-side --field-manager=flux-operator -f -

  # List all ResourceSets
  flux-operator get rset --all-namespaces

  # Reconcile a ResourceSet 
  flux-operator -n apps reconcile rset podinfo

  # Suspend a ResourceSet 
  flux-operator -n apps suspend rset podinfo

  # Resume a ResourceSet 
  flux-operator -n apps resume rset podinfo

@stefanprodan stefanprodan added the area/resourceset ResourceSet related issues and PRs label Jan 24, 2025
@stefanprodan stefanprodan force-pushed the cli branch 3 times, most recently from 7178707 to 36d322a Compare January 24, 2025 13:54
@stefanprodan stefanprodan added the area/cli CLI related issues and pull requests label Jan 31, 2025
@stefanprodan stefanprodan marked this pull request as ready for review January 31, 2025 08:54
@stefanprodan stefanprodan force-pushed the cli branch 2 times, most recently from fcaf42a to df9b8d0 Compare January 31, 2025 08:57
Copy link
Member

@matheuscscp matheuscscp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 🚀

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/cli CLI related issues and pull requests area/resourceset ResourceSet related issues and PRs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants