• golang 编译安装kata container (二)


    https://remimin.github.io/2018/09/12/kata-container-01/

    kata-runtime kata-proxy kata-shim
    
    go get -d -u github.com/kata-containers/runtime github.com/kata-containers/proxy github.com/kata-containers/shim
    cd $GOPATH/src/github.com/kata-containers/runtime
    make && make install
    cd ${GOPATH}/src/github.com/kata-containers/proxy
    make && make install 
    cd ${GOPATH}/src/github.com/kata-containers/shim
    make && make install 
    root@ubuntu:/opt/gopath/src/github.com# echo ${GOPATH}
    /opt/gopath
    root@ubuntu:~/kata/kata_package# go env -w GOPROXY=https://goproxy.cn,direct
    root@ubuntu:~/kata/kata_package# go get -d -u github.com/kata-containers/runtime
    package github.com/kata-containers/runtime: no Go files in /opt/gopath/src/github.com/kata-containers/runtime
    root@ubuntu:~/kata/kata_package# go get -d -u github.com/kata-containers/runtime github.com/kata-containers/proxy github.com/kata-containers/shim
    package github.com/kata-containers/runtime: no Go files in /opt/gopath/src/github.com/kata-containers/runtime
    root@ubuntu:~/kata/kata_package# cd ${GOPATH}/src/github.com/kata-containers/
    root@ubuntu:/opt/gopath/src/github.com/kata-containers# ls
    agent  proxy  runtime  shim
    root@ubuntu:/opt/gopath/src/github.com/kata-containers# ls runtime/
    arch                CODEOWNERS          data        Gopkg.toml  Makefile  protocols  VERSION
    cli                 containerd-shim-v2  golang.mk   hack        netmon    README.md  versions.yaml
    CODE_OF_CONDUCT.md  CONTRIBUTING.md     Gopkg.lock  LICENSE     pkg       vendor     virtcontainers
    root@ubuntu:/opt/gopath/src/github.com/kata-containers# cd $GOPATH/src/github.com/kata-containers/runtime
    root@ubuntu:/opt/gopath/src/github.com/kata-containers/runtime# cd ${GOPATH}/src/github.com/kata-containers/proxy
    root@ubuntu:/opt/gopath/src/github.com/kata-containers/proxy# make && make install 
    go build -buildmode=pie -o kata-proxy -ldflags "-X main.version=1.12.0-alpha1-2d7b87879ccb74e59a1f7c1a89493f2af900de44 "
    install -D kata-proxy //usr/libexec/kata-containers/kata-proxy
    root@ubuntu:/opt/gopath/src/github.com/kata-containers/proxy# cd ${GOPATH}/src/github.com/kata-containers/shim
    root@ubuntu:/opt/gopath/src/github.com/kata-containers/shim# make && make install 
    go build -buildmode=pie -o kata-shim -ldflags "-X main.version=1.12.0-alpha1-661632b9df7a640a2614970c03ad7b686e3b277a "
    install -D kata-shim //usr/libexec/kata-containers/kata-shim
    root@ubuntu:/opt/gopath/src/github.com/kata-containers/shim# 
    root@ubuntu:/opt/gopath/src/github.com/kata-containers/proxy# cd ${GOPATH}/src/github.com/kata-containers/shim
    root@ubuntu:/opt/gopath/src/github.com/kata-containers/shim# make && make install 
    go build -buildmode=pie -o kata-shim -ldflags "-X main.version=1.12.0-alpha1-661632b9df7a640a2614970c03ad7b686e3b277a "
    install -D kata-shim //usr/libexec/kata-containers/kata-shim
    root@ubuntu:/opt/gopath/src/github.com/kata-containers/shim# cd ..
    root@ubuntu:/opt/gopath/src/github.com/kata-containers# ls
    agent  proxy  runtime  shim
    root@ubuntu:/opt/gopath/src/github.com/kata-containers# cd ..
    root@ubuntu:/opt/gopath/src/github.com# ls
    asaskevich  containernetworking  docker  golang      josharian        opencontainers  PuerkitoBio  urfave
    blang       coreos               godbus  go-openapi  kata-containers  opentracing     safchain     vishvananda
    BurntSushi  cpuguy83             gogo    hashicorp   mailru           pkg             sirupsen
    containerd  cri-o                go-ini  intel       mitchellh        prometheus      uber
    root@ubuntu:/opt/gopath/src/github.com#
    root@ubuntu:/opt/gopath/src/github.com# kata-runtime kata-check
    ERRO[0000] /usr/share/defaults/kata-containers/configuration-qemu.toml: file /usr/share/kata-containers/vmlinuz.container does not exist  arch=arm64 name=kata-runtime pid=49332 source=runtime
    /usr/share/defaults/kata-containers/configuration-qemu.toml: file /usr/share/kata-containers/vmlinuz.container does not exist
    root@ubuntu:/opt/gopath/src/github.com# 
    root@ubuntu:/opt/gopath/src/github.com# /usr/bin/kata-runtime kata-env
    bash: /usr/bin/kata-runtime: No such file or directory
    root@ubuntu:/opt/gopath/src/github.com# whereis kata-runtime
    kata-runtime: /usr/local/bin/kata-runtime
    root@ubuntu:/opt/gopath/src/github.com# /usr/local/bin/kata-runtime kata-env
    /usr/share/defaults/kata-containers/configuration-qemu.toml: file /usr/share/kata-containers/vmlinuz.container does not exist
    root@ubuntu:/opt/gopath/src/github.com#
  • 相关阅读:
    C++ 实现简单快速排序
    LEETCODE 198. House Robber
    leetcode 174
    GIT 版本的回退
    unorderd_map 自定义键值及哈希函数的重载
    互斥锁 形成死锁实例
    leetcode 300
    LeetCode 62
    LeetCode 122
    SVN提交,强制注释
  • 原文地址:https://www.cnblogs.com/dream397/p/13751020.html
Copyright © 2020-2023  润新知