Skip to content

Conversation

@awasthan
Copy link

Fixed the Helm template so imagePullSecrets is only defined at the pod level (not inside the container), eliminating the warning about spec.template.spec.containers[0].imagePullSecrets.

🐛 Bug-fix PR

Before opening this PR please:

  1. make lint - passes ruff, mypy, pylint
  2. make test - all unit + integration tests green
  3. make coverage - ≥ 90 %
  4. make docker docker-run-ssl or make podman podman-run-ssl
  5. Update relevant documentation.
  6. Tested with sqlite and postgres + redis.
  7. Manual regression no longer fails. Ensure the UI and /version work correctly.

📌 Summary

It fixes the below warning when trying to deploy using helm:
"Warning: unknown field "spec.template.spec.containers[0].imagePullSecrets""

🔁 Reproduction Steps

Run the helm install command to deploy on K8S or OCP cluster.

🐞 Root Cause

The job-migration.yaml file (charts/mcp-stack/templates/job-migration.yaml) has the imagePullSecrets inside 'containers' section; which is incorrect. This is triggering the warning.

💡 Fix Description

Fixed the Helm template so imagePullSecrets is only defined at the pod level (not inside the container), eliminating the warning about spec.template.spec.containers[0].imagePullSecrets.

🧪 Verification

Check Command Status
Lint suite make lint
Unit tests make test
Coverage ≥ 90 % make coverage
Manual regression no longer fails steps / screenshots

📐 MCP Compliance (if relevant)

  • Matches current MCP spec
  • No breaking change to MCP clients

✅ Checklist

  • Code formatted (make black isort pre-commit)
  • No secrets/credentials committed

Fixed the Helm template so imagePullSecrets is only defined at the pod level (not inside the container), eliminating the warning about spec.template.spec.containers[0].imagePullSecrets.
The mcp-gateway-mcp-stack-migration Job is a Helm pre-install hook, so it runs before Helm creates the Postgres Deployment/Service/PVC.
Because Postgres isn’t created yet, the job keeps failing to connect to mcp-gateway-mcp-stack-postgres, and the failed pre-install hook prevents Helm from installing the rest of the resources.
Switched the migration Job to run after install/upgrade so Postgres is already up before migrations run.
@awasthan
Copy link
Author

Also fixed the below issue:
The mcp-gateway-mcp-stack-migration Job is a Helm pre-install hook, so it runs before Helm creates the Postgres Deployment/Service/PVC.
Because Postgres isn’t created yet, the job keeps failing to connect to mcp-gateway-mcp-stack-postgres, and the failed pre-install hook prevents Helm from installing the rest of the resources.
Switched the migration Job to run after install/upgrade so Postgres is already up before migrations run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant