zoukankan      html  css  js  c++  java
  • 027_git添加多账号设置

    一、

    注意事项:

    (1)公钥文件权限设置问题
    现象:
    Permissions 0644 for '/Users/arunyang/.ssh/id_rsa_ele_me.pub' are too open.
    It is required that your private key files are NOT accessible by others.
    This private key will be ignored.
    解决:
    chmod 600 /Users/arunyang/.ssh/id_rsa_ele_me.pub
    
    (2)IdentityFile本地~/.ssh/config应该为私钥,不应该问公钥
    现象:
    Load key "/Users/arunyang/.ssh/id_rsa_ele_me.pub": invalid format
    git@git.elenet.me: Permission denied (publickey).
    解决:IdentityFile配置中把.pub的公钥后缀给去掉
    
    (3)ssh配置的git@host主机名,出现如下情况,证明是ok的
    ssh -T git@git.elenet.me
    
    Welcome to GitLab, arunyang!
    (4)ssh配置参考
    Host git.elenet.me
       Hostname git.elenet.me
       IdentityFile /Users/arunyang/.ssh/id_rsa_ele_me
       PreferredAuthentications publickey
       User arunyang
    

    参考:https://www.jianshu.com/p/4b56bed47e6e

  • 相关阅读:
    Design Patterns
    Interview
    ListView Optimization
    android onclick onLongClick ontouch dispatchTouchEvent onInterceptTouchEvent
    java hashcode equals
    Android res/raw vs assets
    HttpClient -- 血的教训
    How Android Draws Views
    元数据 metadata
    Git-2
  • 原文地址:https://www.cnblogs.com/itcomputer/p/10491561.html
Copyright © 2011-2022 走看看