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

Fix/eng 92 cli agent statelink mechanics #3

Merged
merged 4 commits into from
Nov 18, 2024

Conversation

evilsocket
Copy link
Contributor

@evilsocket evilsocket commented Nov 15, 2024

Closes ENG-92:

  • Added a more explicit error message when dreadnode agent push raises a 404 due to a different server profile.
  • Added a new profile sub field to links in order to preemptively check this condition and present a meaningful error message.
  • Aligned unit tests to these changes.

Copy link

linear bot commented Nov 15, 2024

ENG-92 CLI - Agent state/link mechanics

A few general situations we might want to explore for agent management:

  • If we have an existing agent folder prepped with a .dreadnode.yaml, and we try to run agent push against a different server (or a reset local server), we just get 404 on creating the version without great feedback to a user. We might want to catch this, and prompt the user to create the agent again.
  • I'm not sure how far we've gone down handling a configured .dreadnode.yaml file in an agent when it comes to switching profiles, potentially pushing it to different servers, or using it for different strikes as well. I believe we have the links field for this, but we don't store any type of profile or server url in there.

In general, I think we have some of this logic built, but I'm not sure we've wired everything up for all the situations a user might find themselves in when it comes to context switching an agent between servers, strikes, etc.

@evilsocket evilsocket requested a review from monoxgas November 15, 2024 15:08
Copy link
Contributor

@monoxgas monoxgas left a comment

Choose a reason for hiding this comment

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

All looks awesome!

@evilsocket evilsocket merged commit 67e837f into main Nov 18, 2024
3 checks passed
@evilsocket evilsocket deleted the fix/eng-92-cli-agent-statelink-mechanics branch November 18, 2024 10:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants