solo-io / bumblebee

Get eBPF programs running from the cloud to the kernel in 1 line of bash
Apache License 2.0
1.26k stars 78 forks source link

Cannot run tcpconnlat example #97

Open k8spacket opened 1 year ago

k8spacket commented 1 year ago

Version

0.0.14

Linux Version

5.15.0-1022-aws

Describe the bug

Hi solo.io, great job!

Example from link https://github.com/solo-io/bumblebee/tree/main/examples/tcpconnlat doesn't work.

  ERROR   Failed to load OCI image
github.com/containerd/containerd/remotes/docker.(*request).do
    /home/runner/go/pkg/mod/github.com/containerd/containerd@v1.5.9/remotes/docker/resolver.go:551
github.com/containerd/containerd/remotes/docker.(*request).doWithRetries
    /home/runner/go/pkg/mod/github.com/containerd/containerd@v1.5.9/remotes/docker/resolver.go:576
github.com/containerd/containerd/remotes/docker.(*request).doWithRetries
    /home/runner/go/pkg/mod/github.com/containerd/containerd@v1.5.9/remotes/docker/resolver.go:589
github.com/containerd/containerd/remotes/docker.(*dockerResolver).Resolve
    /home/runner/go/pkg/mod/github.com/containerd/containerd@v1.5.9/remotes/docker/resolver.go:280
oras.land/oras-go/pkg/oras.Copy
    /home/runner/go/pkg/mod/oras.land/oras-go@v1.0.0/pkg/oras/copy.go:63
github.com/solo-io/bumblebee/pkg/spec.TryFromLocal
    /home/runner/work/bumblebee/bumblebee/pkg/spec/utils.go:37
github.com/solo-io/bumblebee/pkg/cli/internal/commands/run.getProgram
    /home/runner/work/bumblebee/bumblebee/pkg/cli/internal/commands/run/run.go:180
github.com/solo-io/bumblebee/pkg/cli/internal/commands/run.run
    /home/runner/work/bumblebee/bumblebee/pkg/cli/internal/commands/run/run.go:95
github.com/solo-io/bumblebee/pkg/cli/internal/commands/run.Command.func1
    /home/runner/work/bumblebee/bumblebee/pkg/cli/internal/commands/run/run.go:76
github.com/spf13/cobra.(*Command).execute
    /home/runner/go/pkg/mod/github.com/spf13/cobra@v1.2.1/command.go:856
github.com/spf13/cobra.(*Command).ExecuteC
    /home/runner/go/pkg/mod/github.com/spf13/cobra@v1.2.1/command.go:974
github.com/spf13/cobra.(*Command).Execute
    /home/runner/go/pkg/mod/github.com/spf13/cobra@v1.2.1/command.go:902
github.com/spf13/cobra.(*Command).ExecuteContext
    /home/runner/go/pkg/mod/github.com/spf13/cobra@v1.2.1/command.go:895
main.main
    /home/runner/work/bumblebee/bumblebee/bee/main.go:13
runtime.main
    /opt/hostedtoolcache/go/1.17.6/x64/src/runtime/proc.go:255
runtime.goexit
    /opt/hostedtoolcache/go/1.17.6/x64/src/runtime/asm_amd64.s:1581
Error: failed to authorize: failed to fetch anonymous token: unexpected status: 401 Unauthorized
2023/01/14 11:48:26 exiting: failed to authorize: failed to fetch anonymous token: unexpected status: 401 Unauthorized

There isn't the tcpconnlat image in the packages on GitHub: https://github.com/orgs/solo-io/packages

Steps to reproduce the bug

bee run ghcr.io/solo-io/bumblebee/tcpconnlat:$(bee version)

Expected Behavior

Program is started

Additional Context

No response

krisztianfekete commented 1 year ago

Hey @k8spacket, thank you for opening this issue! This is strange, as I can see it was pushed with the latest release:

 SUCCESS  Pushing image ghcr.io/solo-io/bumblebee/tcpconnlat:0.0.14 to remote registry

However, I get the same as you. We will look into it, in the meantime, you can work this out by building the image locally and use that, like this:

root@master:~# bee build tcpconnlat.c tcpconnlat:v1
 SUCCESS  Successfully compiled "tcpconnlat.c" and wrote it to "tcpconnlat.o"                                                                                                      
 SUCCESS  Saved BPF OCI image to tcpconnlat:v1                                                                                                                                     
root@master:~# bee run tcpconnlat:v1
 SUCCESS  Fetching program from registry: tcpconnlat:v1