Skip to content

Enhance MCPServer with emptyDir#62

Merged
k8s-ci-robot merged 2 commits into
kubernetes-sigs:mainfrom
aliok:2026-03-24-empty-volumes
Mar 27, 2026
Merged

Enhance MCPServer with emptyDir#62
k8s-ci-robot merged 2 commits into
kubernetes-sigs:mainfrom
aliok:2026-03-24-empty-volumes

Conversation

@aliok

@aliok aliok commented Mar 24, 2026

Copy link
Copy Markdown
Member

Fixes #43

Looks like this:

apiVersion: mcp.x-k8s.io/v1alpha1
kind: MCPServer
metadata:
  name: mcpserver-with-emptydir
  namespace: default
spec:
  config:
    storage:
      # EmptyDir for cache with larger size limit
      - path: /tmp/cache
        permissions: ReadWrite
        source:
          type: EmptyDir
          emptyDir:
            sizeLimit: 500Mi

I have my own E2E test suite and existing MCP servers worked fine with this branch of the operator: https://github.com/mcp-kube/mcp-lifecycle-operator-e2e-tests/actions/runs/23618657354/job/68792484134#step:10:43

@k8s-ci-robot k8s-ci-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Mar 24, 2026
@k8s-ci-robot k8s-ci-robot added needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Mar 24, 2026
@k8s-ci-robot

Copy link
Copy Markdown
Contributor

Hi @aliok. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Tip

We noticed you've done this a few times! Consider joining the org to skip this step and gain /lgtm and other bot rights. We recommend asking approvers on your previous PRs to sponsor you.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Mar 24, 2026
@aliok aliok changed the title [WIP] Enhance MCPServer configuration with resource management and probes [WIP] Enhance MCPServer with emptyDir Mar 25, 2026
@aliok aliok force-pushed the 2026-03-24-empty-volumes branch 2 times, most recently from 24bfa92 to bddee7e Compare March 25, 2026 20:00
@aliok aliok closed this Mar 26, 2026
@aliok aliok deleted the 2026-03-24-empty-volumes branch March 26, 2026 13:59
@aliok aliok restored the 2026-03-24-empty-volumes branch March 26, 2026 13:59
@aliok aliok reopened this Mar 26, 2026
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 26, 2026
@aliok aliok force-pushed the 2026-03-24-empty-volumes branch from bddee7e to 1ca212b Compare March 26, 2026 14:05
@aliok aliok force-pushed the 2026-03-24-empty-volumes branch from 1ca212b to 1540d38 Compare March 26, 2026 21:20
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Mar 26, 2026
@aliok aliok changed the title [WIP] Enhance MCPServer with emptyDir Enhance MCPServer with emptyDir Mar 26, 2026
@aliok aliok marked this pull request as ready for review March 26, 2026 21:31
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Mar 26, 2026
@k8s-ci-robot k8s-ci-robot requested a review from mikebrow March 26, 2026 21:31
@aliok

aliok commented Mar 26, 2026

Copy link
Copy Markdown
Member Author

cc @matzew this is now rebased.

source:
type: ContainerImage
containerImage:
ref: docker.io/library/nginx:latest

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nope - let's please use real servers

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  apiVersion: mcp.x-k8s.io/v1alpha1
  kind: MCPServer
  metadata:
    name: kubernetes-mcp-server
  spec:
    source:
      type: ContainerImage
      containerImage:
        ref: quay.io/containers/kubernetes_mcp_server:latest
    config:
      port: 8080
      storage:
        - path: /tmp
          permissions: ReadWrite
          source:
            type: EmptyDir
            emptyDir:
              sizeLimit: 100Mi

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess 😅

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Damn, I was creating this PR when creating the prev one with the same issue, forgot to update it.
Thanks for catching it!

@matzew

matzew commented Mar 27, 2026

Copy link
Copy Markdown
Member

PR looks good, except for the sample. This should be changed

Signed-off-by: Ali Ok <aliok@redhat.com>
@aliok

aliok commented Mar 27, 2026

Copy link
Copy Markdown
Member Author

Updated the example

@matzew matzew left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 27, 2026
@k8s-ci-robot

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: aliok, matzew

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 27, 2026
@k8s-ci-robot k8s-ci-robot merged commit 7a1db01 into kubernetes-sigs:main Mar 27, 2026
6 checks passed
@aliok aliok deleted the 2026-03-24-empty-volumes branch April 17, 2026 07:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add emptyDir volume support for writable scratch space

3 participants