diff --git a/README.md b/README.md index d2a7c565..65eb8899 100644 --- a/README.md +++ b/README.md @@ -523,6 +523,15 @@ HolmesGPT can consult webpages containing runbooks or other relevant information HolmesGPT uses playwright to scrape webpages and requires playwright to be installed and working through `playwright install`. +
+ +ArgoCD + + +Holmes can use the `argocd` CLI to get details about the ArgoCD setup like the apps contifuration and status, clusters and projects within ArgoCD. +To enable ArgoCD, set the `ARGOCD_AUTH_TOKEN` environment variable as described in the [argocd documentation](https://argo-cd.readthedocs.io/en/latest/user-guide/commands/argocd_account_generate-token/). +
+ ## More Use Cases HolmesGPT was designed for incident response, but it is a general DevOps assistant too. Here are some examples: diff --git a/holmes/config.py b/holmes/config.py index ed99b302..5006aed2 100644 --- a/holmes/config.py +++ b/holmes/config.py @@ -124,6 +124,7 @@ def create_tool_executor( ) enabled_toolsets = [ts for ts in matching_toolsets if ts.is_enabled()] + print(f"toolsets={str([ts.name for ts in enabled_toolsets])}") for ts in all_toolsets: if ts not in matching_toolsets: console.print( diff --git a/holmes/plugins/prompts/_general_instructions.jinja2 b/holmes/plugins/prompts/_general_instructions.jinja2 index c35a8e18..52b8952c 100644 --- a/holmes/plugins/prompts/_general_instructions.jinja2 +++ b/holmes/plugins/prompts/_general_instructions.jinja2 @@ -37,4 +37,3 @@ Special cases and how to reply: * Issues are a subset of findings. When asked about an issue or a finding and you have an id, use the tool `fetch_finding_by_id`. * For any question, try to make the answer specific to the user's cluster. ** For example, if asked to port forward, find out the app or pod port (kubectl decribe) and provide a port forward command specific to the user's question -* If you need to use ArgoCD tools, ask the user for their argocd auth_token if they haven't given it yet diff --git a/holmes/plugins/toolsets/argocd.yaml b/holmes/plugins/toolsets/argocd.yaml index 9becd438..5411a61a 100644 --- a/holmes/plugins/toolsets/argocd.yaml +++ b/holmes/plugins/toolsets/argocd.yaml @@ -6,32 +6,32 @@ toolsets: tools: - name: "argocd_app_get" description: "Retrieve information about an existing application, such as its status and configuration" - command: "argocd app get {{ app_name }} --show-operation -o yaml --auth-token {{ auth_token }}" + command: "argocd app get {{ app_name }} --show-operation -o yaml" - name: "argocd_app_diff" description: "Display the differences between the current state of an application and the desired state specified in its Git repository" - command: "argocd app diff {{ app_name }} --auth-token {{ auth_token }}" + command: "argocd app diff {{ app_name }}" - name: "argocd_app_list" description: "List the applications in Argocd" - command: "argocd app list --auth-token {{ auth_token }}" + command: "argocd app list" - name: "argocd_app_history" description: "List the deployment history of an application in ArgoCD" - command: "argocd app history {{app_name}} --app-namespace {{namespace}} --auth-token {{ auth_token }}" + command: "argocd app history {{app_name}} --app-namespace {{namespace}}" - name: "argocd_repo_list" description: "List all the Git repositories that ArgoCD is currently managing" - command: "argocd repo list --auth-token {{ auth_token }}" + command: "argocd repo list" - name: "argocd_proj_list" description: "List all available projects" - command: "argocd proj list {{ project_name }} --auth-token {{ auth_token }}" + command: "argocd proj list {{ project_name }}" - name: "argocd_proj_get" description: "Retrieves information about an existing project, such as its applications and policies" - command: "argocd proj get {{ project_name }} --auth-token {{ auth_token }}" + command: "argocd proj get {{ project_name }}" - name: "argocd_cluster_list" description: "List all known clusters" - command: "argocd cluster list --auth-token {{ auth_token }}" + command: "argocd cluster list"