> For the complete documentation index, see [llms.txt](https://shuttle-1.gitbook.io/shuttle-cobra/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://shuttle-1.gitbook.io/shuttle-cobra/getting-started/quickstart.md).

# Quickstart

### Deploy your project

1. **Configure AWS Credentials** Before deploying, ensure you have authenticated with AWS using one of the following methods:
   * **SSO Enabled**: Use `aws configure sso` for AWS Single Sign-On.
   * **IAM User Account**: Use `aws configure` for standard IAM user credentials.
   * **Temporary IAM Credentials**: Set the following environment variables:

     ```bash
     export AWS_ACCESS_KEY_ID='your_access_key'
     export AWS_SECRET_ACCESS_KEY='your_secret_key'
     export AWS_SESSION_TOKEN='your_session_token'
     ```
   * **Other Options**: IAM role metadata and OIDC federation are also supported.
2. **Install uv for Virtual Environment Management**

   ```bash
   pip install uv
   ```
3. **Navigate to Your Project Directory** Change into the newly created project directory:

   ```bash
   cd <your-project-name>
   ```
4. **Create and Activate a Virtual Environment**

   ```bash
   uv venv
   source .venv/bin/activate
   ```
5. **Add Shuttle Dependency**

   ```bash
   uv init
   uv add shuttle-cobra
   ```
6. **Create Your Shuttle Project** There is no `shuttle init` command for Python projects. Instead, you must create your project files manually.

   Create a `main.py` file: you can use the [built-in user-project example](https://github.com/shuttle-hq/shuttle-cobra/blob/main/user-project/__main__.py) as a starting point.
7. **Deploy Your Project** Deploy your application to the Shuttle platform:

   ```bash
   shuttle deploy
   # or
   uv run -m shuttle deploy
   ```

   Follow the prompts to confirm deployment.
8. **View Application Logs** To view logs from your deployed application:

   ```bash
   shuttle logs
   # or
   uv run -m shuttle logs
   ```
9. **Run Your Project Locally (Optional)** To run your application locally using deployed resources:

   ```bash
   shuttle run
   # or
   uv run -m shuttle run
   ```

   Note: This will execute your application's `main` function (or equivalent entrypoint) and connect to the remote resources provisioned in the cloud.
10. **Destroy Your Project (Cleanup)** When you're finished, you can destroy all provisioned infrastructure and associated resources:

    ```bash
    shuttle destroy
    # or
    uv run -m shuttle destroy
    ```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://shuttle-1.gitbook.io/shuttle-cobra/getting-started/quickstart.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
