Skip to main content

Running and removing instances

Listing and inspecting

Remote or localagainst prod-1
# odoocli instance list --server prod-1
Remote or localagainst prod-1
# odoocli instance info --instance acme
Remote or localagainst prod-1
# odoocli instance size --instance acme

Starting and stopping

Remote or localagainst prod-1
# odoocli instance container start --instance acme
Remote or localagainst prod-1
# odoocli instance container stop --instance acme
Remote or localagainst prod-1
# odoocli instance container restart --instance acme

A shell inside the instance container, for when you need Odoo's own tooling:

Remote or localagainst prod-1
# odoocli instance container shell --instance acme

Images

Each instance runs an image built for its Odoo version. You can rebuild it, list what exists and switch which one the instance uses.

Remote or localagainst prod-1
# odoocli instance image build --instance acme
Remote or localagainst prod-1
# odoocli instance image list --instance acme
Remote or localagainst prod-1
# odoocli instance image activate --instance acme
A corrupt local image layer does not repair itself

Pulling again reuses the existing blob. If an image is damaged, remove the image and prune the builder cache before pulling, or the same broken layer comes straight back.

nginx

The instance's nginx site is generated from its configuration. If the site and the configuration have drifted, rebuild it:

Remote or localagainst prod-1
# odoocli instance nginx config rebuild --instance acme

Repair

Remote or localagainst prod-1
# odoocli instance repair filesystem --instance acme

Repair fixes the instance's directory tree and permissions. It is the right first move when an instance runs but cannot write, and the wrong move for anything database-shaped.

Removing

Remote or localagainst prod-1
# odoocli instance remove --instance acme
Removal drops the instance's databases

Removing an instance removes its container, its data tree and the databases it owns. Take a backup first, and be certain the instance's active database is the one you think it is - see the import warning in Configuration.