Coder Social home page Coder Social logo

demo's Introduction

Build Status

KubeVirt Demo

This demo will deploy KubeVirt on an existing minikube with Kubernetes 1.9 or later.

Quickstart

Deploy KubeVirt

This demo assumes that minikube is up and running and kubectl available on your system. If not, then please take a look at the guide below

With minikube RUNNING, you can easily deploy KubeVirt:

$ export VERSION=v0.5.0
$ kubectl create \
    -f https://github.com/kubevirt/kubevirt/releases/download/$VERSION/kubevirt.yaml

Note: The initial deployment to a new minikube instance can take a long time, because a number of containers have to be pulled from the internet. Use watch kubectl get --all-namespaces pods to monitor the progress.

Install virtctl

Note: This requires kubectl from Kubernetes 1.9 or later on the client

An additional binary is provided to get quick access to the serial and graphical ports of a VM, and handle start/stop operations. The tool is called virtctl and can be retrieved from the release page of KubeVirt:

$ curl -L -o virtctl \
    https://github.com/kubevirt/kubevirt/releases/download/$VERSION/virtctl-$VERSION-linux-amd64
$ chmod +x virtctl

Deploy a VirtualMachine

Once you deployed KubeVirt you are ready to launch a VM:

# Creating a virtual machine
$ kubectl apply -f https://raw.githubusercontent.com/kubevirt/demo/master/manifests/vm.yaml

# After deployment you can manage VMs using the usual verbs:
$ kubectl get ovms
$ kubectl get ovms -o yaml testvm

# To start an offline VM you can use
$ ./virtctl start testvm
$ kubectl get vms
$ kubectl get vms -o yaml testvm

# To shut it down again
$ ./virtctl stop testvm

# To delete
$ kubectl delete ovms testvm
# To create your own
$ kubectl create -f $YOUR_VM_SPEC

Accessing VMs (serial console & vnc)

# Connect to the serial console
$ ./virtctl console testvm

# Connect to the graphical display
# Note: Requires `remote-viewer` from the `virt-viewer` package.
$ ./virtctl vnc testvm

Next steps

User Guide

Now that KubeVirt is up an running, you can take a look at the user guide to understand how you can create and manage your own virtual machines.

Appendix: Deploying minikube

  1. If not installed, install minikube as described here:

    1. Install the kvm2 driver
    2. Download the minikube binary
  2. Verify nested virtualization is enabled on the machine minikube is being installed on:

$ cat /sys/module/kvm_intel/parameters/nested
Y
  1. Launch minikube with CNI:
$ minikube start \
  --vm-driver kvm2 \
  --network-plugin cni
  1. Install kubectl via a package manager or download it

demo's People

Contributors

fabiand avatar mpolednik avatar rmohr avatar awels avatar karmab avatar rwsu avatar xsgordon avatar stu-gott avatar ansiwen avatar

Watchers

James Cloos avatar Brandon B. Jozsa avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.