https://prefect.io logo
Title
b

Bastian Röhrig

10/14/2021, 10:09 AM
Hey everyone, I can't get agent automations in prefect cloud to work. When I setup an agent automation, it asks me to create or choose an agent config. I tried to pass on the name of this config to my agent on startup with the
--agent-config-id
flag, however that does not work because the
prefect agent docker start
command expects that flag to contain an id. Can anyone help me with that?
a

Anna Geller

10/14/2021, 10:26 AM
Hi @Bastian Röhrig, the process is described in the docs here. 1. First, you have to go to the automations tab in the UI and set up an agent configuration as part of your Automation. 2. You’ll see the
agent config id
that is provided once your automation is created. This is a UUID. 3. You can then start your agent and pass this UUID to the agent start command:
prefect agent docker start --agent-config-id your-uuid
b

Bastian Röhrig

10/14/2021, 11:07 AM
Thank you, that worked 🙂 Follow up question: Is there a way I can delete agent configs in the ui? (I created several for testing purposes)
a

Anna Geller

10/14/2021, 11:15 AM
Nice work! I believe if you delete it this way, the config ID will be gone as well, since it seems to be coupled with the automation.
b

Bastian Röhrig

10/14/2021, 11:27 AM
I just tried that, but I can still select the old superfluous agent configs when I create a new agent automation. That is not really a problem for me though.
a

Anna Geller

10/14/2021, 11:29 AM
Gotcha. You can probably do it using GraphQL mutation on
agent_config
schema.
:upvote: 1
b

Bastian Röhrig

10/14/2021, 1:22 PM
Thank you for the GraphQL hint, I ended up deleting my old agent configs like that.
👍 1