-
Notifications
You must be signed in to change notification settings - Fork 419
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(plugin/plugin-clair): vendor clairctl #3294
Conversation
Signed-off-by: Yvonnick Esnault <yvonnick.esnault@corp.ovh.com>
p := usr.HomeDir + "/.clairctl" | ||
|
||
if _, err := os.Stat(p); os.IsNotExist(err) { | ||
os.Mkdir(p, 0700) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Error return value of os.Mkdir
is not checked
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
"github.com/spf13/viper" | ||
) | ||
|
||
var errNoInterfaceProvided = errors.New("could not load configuration: no interface provided") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
errNoInterfaceProvided
is unused
) | ||
|
||
var errNoInterfaceProvided = errors.New("could not load configuration: no interface provided") | ||
var errInvalidInterface = errors.New("Interface does not exist") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
errInvalidInterface
is unused
return viper.GetString("clairctl.tempFolder") | ||
} | ||
|
||
func values() config { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
values
is unused
Password string | ||
} | ||
|
||
type loginMapping map[string]Login |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
loginMapping
is unused
InsecureRegistries []string | ||
} | ||
|
||
type config struct { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
config
is unused
No description provided.