From f50bca076b2805216f11a305b272510be10895da Mon Sep 17 00:00:00 2001 From: Elijah DeLee Date: Thu, 1 Oct 2026 16:57:54 -0400 Subject: [PATCH 1/6] feat: add local read replica experiment configuration --- base/compose.yaml | 1 + base/settings.py | 29 ++++++++++++++++++++++++++++- 2 files changed, 29 insertions(+), 1 deletion(-) diff --git a/base/compose.yaml b/base/compose.yaml index e7eaa28..eee9ed2 100644 --- a/base/compose.yaml +++ b/base/compose.yaml @@ -35,6 +35,7 @@ services: volumes: - "{SRC_DIR}:/src:z" - "{OCI_ENV_DIR}:/opt/oci_env:z" + - "{OCI_ENV_DIR}/base/settings.py:/etc/pulp/settings.py:z" - "oci_pulp:/var/lib/pulp" - "oci_redis_data:/data" - "oci_pg_data:/var/lib/pgsql" diff --git a/base/settings.py b/base/settings.py index e81a199..17457d4 100644 --- a/base/settings.py +++ b/base/settings.py @@ -1,2 +1,29 @@ # Pulp needs an /etc/pulp/settings.py with CONTENT_ORIGIN to start. -CONTENT_ORIGIN='http://localhost:80' +import sys +sys.path.insert(0, '/src') +CONTENT_ORIGIN='http://localhost:5001' +DATABASES = { + 'default': { + 'ENGINE': 'django.db.backends.postgresql', + 'NAME': 'pulp', + 'USER': 'postgres', + 'PASSWORD': '', + 'HOST': 'localhost', + 'PORT': 5432, + }, + 'replica': { + 'ENGINE': 'django.db.backends.postgresql', + 'NAME': 'pulp', + 'USER': 'postgres', + 'PASSWORD': '', + 'HOST': 'pulp_pg_replica', + 'PORT': 5432, + }, +} +DATABASE_ROUTERS = ['pulpcore.app.local_read_router.MavenReadReplicaRouter'] +SECRET_KEY='local-pulp-experiment-secret-key' +CACHE_ENABLED=True +MAVEN_PACKAGE_COUNT_CACHE_ENABLED=True +MAVEN_PACKAGE_PAGE_CACHE_ENABLED=True +REDIS_HOST='localhost' +REDIS_PORT=6379 From a6a388ba992fd42c8b9b5a29c1a38324bbfabad3 Mon Sep 17 00:00:00 2001 From: Elijah DeLee Date: Thu, 1 Oct 2026 17:05:17 -0400 Subject: [PATCH 2/6] build: pin local replica experiment base image --- base/Dockerfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/base/Dockerfile b/base/Dockerfile index 4d110d8..095cecf 100644 --- a/base/Dockerfile +++ b/base/Dockerfile @@ -1,4 +1,5 @@ -ARG BASE_IMAGE=ghcr.io/pulp/pulp-ci-centos10:latest +# Pin the development base used by the read-replica experiment; do not use :latest. +ARG BASE_IMAGE=ghcr.io/pulp/pulp-ci-centos10@sha256:38b0c45ae2019d63122f166a2ab27b993f40ecb2d96d69324d4969016b765a27 FROM $BASE_IMAGE # configure S6 to use env variables From 50e17599818224fd2ed69d727ab099225979bcc3 Mon Sep 17 00:00:00 2001 From: Elijah DeLee Date: Thu, 1 Oct 2026 17:08:47 -0400 Subject: [PATCH 3/6] feat: route local Maven reads to PostgreSQL replica --- base/settings.py | 1 + 1 file changed, 1 insertion(+) diff --git a/base/settings.py b/base/settings.py index 17457d4..58c52b0 100644 --- a/base/settings.py +++ b/base/settings.py @@ -21,6 +21,7 @@ }, } DATABASE_ROUTERS = ['pulpcore.app.local_read_router.MavenReadReplicaRouter'] +ENABLED_PLUGINS = ['pulp_file', 'pulp_maven', 'pulp_rpm'] SECRET_KEY='local-pulp-experiment-secret-key' CACHE_ENABLED=True MAVEN_PACKAGE_COUNT_CACHE_ENABLED=True From e8a0a8d9aa2a011ae83b4cbf38568c7e3b26dcd2 Mon Sep 17 00:00:00 2001 From: Elijah DeLee Date: Thu, 1 Oct 2026 17:11:15 -0400 Subject: [PATCH 4/6] docs: mark base image pin as temporary --- base/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/Dockerfile b/base/Dockerfile index 095cecf..ca33ce2 100644 --- a/base/Dockerfile +++ b/base/Dockerfile @@ -1,4 +1,4 @@ -# Pin the development base used by the read-replica experiment; do not use :latest. +# Temporary pin for the read-replica experiment; revert before opening a PR. ARG BASE_IMAGE=ghcr.io/pulp/pulp-ci-centos10@sha256:38b0c45ae2019d63122f166a2ab27b993f40ecb2d96d69324d4969016b765a27 FROM $BASE_IMAGE From b0335ef18b77ab61ed7fff2b138c84794a49e4eb Mon Sep 17 00:00:00 2001 From: Elijah DeLee Date: Thu, 1 Oct 2026 17:12:21 -0400 Subject: [PATCH 5/6] docs: mark replica settings mount for optional profile --- base/compose.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/base/compose.yaml b/base/compose.yaml index eee9ed2..01a9a59 100644 --- a/base/compose.yaml +++ b/base/compose.yaml @@ -35,6 +35,7 @@ services: volumes: - "{SRC_DIR}:/src:z" - "{OCI_ENV_DIR}:/opt/oci_env:z" + # TODO: move replica-specific settings into an optional compose target. - "{OCI_ENV_DIR}/base/settings.py:/etc/pulp/settings.py:z" - "oci_pulp:/var/lib/pulp" - "oci_redis_data:/data" From 88d827de3627c72ee5becb822c545b1ed49f2cf2 Mon Sep 17 00:00:00 2001 From: Elijah DeLee Date: Tue, 3 Nov 2026 22:35:38 -0500 Subject: [PATCH 6/6] Fix pminio image source Use available MinIO-compatible image after the old community image became unavailable and document the AIStor distinction. Assisted-by: pi coding agent --- docs/dev/reference/profiles/pminio.md | 11 ++++++++--- profiles/pminio/README.md | 11 ++++++++--- profiles/pminio/compose.yaml | 4 +++- 3 files changed, 19 insertions(+), 7 deletions(-) diff --git a/docs/dev/reference/profiles/pminio.md b/docs/dev/reference/profiles/pminio.md index 6a04359..29ea8f0 100644 --- a/docs/dev/reference/profiles/pminio.md +++ b/docs/dev/reference/profiles/pminio.md @@ -2,10 +2,15 @@ ## Usage -Adding this profile sets up a Minio instance that is configured as Pulp's S3 backend. The Minio +Adding this profile sets up a MinIO-compatible instance configured as Pulp's S3 backend. The instance is launched as a separate service and can be accessed inside the main container at -`http://pminio:9000`. The Minio Client CLI,`mc`, is also installed and configured inside the main -container to talk to the Minio service. +`http://pminio:9000`. The MinIO Client CLI, `mc`, is also installed and configured inside the +main container to talk to the service. + +The profile uses `quay.io/openshifttest/minio:latest` because the former +`quay.io/minio/minio` community image is no longer pullable. MinIO's current +`quay.io/minio/aistor/minio` repository is AIStor and is not assumed to be a drop-in replacement +for this local profile. If you want to interact with Pulp distributions from your host, add a new entry to `/etc/hosts` on the host machine for the `pminio` alias, like so: diff --git a/profiles/pminio/README.md b/profiles/pminio/README.md index d102f97..ffab549 100644 --- a/profiles/pminio/README.md +++ b/profiles/pminio/README.md @@ -2,10 +2,15 @@ ## Usage -Adding this profile sets up a Minio instance that is configured as Pulp's S3 backend. The Minio +Adding this profile sets up a MinIO-compatible instance configured as Pulp's S3 backend. The instance is launched as a separate service and can be accessed inside the main container at -`http://pminio:9000`. The Minio Client CLI,`mc`, is also installed and configured inside the main -container to talk to the Minio service. +`http://pminio:9000`. The MinIO Client CLI, `mc`, is also installed and configured inside the +main container to talk to the service. + +The profile uses `quay.io/openshifttest/minio:latest` because the former +`quay.io/minio/minio` community image is no longer pullable. MinIO's current +`quay.io/minio/aistor/minio` repository is AIStor and is not assumed to be a drop-in replacement +for this local profile. Do not forget to add a new entry to `/etc/hosts` on the host machine for the `pminio` alias, like so: diff --git a/profiles/pminio/compose.yaml b/profiles/pminio/compose.yaml index ef0ed51..01c145d 100644 --- a/profiles/pminio/compose.yaml +++ b/profiles/pminio/compose.yaml @@ -1,6 +1,8 @@ services: pminio: - image: quay.io/minio/minio + # The old quay.io/minio/minio community image was retired. This public + # MinIO-compatible image keeps the local development profile working. + image: quay.io/openshifttest/minio:latest environment: - "MINIO_ROOT_USER={S3_ACCESS_KEY}" - "MINIO_ROOT_PASSWORD={S3_SECRET_KEY}"