Update Plausible template to v3.1.0 with enhanced ClickHouse configuration#643
Update Plausible template to v3.1.0 with enhanced ClickHouse configuration#643Eetezadi wants to merge 4 commits intoDokploy:canaryfrom
Conversation
…ation - Upgrade Plausible Community Edition from v2.1.5 to v3.1.0 - Update PostgreSQL from 16-alpine to 18-alpine - Update ClickHouse from 24.3.3.102-alpine to 25.12-alpine - Add CLICKHOUSE_SKIP_USER_SETUP environment variable for ClickHouse - Replace ClickHouse config files with optimized configurations: - logs.xml: Query logging with 30-day retention - ipv4-only.xml: Network binding configuration - low-resources.xml: Performance tuning for low-memory environments
built with Refined Cloudflare Pages Action⚡ Cloudflare Pages Deployment
|
There was a problem hiding this comment.
Pull request overview
This PR updates the Plausible Analytics template from v2.1.5 to v3.1.0, including upgrades to PostgreSQL 18 and ClickHouse 25.12, along with reorganized ClickHouse configuration files. The update aims to bring the template in line with Plausible's latest community edition release with enhanced ClickHouse configuration.
Changes:
- Updated Plausible image from v2.1.5 to v3.1.0 and bumped PostgreSQL (16→18) and ClickHouse (24.3→25.12) versions
- Reorganized ClickHouse configuration into three separate XML files (logs.xml, ipv4-only.xml, low-resources.xml) with improved settings for resource-constrained environments
- Updated meta.json to reflect v3.1.0
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 8 comments.
| File | Description |
|---|---|
| meta.json | Version number updated from v2.1.5 to v3.1.0 |
| blueprints/plausible/docker-compose.yml | Updated all service images, reorganized ClickHouse config volume mounts, added ports section, set CLICKHOUSE_SKIP_USER_SETUP=1 |
| blueprints/plausible/template.toml | Restructured ClickHouse configuration into three separate mount files with expanded settings for logging, networking, and resource limits |
| environment: | ||
| - POSTGRES_PASSWORD=postgres |
There was a problem hiding this comment.
The plausible_db service sets POSTGRES_PASSWORD but is missing POSTGRES_DB and POSTGRES_USER environment variables. While PostgreSQL has defaults (user: postgres, db: postgres), it's better to explicitly configure these. The Plausible service will also need a DATABASE_URL environment variable to connect to PostgreSQL. See aptabase blueprint (blueprints/aptabase/docker-compose.yml:8-9, 42) for a similar pattern where both the database and main service have properly configured connection strings.
| [config.env] | ||
| BASE_URL = "http://${main_domain}" | ||
| SECRET_KEY_BASE = "${secret_base}" | ||
| TOTP_VAULT_KEY = "${totp_key}" |
There was a problem hiding this comment.
Missing required ClickHouse connection environment variables for the Plausible service. The PR description mentions "Set required ClickHouse environment variables (DB name, user, password)" but these are not present in the template.toml [config.env] section. Looking at similar blueprints (e.g., aptabase at blueprints/aptabase/docker-compose.yml:43), the Plausible service needs environment variables to connect to the ClickHouse database, such as CLICKHOUSE_DATABASE_URL. Additionally, DATABASE_URL for PostgreSQL connection should also be configured.
| [config.env] | ||
| BASE_URL = "http://${main_domain}" | ||
| SECRET_KEY_BASE = "${secret_base}" | ||
| TOTP_VAULT_KEY = "${totp_key}" |
There was a problem hiding this comment.
The PR description states "Added CLICKHOUSE_FLUSH_INTERVAL_SECONDS and CLICKHOUSE_MAX_BUFFER_SIZE" but these environment variables are not present in the code changes. If these environment variables are required for Plausible v3.1.0 to properly configure ClickHouse, they should be added to the [config.env] section of template.toml.
|
@greptile review |
Additional Comments (1)
|
|
Hey, read our contributing guide https://github.com/Dokploy/templates/blob/canary/CONTRIBUTING.md |
- Remove ports section (Dokploy handles port mapping via template.toml) - Fix mount filePath prefix from / to ./ to match repo conventions - Add explicit DATABASE_URL and CLICKHOUSE_DATABASE_URL env vars
|
Thanks for the review! I've read through the contributing guide and addressed the feedback: Changes made: Removed ports section — Dokploy handles port mapping via template.toml domains version: "3.8" — Deprecated in Docker Compose v2+; no recent template in the repo uses it (aptabase, openpanel, rybbit all omit it) |
Summary
Changes
Greptile Summary
Updated Plausible Analytics from v2.1.5 to v3.1.0-community with enhanced ClickHouse configuration. The template modernizes ClickHouse config files and updates PostgreSQL to v18.
Critical Issues:
version: "3.8"field indocker-compose.yml(violates Dokploy conventions)portsinstead ofexposeindocker-compose.yml(violates Dokploy conventions per AGENTS.md:150)DATABASE_URLandCLICKHOUSE_DATABASE_URL) intemplate.tomlthat Plausible v3.1.0 requires to connect to databasesPositive Changes:
logs.xml,ipv4-only.xml,low-resources.xml)../files/clickhouse/to./clickhouse/for Dokploy compatibilityCLICKHOUSE_SKIP_USER_SETUP=1for proper initializationConfidence Score: 2/5
portsinstead ofexpose(violating Dokploy conventions), and most critically, missing DATABASE_URL and CLICKHOUSE_DATABASE_URL environment variables that Plausible v3.1.0 requires to connect to its databases. Without these connection URLs, the application cannot function.docker-compose.yml(needs version field and expose fix) andtemplate.toml(needs database connection environment variables)Last reviewed commit: 8439269
(4/5) You can add custom instructions or style guidelines for the agent here!
Context used:
dashboard- AGENTS.md (source)