-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: yaroslavborbat <[email protected]>
- Loading branch information
1 parent
c1a5671
commit 7016f1c
Showing
4 changed files
with
79 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
images/virtualization-artifact/pkg/controller/kvapi/types.go
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package kvapi | ||
|
||
import ( | ||
v1 "k8s.io/api/core/v1" | ||
virtv1 "kubevirt.io/api/core/v1" | ||
) | ||
|
||
type VirtualMachineVolumeRequest struct { | ||
AddVolumeOptions *AddVolumeOptions `json:"addVolumeOptions,omitempty" optional:"true"` | ||
RemoveVolumeOptions *virtv1.RemoveVolumeOptions `json:"removeVolumeOptions,omitempty" optional:"true"` | ||
} | ||
type AddVolumeOptions struct { | ||
Name string `json:"name"` | ||
Disk *virtv1.Disk `json:"disk"` | ||
VolumeSource *HotplugVolumeSource `json:"volumeSource"` | ||
DryRun []string `json:"dryRun,omitempty"` | ||
} | ||
|
||
type HotplugVolumeSource struct { | ||
PersistentVolumeClaim *virtv1.PersistentVolumeClaimVolumeSource `json:"persistentVolumeClaim,omitempty"` | ||
DataVolume *virtv1.DataVolumeSource `json:"dataVolume,omitempty"` | ||
ContainerDisk *ContainerDiskSource `json:"containerDisk,omitempty"` | ||
} | ||
|
||
type ContainerDiskSource struct { | ||
Image string `json:"image"` | ||
ImagePullSecret string `json:"imagePullSecret,omitempty"` | ||
Path string `json:"path,omitempty"` | ||
ImagePullPolicy v1.PullPolicy `json:"imagePullPolicy,omitempty"` | ||
Hotpluggable bool `json:"hotpluggable,omitempty"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters