> ## Documentation Index
> Fetch the complete documentation index at: https://docs.superblocks.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Local Docker

> Estimated deployment time: 2 minutes

export const Alert = ({type, title, children}) => {
  const variant = ["info", "success", "warning", "danger", "note"].includes(type) ? type : "note";
  return <div className={`alert alert--${variant}`}>
      <div className="alert-icon" />
      <div className="alert-content">
        {title && <div className="alert-title">{title}</div>}
        <div className="alert-body">{children}</div>
      </div>
    </div>;
};

For testing purposes, you can install the agent on your local machine with [Docker Compose](https://docs.docker.com/compose/install/) following these steps.

<Alert type="warning">
  Meant for testing only. A local deployment means you are the only user who can access the agent from Superblocks. To deploy the agent for use across your organization, use one of the <a href="/enterprise/hybrid-architecture/deployment/">production deployment methods</a>.
</Alert>

## Install and run container on your machine

<Alert type="info">
  To generate a <code>SUPERBLOCKS\_AGENT\_KEY</code>, go to the Superblocks <a href="https://app.superblocks.com/opas">Setup Wizard</a>.
</Alert>

```bash theme={null}
curl -s https://charts.superblocks.com/agent/compose.yaml | \
SUPERBLOCKS_AGENT_KEY="<YOUR_AGENT_KEY>" \
SUPERBLOCKS_AGENT_HOST_URL="http://localhost:8080" \
SUPERBLOCKS_AGENT_DATA_DOMAIN="app.superblocks.com" \
SUPERBLOCKS_DOCKER_AGENT_TAG="latest" \
docker compose -p superblocks -f - up
```

<Alert type="info">
  If you use the EU Superblocks instance, set <code>SUPERBLOCKS\_AGENT\_DATA\_DOMAIN</code> to <code>eu.superblocks.com</code>.
</Alert>

## Connect to a local database

To connect your agent to a locally running database, you must specify `host.docker.internal` in the Superblocks integration config, not `localhost`. More on this [here](/integrations/troubleshooting/troubleshooting-databases#testing-with-hybrid-using-localhost).
