Skip to content
This repository has been archived by the owner on May 14, 2021. It is now read-only.

block the volume-mounter to apply on ephemeral volume #17

Merged
merged 2 commits into from
Feb 7, 2020

Conversation

ryanzhang-oss
Copy link
Collaborator

@ryanzhang-oss ryanzhang-oss commented Feb 6, 2020

Another way to not block volume-mounter on ephemeral volume

~/workspace/oam/rudr (fix-issue-522) $ kc apply -f examples/volumes-ephemeral.yaml

componentschematic.core.oam.dev/server-with-ephemeral-volume created

Error from server: error when creating "examples/volumes-ephemeral.yaml": admission webhook "validate.appconfig.core.oam.dev" denied the request: Container server has a volumn myvol with ephemeral volumne so it can't have traint volume-mounter of type volume-mounter

Copy link
Member

@hongchaodeng hongchaodeng left a comment

Choose a reason for hiding this comment

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

please link to the issue

for _, c := range comp.Spec.Containers {
for _, v := range c.Resources.Volumes {
//TODO: check the volumeName from the Trait to match the disk volume name
if v.Disk.Ephemeral{
Copy link
Member

Choose a reason for hiding this comment

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

gofmt?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

how to link to the issue other than paste the link here?

Copy link
Member

Choose a reason for hiding this comment

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

Just paste it here is good enough.
Also the code looks not "gofmt-ed"?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

thanks, go fmted.

@ryanzhang-oss
Copy link
Collaborator Author

oam-dev/rudr#522

Copy link
Member

@wonderflow wonderflow left a comment

Choose a reason for hiding this comment

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

LGTM

@wonderflow wonderflow merged commit fe8a44d into oam-dev:master Feb 7, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants