# Odoo installation

### Доп информация

* Odoo на Docker HUB - <https://hub.docker.com/_/odoo/>

### Получение из репы образа Odoo

```
git clone --depth=1 -b master --single-branch https://github.com/litnimax/odoo-dokku.git
```

### Запускаем базу

#### Создаем постоянное хранилище для базы данных

```
docker volume create dbdata
```

Запускаем образ Postgres

```
docker run -d -e POSTGRES_USER=odoo -e POSTGRES_PASSWORD=odoo \
    -v dbdata:/var/lib/postgresql/data --name db postgres:9-alpine
```

### Запускаем Odoo

Создаем том для хранения данных сессий и атачей:

```
docker volume create odoodata
```

Создаем скрипт запуска

```
docker run --rm -it --link db:db -p 127.0.0.1:8069:8069 -v `pwd`/addons/:/mnt/extra-addons/ \
        -v odoodata:/var/lib/odoo \
        -e ODOO_ARG_DATABASE=test1 -e ODOO_ARG_DB_USER=odoo -e ODOO_ARG_DB_PASSWORD=odoo \
        -e ODOO_ARG_DB_HOST=db delme $@
```

Запускаем Odoo

```
./run.sh
```

### Запуск Odoo после добавления или обновления модуля

```bash
odoo -u modulename -d db_name
```

## TODO - Добавить секцию под docker-compose.


---

# 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://comlib.gitbook.io/odoo/odoo-installation.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.
