perymerdeka
perymerdeka

Reputation: 821

fatal: could not read Username for 'https://gitlab.com': No such device or address on gitlab

I am Try to push code with automate deploy and pull process to the production server, but I got an error in the pipeline build process like this

fatal: could not read Username for 'https://gitlab.com': No such device or address

here is a .gitlab-ci.yml

script:
- mkdir -p ~/.ssh
- chmod 700 ~/.ssh
- echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config
- echo "$PRIVATE_KEY_STAGING" > ~/.ssh/id_rsa
- chmod 600 ~/.ssh/id_rsa
- ssh -p22 ec2-user@$SERVER_STAGING "uname -a"

How to Login to My Server and pull my updated code using Gitlab CI/CD?

Thanks in advance

Upvotes: 2

Views: 6237

Answers (0)

Related Questions