Fix handling of empty strings for default docker volumes (#1209)

This commit is contained in:
Anbraten 2022-09-27 11:43:35 +02:00 committed by GitHub
parent b4d89a1cce
commit 70114ed1fd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -64,6 +64,9 @@ func (e *docker) Load() error {
e.volumes = make([]string, 0, len(volumes))
// Validate provided volume definitions
for _, v := range volumes {
if v == "" {
continue
}
parts, err := splitVolumeParts(v)
if err != nil {
log.Error().Err(err).Msgf("invalid volume '%s' provided in WOODPECKER_BACKEND_DOCKER_VOLUMES", v)