Skip to content

Commit

Permalink
Virt-handler
Browse files Browse the repository at this point in the history
Created a degenerate virt-handler binary to aid in creating a docker
container and DaemonSet file.

Change-Id: I5dc14c924c6f1bcdce2b8ef29c0fd9d177b6634a
Signed-off-by: Stu Gott <[email protected]>
  • Loading branch information
stu-gott committed Nov 4, 2016
1 parent 4b80b99 commit 1b8cf9b
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ vendor/*
.idea
cmd/virt-controller/virt-controller
cmd/virt-launcher/virt-launcher
cmd/virt-handler/virt-handler
contrib/manifest/*.yaml
**/bin
.vagrant
Expand Down
5 changes: 5 additions & 0 deletions cmd/virt-handler/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
FROM centos:7

COPY virt-handler /virt-handler

ENTRYPOINT [ "/virt-handler" ]
21 changes: 21 additions & 0 deletions cmd/virt-handler/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
= virt-handler =

This process is currently a placeholder

== Running virt-handler ==

Virt-handler can be started through docker with

```
docker run \
--rm \
--volume=/var/run/libvirt/libvirt-sock:/var/run/libvirt/libvirt-sock:Z \
--detach=false \
kubevirt/virt-handler:latest
```

On bare metal run

```
./virt-handler
```
14 changes: 14 additions & 0 deletions cmd/virt-handler/virt-handler.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package main

import (
"fmt"
"time"
)

func main() {
for {
fmt.Println("Sleeping")
// Sleep for one minute
time.Sleep(60000 * time.Millisecond)
}
}
2 changes: 1 addition & 1 deletion hack/config.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

binaries="cmd/virt-controller cmd/virt-launcher"
binaries="cmd/virt-controller cmd/virt-launcher cmd/virt-handler"
docker_prefix=kubevirt
docker_tag=latest
manifest_templates="`ls contrib/manifest/*.in`"

0 comments on commit 1b8cf9b

Please sign in to comment.