Our enhanced runners utilize the Kubernetes executor which allows for resources to be configured directly instead of indirectly through runner tags.

    The following is an example .gitlab-ci.yml file that configures resources.

    # Defaults for entire pipeline, which effectively override runner config.
    variables:
      KUBERNETES_CPU_REQUEST: "8"
      KUBERNETES_MEMORY_REQUEST: "24Gi"
    
      # Increase if having problems due to a large git repository or large Gitlab artifacts.
      KUBERNETES_HELPER_CPU_REQUEST: "1"
      KUBERNETES_HELPER_MEMORY_REQUEST: "1Gi"
    
    job:
      variables:
        # Configured per job.
        KUBERNETES_CPU_REQUEST: "16"
        KUBERNETES_MEMORY_REQUEST: "48Gi"
      services:
      - name: redis:5
        variables:
          # Configured per service.
          KUBERNETES_SERVICE_CPU_REQUEST: "2"
          KUBERNETES_SERVICE_MEMORY_REQUEST: "8Gi"
      script: echo do stuff
    

    The defaults applied to all jobs are configured through the repository file:

    • cpu
    • memory
    • helper_cpu
    • helper_memory
    • service_cpu
    • service_memory