code: func newAuthProvider(c *Context) (dockerauth.AuthProvider, error) {
  	provider := dockerauth.NewMultiAuthProvider()
  	provider.AddProvider(dockerauth.NewECRAuthProvider(func(region string) dockerauth.ECR {
  		return ecr.New(c, &aws.Config{Region: aws.String(region)})
  	}))
  
  	if dockerConfigPath := c.String(FlagDockerAuth); dockerConfigPath != "" {
  		dockerConfigFile, err := os.Open(dockerConfigPath)
  		if err != nil {
  			return nil, err
  		}
  
  		defer dockerConfigFile.Close()
  
  		dockerConfigProvider, err := dockerauth.NewDockerConfigAuthProvider(dockerConfigFile)
  		if err != nil {
  			return nil, err
  		}
  
  		provider.AddProvider(dockerConfigProvider)
  	}
  
  	return provider, nil
  }
docs: // Auth provider =======================