Deploy Your First Agent¶
Work in Progress
This page is currently under development.
Overview¶
This guide walks you through the process of deploying your first agent using AgentCore CLI. You'll learn how to create a simple agent, configure it, and deploy it to Amazon Bedrock AgentCore Runtime.
Prerequisites¶
Before starting, ensure you have:
- Completed the installation steps
- Initialized your project using
agentcore-cli init
- Docker installed and running
Step 1: Create a Simple Agent¶
Let's start by creating a basic agent that responds to prompts. Create the following files:
Dockerfile¶
Docker | |
---|---|
app.py¶
requirements.txt¶
Text Only | |
---|---|
Step 2: Deploy the Agent¶
Now that you have created the agent files, deploy it using AgentCore CLI:
Bash | |
---|---|
This command will:
- Build your Docker image
- Create an ECR repository if it doesn't exist
- Push the image to ECR
- Create an IAM role with necessary permissions
- Deploy the agent runtime on Bedrock AgentCore
Step 3: Test the Agent¶
Test your deployed agent by invoking it:
Bash | |
---|---|
You should see a response similar to:
Step 4: Check Agent Status¶
Check the status of your agent:
Bash | |
---|---|
This will show you:
- The agent's current version
- Available endpoints
- Deployment status
- Resource usage
Next Steps¶
Now that you've deployed your first agent, you can:
- Customize your agent with more advanced functionality
- Learn about agent lifecycle management
- Set up multiple environments
- Implement more sophisticated agents
Troubleshooting¶
If you encounter issues:
- Ensure Docker is running and properly configured
- Verify your AWS credentials are valid
- Check that you have the necessary permissions
- See the troubleshooting guide for more help