mirror of
https://github.com/drone-plugins/drone-docker.git
synced 2026-06-04 10:15:30 +08:00
remove docker registry string match
This commit is contained in:
@@ -5,7 +5,6 @@ import (
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
"strings"
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -50,7 +49,7 @@ func (c *Config) SetCredHelper(registry, helper string) {
|
||||
|
||||
func (c *Config) CreateDockerConfigJson(credentials []RegistryCredentials) ([]byte, error) {
|
||||
for _, cred := range credentials {
|
||||
if cred.Registry != "" && strings.Contains(cred.Registry, "docker") {
|
||||
if cred.Registry != "" {
|
||||
|
||||
if cred.Username == "" {
|
||||
return nil, fmt.Errorf("Username must be specified for registry: %s", cred.Registry)
|
||||
|
||||
Reference in New Issue
Block a user