pulp-operator icon indicating copy to clipboard operation
pulp-operator copied to clipboard

custom_pulp_settings config map requires double quotation

Open StopMotionCuber opened this issue 4 months ago • 0 comments

Version Pulp Operator 1.0.1

Describe the bug When using custom_pulp_settings on the Operator, that requires quoting. Otherwise python processes complain about syntax errors.

To Reproduce Steps to reproduce the behavior:

  1. Add the following ConfigMap
apiVersion: v1
kind: ConfigMap
metadata:
  name: pulp-custom-config
  namespace: pulp-operator
data:
  CONTENT_ORIGIN: "https://repo.home-organization.com/"
  1. Add pulp_custom_config: pulp-custom-config to the Pulp CRD.

Expected behavior The new content origin is accepted and properly quoted inserted into the secret at settings.py.

Actual behavior I get a Syntax error, as this is rendered as

CONTENT_ORIGIN = https://repo.home-organization.com/

within the settings.py

Additional context This can be worked around using double quotation on the yaml file:

apiVersion: v1
kind: ConfigMap
metadata:
  name: pulp-custom-config
  namespace: pulp-operator
data:
  CONTENT_ORIGIN: '"https://repo.home-organization.com/"'

But that wouldn't be something that I would expect. Additionally I'm a bit puzzled why this was not catched in testing, as it looks to me like you would directly stumble upon this issue

StopMotionCuber avatar Aug 29 '25 15:08 StopMotionCuber