Skip to content

Document the plone/nick container image - #2119

Merged
ericof merged 2 commits into
6.0from
issue-2118
Oct 31, 2026
Merged

ericof merged 2 commits into
6.0from
issue-2118

Conversation

@ericof

@ericof ericof commented Oct 31, 2026

Copy link
Copy Markdown
Member

The plone/nick image is published, but the Containers section doesn't mention it. This adds docs/install/containers/images/nick.md and lists it among the official images.

The new page covers:

  • what the image is, and how its tags move, including that published images are rebuilt in place, so an exact build needs the image digest
  • running Nick with PostgreSQL, with DB_PASSWORD and SECRET as the required settings
  • a Docker Compose stack that splits Nick into migrate, api and worker containers
  • configuration, and building your own image with add-ons, with ADDONS for trying them out only

The Compose stack lives on the image page, as it does for plone/aurora, rather than under examples/. Nick's deployment guidance stays in the Nick documentation, which the page links to.

Note for reviewers: without PROFILES, the image installs the demo site with an admin user whose password is admin. The page warns about this because it matters for anyone copying the examples to production.

The README's plain docker run example sets DB_HOST=db but starts no database that the container can reach under that name, so it fails with a host lookup error. The page creates a Docker network and a PostgreSQL container first, and runs Nick on that network.

Closes #2118

Add a page for the official plone/nick image: its tags, running it with
PostgreSQL, a Docker Compose stack that splits the migrate, api and worker
modules, selecting modules, the configuration variables and add-ons.
The deployment guide of Nick is linked, not repeated.

Add the image to the official images table and the toctree.

Refs #2118
sneridagh
sneridagh previously approved these changes Oct 31, 2026
@github-project-automation github-project-automation Bot moved this from New to Approved in Plone Documentation Oct 31, 2026
The docker run flow kept the database and uploaded files in the
container, so removing a container lost them. Create the nick-data and
nick-blobs volumes and mount them on the database and on Nick, and
explain what each volume holds and what removing it deletes.

The Compose section now says what its volumes hold and that
docker compose down -v deletes them.

Refs #2118
@ericof

ericof commented Oct 31, 2026

Copy link
Copy Markdown
Member Author

I'm merging as the dlr.de SSL failure is probably temporary

@ericof
ericof merged commit 34dd9b8 into 6.0 Oct 31, 2026
2 of 4 checks passed
@ericof
ericof deleted the issue-2118 branch October 31, 2026 03:08
@github-project-automation github-project-automation Bot moved this from Approved to Done in Plone Documentation Oct 31, 2026

@stevepiercy stevepiercy left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merged too quick. Would you please incorporate these changes, and see my questions? Thank you!


- `3.0` points to the newest 3.0.x release.
- `3` points to the newest 3.x release.
- `latest` points to the version in the `version.txt` file of the repository.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- `latest` points to the version in the `version.txt` file of the repository.
- `latest` points to the version in the {file}`version.txt` file of the repository.

- `latest` points to the version in the `version.txt` file of the repository.

A prerelease, such as `3.1.0-alpha.1`, gets only its own tag.
It does not move `latest`, `3` or `3.0`.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
It does not move `latest`, `3` or `3.0`.
It does not move `latest`, `3`, or `3.0`.

Then use the digest in place of the tag, as `plone/nick@sha256:<digest>`.


## Using this image

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
## Using this image
## Usage
This section describes how to use the `plone/nick` image.

### Run with PostgreSQL

The image runs `nick`, which migrates the database, installs the profiles, and starts the API on port 8080 and the job worker.
Set `DB_PASSWORD` and `SECRET`; the container stops at startup if either one is missing.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How should these be set?


A named volume is storage that Docker manages, and it outlives the container that uses it.
The `nick-data` volume keeps the database, and the `nick-blobs` volume keeps the uploaded files in the default `file` blob storage.
Without them, removing a container removes the data it holds.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Without them, removing a container removes the data it holds.
With these named volumes, it's possible to remove the container without removing the data and files it holds.

Read the [Add-ons](https://nick.docs.plone.org/developer-guide/addons) chapter of the Nick documentation for how to write one.

The `ADDONS` variable installs add-ons every time the container starts.
Use it only to try an add-on out, and build an image for production.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Use it only to try an add-on out, and build an image for production.
Use it only to try out an add-on, and build an image for production.

ENV PROFILES=@plone/nick:core,@acme/nick-addon:default
```

Read the [Add-ons](https://nick.docs.plone.org/developer-guide/addons) chapter of the Nick documentation for how to write one.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got intersphinx? Not sure what Nick uses to build docs.

| `/app/config.ts` | A `config.ts` file mounted at this path replaces the environment configuration. |

Nick reads other settings from the environment as well.
For the full list, and for the settings of a production deployment, see the [Deployment](https://nick.docs.plone.org/admin-guide/deployment) guide in the Nick documentation.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got intersphinx? Not sure what Nick uses to build docs.

| `NICK_MODULES` | Modules to run: `migrate`, `api` or `worker`, separated by commas. Default: all of them. |
| `PORT` | Port where the API listens. Default: `8080`. |
| `ALLOWED_ORIGINS` | Origins that CORS allows, such as the address of the frontend. |
| `BLOBS_DIR` | Directory of the `file` blob storage. Default: `/app/var/blobstorage`. Mount a volume there, or use the `db` or `s3` blob storage. |

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
| `BLOBS_DIR` | Directory of the `file` blob storage. Default: `/app/var/blobstorage`. Mount a volume there, or use the `db` or `s3` blob storage. |
| `BLOBS_DIR` | Directory of the `file` blob storage. Default: {file}`/app/var/blobstorage`. Mount a volume there, or use the `db` or `s3` blob storage. |


The `migrate` module exits with a non-zero status when it hits errors.
Each command needs the database and secret variables from the previous section.
To set the modules with an environment variable instead, use `-e NICK_MODULES=api`.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
To set the modules with an environment variable instead, use `-e NICK_MODULES=api`.
To set the modules with an environment variable instead.
For example, for the `api` module, use the following:
```shell
docker run plone/nick -e NICK_MODULES=api
```

@github-project-automation github-project-automation Bot moved this from Done to In Progress in Plone Documentation Oct 31, 2026
ericof added a commit that referenced this pull request Oct 31, 2026
Follow-up to #2119 with the changes stevepiercy requested. Say how to
pass the required variables, show the commands that remove containers
and volumes, and put the environment variable option before the image
name, where docker run reads it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

Document usage of plone/nick container

3 participants