Skip to content

Error cleaning up configmap: resource name may not be empty

Summary

Steps to reproduce

Premium customer reported on zd-221975 that after upgrading runners to 14.01 started seeing the below errors

ERROR: Error cleaning up configmap: resource name may not be empty
ERROR: Job failed (system failure): prepare environment: setting up scripts configMap: generating scripts config map: ConfigMap "runner-abuzs4bk-project-16862655-concurrent-1-scriptshdc72" is invalid: []: Too long: must have at most 1048576 bytes. Check https://docs.gitlab.com/runner/shells/index.html#shell-profile-loading for more information

The error went away after enabling the flag FF_USE_LEGACY_KUBERNETES_EXECUTION_STRATE

  • Upgrade runners to 14.01
.gitlab-ci.yml
Add the job definition that is failing here

Actual behavior

Runners fail with bellow error

ERROR: Error cleaning up configmap: resource name may not be empty
ERROR: Job failed (system failure): prepare environment: setting up scripts configMap: generating scripts config map: ConfigMap "runner-abuzs4bk-project-16862655-concurrent-1-scriptshdc72" is invalid: []: Too long: must have at most 1048576 bytes. Check https://docs.gitlab.com/runner/shells/index.html#shell-profile-loading for more information

Expected behavior

Runners should run as normal and expected

Relevant logs and/or screenshots

job log
ERROR: Error cleaning up configmap: resource name may not be empty
ERROR: Job failed (system failure): prepare environment: setting up scripts configMap: generating scripts config map: ConfigMap "runner-abuzs4bk-project-16862655-concurrent-1-scriptshdc72" is invalid: []: Too long: must have at most 1048576 bytes. Check https://docs.gitlab.com/runner/shells/index.html#shell-profile-loading for more information

Environment description

config.toml contents
Add your configuration here

Used GitLab Runner version

Possible fixes

Enable feature flag for legacy execution

[runners.feature_flags]
FF_USE_LEGACY_KUBERNETES_EXECUTION_STRATEGY = true