networkop / k8s-topo

Topology builder for network simulations inside K8S
BSD 3-Clause "New" or "Revised" License
72 stars 18 forks source link

topology-sidecar-nse question: how to build? #12

Closed qlyoung closed 4 years ago

qlyoung commented 4 years ago

Me again! I managed to build and run all of the dependencies for this project for ARM, except for one:

https://github.com/networkop/k8s-topo/blob/master/bin/k8s-topo#L452

Naturally this image is only built on dockerhub for amd64. Your blog post on k8s-topo (https://networkop.co.uk/post/2020-01-nsm-topo/) is the solitary search result for this image and I can't seem to find the source for it anywhere. I'm guessing you personally built this image and uploaded it to the networkservicemesh dockerhub repo? Could you possibly direct me to source for it?

If you aren't the original author, please disregard this issue ;)

For example, here's a pod deployed by k8s-topo on my ARM cluster, which is failing because that image has been downloaded from dockerhub and has the wrong arch:

root@clusterpi-69 /h/p/networkservicemesh# kubectl describe pod/qrtr2
Name:         qrtr2
Namespace:    default
Priority:     0
Node:         clusterpi-86/192.168.0.234
Start Time:   Tue, 02 Jun 2020 23:44:08 +0100
Labels:       app=qrtr2
              topo=2node-quagga-nms
Annotations:  <none>
Status:       Running
IP:           10.42.5.35
IPs:
  IP:  10.42.5.35
Containers:
  router:
    Container ID:   containerd://0f020019a8b2675b319b7a86612c1b0b55d462bfb61b468eecd781b282a922aa
    Image:          qlyoung/frr:armhf
    Image ID:       docker.io/qlyoung/frr@sha256:b142143ce12e3fc82fcb66e154279af125f444fe4ae7cbcbd1b6ff62d211180a
    Port:           <none>
    Host Port:      <none>
    State:          Running
      Started:      Tue, 02 Jun 2020 23:44:32 +0100
    Ready:          True
    Restart Count:  0
    Environment:    <none>
    Mounts:
      /var/run/secrets/kubernetes.io/serviceaccount from default-token-rztrj (ro)
  nse-sidecar:
    Container ID:   containerd://9f25f2126b5074c4bb90766de64f94dbb0e52d7da9f8c6f715c3a95050c98911
    Image:          networkservicemesh/topology-sidecar-nse:master
    Image ID:       docker.io/networkservicemesh/topology-sidecar-nse@sha256:08657956da2cc6f496426f6b02f29ebdd1230be359c2aa717569ffcff2d6d8c2
    Port:           <none>
    Host Port:      <none>
    State:          Waiting
      Reason:       CrashLoopBackOff
    Last State:     Terminated
      Reason:       Error
      Exit Code:    1
      Started:      Wed, 03 Jun 2020 06:15:53 +0100
      Finished:     Wed, 03 Jun 2020 06:15:53 +0100
    Ready:          False
    Restart Count:  81
    Limits:
      networkservicemesh.io/socket:  1
    Requests:
      networkservicemesh.io/socket:  1
    Environment:
      ENDPOINT_NETWORK_SERVICE:  2node-quagga-nms
      ENDPOINT_LABELS:           device=qrtr2
      IP_ADDRESS:                10.60.1.0/24
    Mounts:
      /var/run/secrets/kubernetes.io/serviceaccount from default-token-rztrj (ro)

xref https://github.com/networkservicemesh/networkservicemesh/issues/2164

networkop commented 4 years ago

here's what you're looking for https://github.com/networkservicemesh/examples/tree/master/examples/topology/sidecar-nsc https://github.com/networkservicemesh/examples/tree/master/examples/topology/sidecar-nse

qlyoung commented 4 years ago

Hell yeah, you rock! Thanks so much!

nickolaev commented 4 years ago

@rdimitrov FYI

nickolaev commented 4 years ago

@qlyoung Is there any public information, blogpost, repo, or anything more about your work with this. It might be useful to share it with the NSM community on one of the calls or slack: https://networkservicemesh.io/community

qlyoung commented 4 years ago

@nickolaev https://qlyoung.net/k8s-topo-picluster