Not running govet or gofmt in Dockerfile builds#1283
Not running govet or gofmt in Dockerfile builds#1283zroubalik merged 2 commits intokedacore:mainfrom
Conversation
540ac13 to
acad632
Compare
|
The static check is failing because of the |
|
We have two patches proposed, hopefully the maintainer will choose one of them: dnephin/pre-commit-golang#63 and dnephin/pre-commit-golang#62 |
|
@arschles hi, any update on this? |
|
@zroubalik sorry for the delay. I've been busy with the HTTP scaling work but I haven't forgotten about this. There's a US holiday this week and I'm going on vacation but I'll finish this up early next week. |
No worries, enjoy your vacation! Thanks for the heads up :) |
Signed-off-by: Aaron Schlesinger <aaron@ecomaz.net>
|
@zroubalik this comment suggests to just use |
@arschles agree! |
Signed-off-by: Aaron Schlesinger <aaron@ecomaz.net>
|
@zroubalik I removed the go-vet precommit check and things seem better now. PTAL |
|
Thanks @zroubalik 😄 |
* Not running govet or gofmt in Dockerfile builds Signed-off-by: Aaron Schlesinger <aaron@ecomaz.net> * not running go-vet in precommit Signed-off-by: Aaron Schlesinger <aaron@ecomaz.net>
Since we have code quality checks on the
v2branch, they will run prior to any docker build operation. That means that thego fmtandgo vetcalls inside the Dockerfile are redundant. This change removes them by creating two new makefile targets:adapter-dockerfileandmanager-dockerfile, and changing the adapter and manager dockerfiles to call those two targets, respectively.This patch also adds
go vetto the pre-commit config file.Question: should we add go vet to the golangci config file? This way, we can avoid running
go fmtandgo vetexplicitly in the pre commit file, as it'll be done automatically by the pre-commit golangci hookChecklist
Fixes #1070
Notes about TODOs:
Not sure about the changelog