dongzheng4556 2019-04-23 09:33
浏览 25

如何使用Go程序更新牧场容器的图像

Thank you for reading. I'm chinese. I have problem with rancher. I want to use golang to make a program that I can click one time to push image to the right place and restart the test environment.

I’m new hand to learn golang. I tried to use golang connect linux. But I can't do more works about it. I have no idea. I find a code from internet in China.

// connect to ssh
addr = fmt.Sprintf("%s:%d", host, port)

if client, err = ssh.Dial("tcp", addr, clientConfig); err != nil {
    return nil, err
}

// create session
if session, err = client.NewSession(); err != nil {
    return nil, err
}

return session, nil

I want to learn how to make the program or some people can provide golang write plugins to help me. Thanks again!

  • 写回答

0条回答

    报告相同问题?

    悬赏问题

    • ¥15 素材场景中光线烘焙后灯光失效
    • ¥15 请教一下各位,为什么我这个没有实现模拟点击
    • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
    • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
    • ¥20 有关区间dp的问题求解
    • ¥15 多电路系统共用电源的串扰问题
    • ¥15 slam rangenet++配置
    • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
    • ¥15 ubuntu子系统密码忘记
    • ¥15 保护模式-系统加载-段寄存器