Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(iso-device): show DVDs in ISO selector #1889

Merged
merged 2 commits into from
Jan 16, 2017
Merged

Conversation

pdonias
Copy link
Member

@pdonias pdonias commented Jan 16, 2017

Fixes #1880

@pdonias pdonias requested a review from julien-f January 16, 2017 15:37
(vmPool, vmContainer) => sr =>
sr.$pool === vmPool && // SR is on the same pool
(vmContainer === vmPool || sr.shared || vmContainer === sr.$container) && // non shared SR is on the same host if VM is running
(sr.SR_type === 'iso' || sr.SR_type === 'udev' && !sr.shared && sr.size) // CD or DVD
Copy link
Member

Choose a reason for hiding this comment

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

sr => {
  const vmHalted = vmContainer === vmPool
  const sameHost = vmContainer === sr.$container
  const samePool = vmPool === sr.$pool

  return (
    samePool && (running ? shared || sameHost : true) &&
    sr.SR_type === 'iso' || sr.SR_type === 'udev' && sr.size
  )
}

@julien-f julien-f merged commit 05d6f3d into next-release Jan 16, 2017
@julien-f julien-f deleted the pierre-dvd-drives branch January 16, 2017 16:07
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.

None yet

2 participants