Skip to content

Instantly share code, notes, and snippets.

@garethahealy
Created January 31, 2017 10:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save garethahealy/a00c7acf57ff3d7a83741b6d58f569b1 to your computer and use it in GitHub Desktop.
Save garethahealy/a00c7acf57ff3d7a83741b6d58f569b1 to your computer and use it in GitHub Desktop.
install skydive
oc new-project skydive
oc annotate namespace skydive openshift.io/node-selector=' '
oc adm policy add-scc-to-user privileged system:serviceaccount:skydive:default
oc create -f https://raw.githubusercontent.com/garethahealy/skydive/master/contrib/openshift/skydive-template.yaml
oc new-app --template=skydive
@makentenza
Copy link

makentenza commented Feb 21, 2017

Gareth, for a ovs-multitenat deployment you must monitor '/var/run/openvswitch/db.sock' in agents as there is no info under '/var/run/netns'

{
    "kind": "DaemonSet",
    "apiVersion": "extensions/v1beta1",
    "metadata": {
        "name": "skydive-agent",
        "namespace": "skydive",
        "selfLink": "/apis/extensions/v1beta1/namespaces/skydive/daemonsets/skydive-agent",
        "uid": "615c872b-f7c9-11e6-aa2b-fa163e7baba0",
        "resourceVersion": "4723681",
        "generation": 1,
        "creationTimestamp": "2017-02-21T00:04:57Z",
        "labels": {
            "app": "skydive",
            "tier": "agent"
        },
        "annotations": {
            "openshift.io/generated-by": "OpenShiftNewApp"
        }
    },
    "spec": {
        "selector": {
            "matchLabels": {
                "app": "skydive",
                "tier": "agent"
            }
        },
        "template": {
            "metadata": {
                "creationTimestamp": null,
                "labels": {
                    "app": "skydive",
                    "tier": "agent"
                }
            },
            "spec": {
                "volumes": [
                    {
                        "name": "docker",
                        "hostPath": {
                            "path": "/var/run/docker.sock"
                        }
                    },
                    {
                        "name": "ovsdb",
                        "hostPath": {
                            "path": "/var/run/openvswitch/db.sock"
                        }
                    }
                ],
                "containers": [
                    {
                        "name": "skydive-agent",
                        "image": "skydive/skydive",
                        "args": [
                            "agent"
                        ],
                        "ports": [
                            {
                                "hostPort": 8081,
                                "containerPort": 8081,
                                "protocol": "TCP"
                            }
                        ],
                        "env": [
                            {
                                "name": "SKYDIVE_AGENT_ANALYZERS",
                                "value": "$(SKYDIVE_ANALYZER_SERVICE_HOST):$(SKYDIVE_ANALYZER_SERVICE_PORT_API)"
                            }
                        ],
                        "resources": {},
                        "volumeMounts": [
                            {
                                "name": "docker",
                                "mountPath": "/var/run/docker.sock"
                            },
                            {
                                "name": "ovsdb",
                                "mountPath": "/var/run/openvswitch/db.sock"
                            }
                        ],
                        "terminationMessagePath": "/dev/termination-log",
                        "imagePullPolicy": "Always",
                        "securityContext": {
                            "privileged": true
                        }
                    }
                ],
                "restartPolicy": "Always",
                "terminationGracePeriodSeconds": 30,
                "dnsPolicy": "ClusterFirst",
                "hostNetwork": true,
                "hostPID": true,
                "securityContext": {}
            }
        }
    },
    "status": {
        "currentNumberScheduled": 11,
        "numberMisscheduled": 0,
        "desiredNumberScheduled": 11
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment