# Docker Compose

## Environment Preparation

Install `docker` and `docker-compose` using the [installer](https://docs.docker.com/compose/install/#install-compose) or via your Operating System's package manager (`pacman`, for example), then launch the service.

## `cortex-starter` Preparation <a href="#cortex-starter-prep" id="cortex-starter-prep"></a>

As `cortex` itself is only a Rails Engine, it needs to be mounted within a parent Rails applicaton. [cortex-starter](https://github.com/cortex-cms/cortex-starter) serves as a starting point for new users, with `cortex` and `cortex-plugins-core` already mounted and configured with several example `ContentTypes`/`Decorators`. Start by cloning the repository:

```bash
$ git clone git@github.com:cortex-cms/cortex-starter.git && cd cortex-starter
```

## Provision & Launch Application

Provision and launch Cortex Starter, PostgreSQL, Redis, Elasticsearch, Sidekiq and live Webpack rebuild via Docker Compose:

```bash
$ docker-compose up
```

Once complete, the admin interface will be accessible locally at `http://localhost:3000`. To access Cortex CMS as superadmin, login as `admin@cortexcms.org` with password `welcome1`.


---

# Agent Instructions: 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:

```
GET https://docs.cortexcms.org/basics/setup/docker-compose.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
