Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion base/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
ARG BASE_IMAGE=ghcr.io/pulp/pulp-ci-centos10: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

# configure S6 to use env variables
Expand Down
2 changes: 2 additions & 0 deletions base/compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ 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"
- "oci_pg_data:/var/lib/pgsql"
Expand Down
30 changes: 29 additions & 1 deletion base/settings.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,30 @@
# 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']
ENABLED_PLUGINS = ['pulp_file', 'pulp_maven', 'pulp_rpm']
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
11 changes: 8 additions & 3 deletions docs/dev/reference/profiles/pminio.md
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down
11 changes: 8 additions & 3 deletions profiles/pminio/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down
4 changes: 3 additions & 1 deletion profiles/pminio/compose.yaml
Original file line number Diff line number Diff line change
@@ -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}"
Expand Down