Hi I have the following Issue, I have tried to setup runners of both types(Shell and SSh) still could not pass the “Deploy stage” not sure why apk not found, Any suggestions would appreciated.
stages:
- build
- test
- deploy
build website:
stage: build
script:
- touch Hasan.txt
artifacts:
paths:
- ./public1
test the artifacts:
image: alpine
stage: test
script:
- grep -irl “rajpoot” ./public1/index.html
deploy the website:
stage: deploy
image: alpine
before_script:
- apk add openssh-client
- eval $(ssh-agent -s)
- echo “$SSH_PRIVATE_KEY” | tr -d ‘\r’ | ssh-add -
- mkdir -p ~/.ssh
- chmod 777 ~/.ssh
script:
- scp -r -o StrictHostKeyChecking=no ./public1 root@IP-Address:/home/hraza/Desktop/
