Remove illegal Characters from Hostname
Runners may occasionally have hostname-illegal Characters – in particular the Underscore _
.
I am not a Golang-Programmer, so I submit a Proposal here only:
In executors/docker/executor_docker.go
alter to the following:
641 func (e *executor) createContainer(containerType string, imageDefinition common.Image, cmd []string, allowedInternalImages []string) (*types.ContainerJSON, error) {
[…]
651 hostname := e.Config.Docker.Hostname
652 if hostname == "" {
653 import('regexp')
654 re := regexp.MustCompile('[^-a-z0-9]')
655 hostname = re.ReplaceAllString(strings.ToLower(s.Build.ProjectUniqueName()), '')
656 }