ssh config for multiple bitbucket accounts - Simple example, but getting 'remote end hung up unexpectedly'

前端 未结 3 2083
时光取名叫无心
时光取名叫无心 2021-02-05 16:35

Suppose my bitbucket user name is \"jon\" and I have some personal projects at https://bitbucket.org/jon.

Suppose I then join a development team that has a

相关标签:
3条回答
  • 2021-02-05 16:37

    It is regards to RSA file that appears on ../.ssh/ folder I fixed this by deleting any corrupt file and then generate again as you install GitHub.

    0 讨论(0)
  • 2021-02-05 16:37

    These commands should fix the problem:

    chown $USER ~/.ssh/config
    chmod 644 ~/.ssh/config
    

    Prefix with sudo if the files are owned by different user.

    If more files are affected, replace config with *.

    In man ssh we can read:

    Because of the potential for abuse, this file must have strict permissions: read/write for the user, and not writable by others. It may be group-writable provided that the group in question contains only the user.

    0 讨论(0)
  • 2021-02-05 17:01

    I had the same problem. After i changed permissions of the file ~/.ssh/config to -rw-r--r--, the error

    Bad owner or permissions on /home/username/.ssh/config
    fatal: The remote end hung up unexpectedly
    

    disappeared.

    Write in console:

    cd ~/.ssh
    chmod 644 config
    
    0 讨论(0)
提交回复
热议问题