Go 报错 error obtaining VCS status: exit status 128 Use -buildvcs=false to disable VCS stamping.

4 篇文章 0 订阅

Go 报错 error obtaining VCS status: exit status 128 Use -buildvcs=false to disable VCS stamping.

背景:

新建一个 Go 项目打算利用 air 进行热重载时,使用air启动 air ,发现报错

build 项目失败
在这里插入图片描述

error obtaining VCS status: exit status 128
        Use -buildvcs=false to disable VCS stamping.
failed to build, error: exit status 1

解决方法

终端输入
go env -w GOFLAGS=-buildvcs=false
之后重新启动 air, 启动成功。
在这里插入图片描述

-- Logs begin at Thu 2023-07-13 00:44:15 CST, end at Thu 2023-07-13 00:53:06 CST. -- Jul 13 00:48:25 pod-64788377f624725f6ea4b9e8-64aed85ec2dbab11bceeb07f systemd[1]: Starting Docker Application Container Engine... Jul 13 00:48:25 pod-64788377f624725f6ea4b9e8-64aed85ec2dbab11bceeb07f dockerd[215]: time="2023-07-13T00:48:25.388440905+08:00" level=info msg="Starting up" Jul 13 00:48:25 pod-64788377f624725f6ea4b9e8-64aed85ec2dbab11bceeb07f dockerd[215]: time="2023-07-13T00:48:25.405370737+08:00" level=error msg="failed to mount overlay: invalid argument" storage-driver=overlay2 Jul 13 00:48:25 pod-64788377f624725f6ea4b9e8-64aed85ec2dbab11bceeb07f dockerd[215]: time="2023-07-13T00:48:25.408339784+08:00" level=info msg="Loading containers: start." Jul 13 00:48:25 pod-64788377f624725f6ea4b9e8-64aed85ec2dbab11bceeb07f dockerd[215]: time="2023-07-13T00:48:25.409506558+08:00" level=warning msg="Running modprobe bridge br_netfilter failed with message: , error: exit status 1" Jul 13 00:48:25 pod-64788377f624725f6ea4b9e8-64aed85ec2dbab11bceeb07f dockerd[215]: time="2023-07-13T00:48:25.411850508+08:00" level=info msg="unable to detect if iptables supports xlock: 'iptables --wait -L -n': `iptables v1.4.21: can't initialize iptables table `filter': Permission denied (you must be root)\nPerhaps iptables or your kernel needs to be upgraded.`" error="exit status 3" Jul 13 00:48:25 pod-64788377f624725f6ea4b9e8-64aed85ec2dbab11bceeb07f dockerd[215]: time="2023-07-13T00:48:25.425371913+08:00" level=info msg="stopping event stream following graceful shutdown" error="<nil>" module=libcontainerd namespace=moby Jul 13 00:48:25 pod-64788377f624725f6ea4b9e8-64aed85ec2dbab11bceeb07f dockerd[215]: failed to start daemon: Error initializing network controller: error obtaining controller instance: failed to create NAT chain DOCKER: iptables failed: iptables -t nat -N DOCKER: iptables v1.4.21: can't initialize iptables table `nat': Permission denied (you must be root)
07-13
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值