Skip to content

GitLab CI runner tags are not split correctly #4030

@gitfool

Description

@gitfool

Prerequisites

  • I have written a descriptive issue title
  • I have searched issues to ensure it has not already been reported

Cake runner

Cake .NET Tool

Cake version

2.3.0

Operating system

Linux

Operating system architecture

64-Bit

CI Server

GitLab CI

What are you seeing?

I noticed GitLab CI runner tags are not split correctly while playing around with gitfool/GitLabCI.Dungeon, as shown this job, the CI_RUNNER_TAGS environment variable contains brackets and quotes:

CI_RUNNER_TAGS=["gce", "east-c", "linux", "ruby", "mysql", "postgres", "mongo", "git-annex", "shared", "docker", "saas-linux-small-amd64"]

which is split into a string array that still has these brackets and quotes:

BuildSystem.GitLabCI.Environment.Runner.Tags[0]               ["gce"
BuildSystem.GitLabCI.Environment.Runner.Tags[1]               "east-c"
BuildSystem.GitLabCI.Environment.Runner.Tags[2]               "linux"
BuildSystem.GitLabCI.Environment.Runner.Tags[3]               "ruby"
BuildSystem.GitLabCI.Environment.Runner.Tags[4]               "mysql"
BuildSystem.GitLabCI.Environment.Runner.Tags[5]               "postgres"
BuildSystem.GitLabCI.Environment.Runner.Tags[6]               "mongo"
BuildSystem.GitLabCI.Environment.Runner.Tags[7]               "git-annex"
BuildSystem.GitLabCI.Environment.Runner.Tags[8]               "shared"
BuildSystem.GitLabCI.Environment.Runner.Tags[9]               "docker"
BuildSystem.GitLabCI.Environment.Runner.Tags[10]              "saas-linux-small-amd64"]

What is expected?

The runner tags should be split into a string array that strips these brackets and quotes:

BuildSystem.GitLabCI.Environment.Runner.Tags[0]               gce
BuildSystem.GitLabCI.Environment.Runner.Tags[1]               east-c
BuildSystem.GitLabCI.Environment.Runner.Tags[2]               linux
BuildSystem.GitLabCI.Environment.Runner.Tags[3]               ruby
BuildSystem.GitLabCI.Environment.Runner.Tags[4]               mysql
BuildSystem.GitLabCI.Environment.Runner.Tags[5]               postgres
BuildSystem.GitLabCI.Environment.Runner.Tags[6]               mongo
BuildSystem.GitLabCI.Environment.Runner.Tags[7]               git-annex
BuildSystem.GitLabCI.Environment.Runner.Tags[8]               shared
BuildSystem.GitLabCI.Environment.Runner.Tags[9]               docker
BuildSystem.GitLabCI.Environment.Runner.Tags[10]              saas-linux-small-amd64

Steps to Reproduce

N/A.

Output log

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions