0

When I used the GitLab runner to run CICD in my project, I found the pipeline ran quite slowly, and it even did not pass the first stage of the work. I set my runner executor as "pwsh". I also downloaded PowerShell 7 for Windows. The following is my .yml file:

stages:
  - build
  - test
  - deploy

Build Job:
  stage: build
  script:
    - echo "This is a first sample Build Job."

Test Job:
  stage: test
  script:
    - echo "This is a first sample Test Job."

Deploy Job:
  stage: deploy
  script:
    - echo "This is a first sample Deploy Job."

I cannot figure out why the runner can not finish this basic pipeline in just a few seconds. It had ran for 11 minutes in the build stage.

Here is my runner information:

[[runners]]
  name = "Local_TYC"
  url = "https://gitlab.com/"
  id = 23245609
  token = "glrt-xxxxxx"
  executor = "shell"
  shell = "pwsh"

I looked at a website to first solve the problem of pwsh path not found: exec: "pwsh": executable file not found in %PATH%

It seemed to work and successfully connect to my runner. And I also put the path of Powershell 7 from windows to the environment variable.

sytech
  • 29,298
  • 3
  • 45
  • 86
  • It appears that you have posted sensitive/private information. If that's the case, please reset your passwords and/or revoke API keys and tokens, as they are considered compromised when posted on the internet. – Samuel Liew May 15 '23 at 01:13

0 Answers0