Fix pipelines not always being created after a push Closes #66196 See merge request gitlab-org/gitlab-ce!31927