--add-host="host.docker.internal:$BITBUCKET_DOCKER_HOST_INTERNAL" \bitbucketpipelines/scp-deploy:1.2.1Unable to find image 'bitbucketpipelines/scp-deploy:1.2.1' locally1.2.1: Pulling from bitbucketpipelines/scp-deploybb7d5a84853b: Pulling fs layerf02b617c6a8c: Pulling fs layerd32e17419b7e: Pulling fs layerc9d2d81226a4: Pulling fs layer3c24ae8b6604: Pulling fs layer8a4322d1621d: Pulling fs layerc9d2d81226a4: Waitinga03ef301ddd7: Pulling fs layera4c591fc96f3: Pulling fs layerc2fde97fe1fb: Pulling fs layer8a4322d1621d: Waiting02d081902850: Pulling fs layera03ef301ddd7: Waitinga4c591fc96f3: Waiting4e6a5cdfcfa7: Pulling fs layerc2fde97fe1fb: Waitingbad96da9f98d: Pulling fs layer02d081902850: Waiting1a9bd9b01ebe: Pulling fs layer8d8633d00c54: Pulling fs layer3c24ae8b6604: Waiting4e6a5cdfcfa7: Waiting1a9bd9b01ebe: Waiting8d8633d00c54: Waitingf02b617c6a8c: Verifying Checksumf02b617c6a8c: Download completed32e17419b7e: Verifying Checksumd32e17419b7e: Download completebb7d5a84853b: Verifying Checksumbb7d5a84853b: Download complete8a4322d1621d: Verifying Checksum8a4322d1621d: Download completec9d2d81226a4: Verifying Checksumc9d2d81226a4: Download completea03ef301ddd7: Verifying Checksuma03ef301ddd7: Download completea4c591fc96f3: Download completec2fde97fe1fb: Verifying Checksumc2fde97fe1fb: Download completebb7d5a84853b: Pull complete02d081902850: Download complete4e6a5cdfcfa7: Verifying Checksum4e6a5cdfcfa7: Download completef02b617c6a8c: Pull completebad96da9f98d: Download completed32e17419b7e: Pull complete3c24ae8b6604: Verifying Checksum3c24ae8b6604: Download complete1a9bd9b01ebe: Verifying Checksum1a9bd9b01ebe: Download complete8d8633d00c54: Verifying Checksum8d8633d00c54: Download completec9d2d81226a4: Pull complete3c24ae8b6604: Pull complete8a4322d1621d: Pull completea03ef301ddd7: Pull completea4c591fc96f3: Pull completec2fde97fe1fb: Pull complete02d081902850: Pull complete4e6a5cdfcfa7: Pull completebad96da9f98d: Pull complete1a9bd9b01ebe: Pull complete8d8633d00c54: Pull completeDigest: sha256:b9111f61b5824ca7ed1cb63689a6da55ca6d6e8985eb778c36a5dfc2ffe776a8Status: Downloaded newer image for bitbucketpipelines/scp-deploy:1.2.1DEBUG: Starting new HTTPS connection (1): bitbucket.org:443DEBUG: https://bitbucket.org:443 "GET /bitbucketpipelines/official-pipes/raw/master/pipes.prod.json HTTP/1.1" 200 NoneINFO: Using passed SSH_KEY...INFO: Adding known hosts...INFO: Appending to ssh config file private key pathINFO: Applied file permissions to ssh directory.Executing: program /usr/bin/ssh host x.xxx.xx.xx, user ubuntu, command scp -v -r -p -d -t /home/ubuntu/pipeline/OpenSSH_8.4p1 Debian-5, OpenSSL 1.1.1k 25 Mar 2021debug1: Reading configuration data /root/.ssh/configdebug1: Reading configuration data /etc/ssh/ssh_configdebug1: /etc/ssh/ssh_config line 19: include /etc/ssh/ssh_config.d/*.conf matched no filesdebug1: /etc/ssh/ssh_config line 21: Applying options for *debug1: Connecting to x.xxx.xx.xx [x.xxx.xx.xx] port 22.debug1: Connection established.debug1: identity file /root/.ssh/pipelines_id type -1debug1: identity file /root/.ssh/pipelines_id-cert type -1debug1: Local version string SSH-2.0-OpenSSH_8.4p1 Debian-5debug1: Remote protocol version 2.0, remote software version OpenSSH_8.2p1 Ubuntu-4ubuntu0.2debug1: match: OpenSSH_8.2p1 Ubuntu-4ubuntu0.2 pat OpenSSH* compat 0x04000000debug1: Authenticating to x.xxx.xx.xx:22 as 'ubuntu'debug1: SSH2_MSG_KEXINIT sentdebug1: SSH2_MSG_KEXINIT receiveddebug1: kex: algorithm: curve25519-sha256debug1: kex: host key algorithm: ecdsa-sha2-nistp256debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: nonedebug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: nonedebug1: expecting SSH2_MSG_KEX_ECDH_REPLYdebug1: Server host key: ecdsa-sha2-nistp256 SHA256:xVqWItEasJmMP8WKRHdxRdOI4ZooV9gWyjhNmDZzGMAdebug1: read_passphrase: can't open /dev/tty: No such device or addressHost key verification failed.lost connection✖ Deployment failed.This is usually caused by the unix user you are logging in as not having a valid shell. or ssh settings.
The "can't open /dev/tty" bit near the end is the giveaway. Try logging in manually, you will probably get the same error.
If you do, then you will need to log in as another user (one who can use su or sudo to change other user's accounts), and look at why that user cannot log in (make sure they have a shell and home directory set in /etc/passwd, and that their home directory exists, belongs to them and they can read/write it). Try "su - <username>" first to see what that does. it might tell you more about what the problem is
If you can log in, or you've fixed the account as above, then you'll want to check what is in the .ssh directory in their home directory.
So, from your system, you can use "ssh ubuntu@x.xxx.xx.xx" and get a command prompt?
What is in that user's .ssh directory in their home directory?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
yes,
I have resolve my issue by following
https://www.basictechno.com/pipeline-bitbucket-to-aws-ec2-over-ssh/
thanks for helping
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.