<em>Mac</em>Book项目 2009年学校开始实施<em>Mac</em>Book项目,所有师生配备一本<em>Mac</em>Book,并同步更新了校园无线网络。学校每周进行电脑技术更新,每月发送技术支持资料,极大改变了教学及学习方式。因此2011
2021-06-01 09:32:01
在gitee上建立springcloud倉庫
application.yaml(https方式)
server: port: 3344 spring: application: name: cloud-config-center #註冊進Eureka伺服器的微服務名 cloud: config: server: git: strictHostKeyChecking: false uri: https://gitee.com/su-qiqaq/spingcloud-config.git #GitHub上面的git倉庫名字 force-pull: true #設定強行pull拉取 #搜尋目錄 search-paths: - springcloud-config #讀取分支 label: master eureka: client: service-url: defaultZone: http://eureka7001.com:7001/eureka/,http://eureka7002.com:7002/eureka/
application.yaml(ssh方式)
發現報錯,原因是沒有設定私鑰在yaml中
com.jcraft.jsch.jschexception: reject hostkey:github.com
如果以前在gitee中設定了公鑰,就可以在C:Users使用者名稱.ssh的id_rsa檔案獲取私鑰,新增在yaml中
server: port: 3344 spring: application: name: cloud-config-center #註冊進Eureka伺服器的微服務名 cloud: config: server: git: uri: git@gitee.com:su-qiqaq/spingcloud-config.git strictHostKeyChecking: false privateKey: | -----BEGIN OPENSSH PRIVATE KEY----- b3BlbnNzaC1rZXktdjEAAAAABG5vbmUAAAAEbm9uZQAAAAAAAAABAAABlwAAAAdzc2gtcn NhAAAAAwEAAQAAAYEAtBGJMiwsYbIH1ljXjp9kP8utlxIT85U7sGdQJFtxDpn7nUc5OvuO 9++JumUQNbKv5284GaYRGogRPvpfAupjq/vz4oolJHOwktELeioN+wIN0ZEhGKQlFF1UmW NONZnsG0geBzieRJFMDvpA2IV0V1jP1C7+jFqLjWTXT2qLsXgwVCxAqyso3o9s4eVKSsEK fJyHCUeoIqUgE30P0LYhd5ubvCUwO77DCDWb3b05VFDD9AKYlF9xXBTN++KHQWOKthtIjg 8ncuZPwrZWkZhinj39NMQJA+G1qN7ZP80OwTAHmJfaOXFHTWfIfdU4UuM/RKRm7hJlBLee KJpuajHSQoU+I7yS7bXKMhZvO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siyV+gbmdVXnMJtd8q XDDZYYRUZS+iynKuiNANZNQz8VGq6jomGE56Zqq/afFHeRk+Ib9m9xpcKWgHj/XXd+tvHg E098I0gtn2jf4ivaCbux8pB9gS8f9QCbj6CQwuQuJwGkWk40Eu8iKPQ9QyqU6U8PNRAAAA wQCVazzRZInKcVyAV+R4qU9RHOSn75Nvq3y/Ph4gxGDX98llTb3CQvjDgP4w2fbrgwPHwm 6GKKRtYxUXdTY4eZRGj5QCCz3uGe8dXh4G5HbRqL17hCfyaVoJblgfJrlY/I76DvbrEkOE /CNxQuBYPpXClEe5LEguCWz07Y/yW4c3yAzAWQqsgtHiTh/Qs3qeFluJj++MbZ03cFTavo UL0os7jijvzcoiWG4sDDf1tucL9MhY3rCy9vqQWqoJH1+dA/gAAADBANoHeMvW/KTrs5hw UIPDo0lEH+P2GCdeaPLeHeuyM5V+17+d6vqVYadw82yhMOcpM3wr5oFhZpm/36YKt1HbqF z4X+aqMC855W4VnCQDs1OvJU6wt42iYMCctN7lfbx2CCzoMaA8/2v8239z85O1LeM0h3K0 djn/idD3DITYKvBuoxOF3BZ1W2U/0b+DUWhH/yrrHpXsmjyqtWgwZLBKzUzXJj/T32pwDM Pko4S9P4SANE/Vk4Uj5s02DwgtI7Im2wAAAMEA022jvQIP8mLkFD7KTdnBwb4HS2hp5e9t P4NTtrXtZE+POjZ54TPerNUxh8ymf766EGeA/ImgPhNWSFKriWC4aFp2UKflPs7/0+jFfB yNjqVEUH410HCuip+yNUcEW3HN/N8UR/l48WDTXh8mdL4vGxtpTiHii4hPB1zyw1Ku3JA+ gDKVBN1pQ2I3Ldxe1n4HYB66PJpWsFZ41JDPiMSmhWwMreUrv0niowqUKttidg+9yEiRB4 5ToAmFqEFbswhFAAAAETExNDE3OTM5NjFAcXEuY29tAQ== -----END OPENSSH PRIVATE KEY----- # uri: https://gitee.com/su-qiqaq/spingcloud-config.git #GitHub上面的git倉庫名字 force-pull: true #設定強行pull拉取 #搜尋目錄 search-paths: - springcloud-config #讀取分支 label: master eureka: client: service-url: defaultZone: http://eureka7001.com:7001/eureka/,http://eureka7002.com:7002/eureka/
出現錯誤
Auth fail
原因:
仔細檢視後發現我的私鑰是以BEGIN OPENSSH PRIVATE KEY開頭,END OPENSSH PRIVATE KEY結尾,而
現在伺服器端如mysql,gitee等還不支援這種格式,因此我們還是生成原來的格式:以BEGIN RSA PRIVATE KEY開頭,
END RSA PRIVATE KEY結尾。
解決:進入 git bash重新生成私鑰和公鑰:
ssh-keygen -m PEM -t rsa -b 4096 -C "1141793961@qq.com"
同樣,重新在C:Users使用者名稱.ssh的id_rsa檔案獲取私鑰,新增在yaml中,並且
重新在C:Users使用者名稱.ssh的id_rsa.pub檔案獲取公鑰,新增在gitee的ssh公鑰中
server: port: 3344 spring: application: name: cloud-config-center #註冊進Eureka伺服器的微服務名 cloud: config: server: git: uri: git@gitee.com:su-qiqaq/spingcloud-config.git ignoreLocalSshSettings: true strictHostKeyChecking: false privateKey: | -----BEGIN RSA PRIVATE KEY----- MIIJJwIBAAKCAgEAqEh1DblLHWCzmrQpbevjWwQihOufLgglt2Lv0uT76BnOI+gi 8YzQjgNSOPDSN6gjwiBayLqkD/cAJZeCOMj5PJyZIs9HXs/V9vUHoZRtYR7z+k0+ QZLJDtJWB9QNCoEwbpzMCwNisuKCW3tktvTVtV9Yq1+EB6RvseRWZbf1wJbVv16T R0u9oYq1eaVflH0nuT/CJSi/uGO81rglGirgqwwOJSmz8MxDxp24HMuQRDK+xtXe 8pBmvtEKirnWcB0NBWmQDd5OljpFhrLBT71YMHKvFvBtcMfpgfgdvrkvZcqlhTiO tAAYnsannHDF+y1L2pa76gFmPgi0HNIj4PfHc29H9d1XdH/0vzeMr6KeMhiwRBO9 pUYcILI2/+Q5774+Be398tSx6czJoNbrzvTj1OzvYZ8Qu80LRPWlNBfzuRTF2tLv ummsnisrY0ii/i7FYL5RdheLvGov3qTudNRPwvFUvXG/fqFrq0QZMr9RahO8JPo0 lViwCYc5oOLVr4xrajqz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Ce2PdUnyVqOhSdPF0Z2s0maALh1WJiTUvPyZ WLMOuqZPLEUyU6rJQcbhKmo0VdwKm74wi1zTLslIwjg7IIWrSTNhvgTEW45pfm/v YhCo10Vd9XLNt6Acszk1imhQ8eUKacECggEAB/ZcUrw0/RvDzYWB+e/L0dFuIFuG oPAm23/UayIENEniIgSeEPR2XnfJQLEjLu9RMEZ5Wn9FWICjqhZJVpNwVhPDFCEZ zW2On5U50EtmHTLZ7KxgR4w9YR9uqaB9cuOXTU1imO7Cs6envJ0iO6pWEFQa531Y XafOgOoIlZ54N/qJhS6PcYBwmgtKCl2v9PzxOJSdQRxQriTW+/EtFeqXhjcdQw4K UtbkGcqbg0woJkis0XnDt5tCddmATvtdngzb+9Rn+3B0i1r2ksU5/SaU1wdEmBmb WAsX8ey+pGxKaMPm+88FeE8glVcJ6BxFTmvng1PImOazvvZAAhvhObZO4A== -----END RSA PRIVATE KEY----- # uri: https://gitee.com/su-qiqaq/spingcloud-config.git #GitHub上面的git倉庫名字 force-pull: true #設定強行pull拉取 #搜尋目錄 search-paths: - springcloud-config #讀取分支 label: master eureka: client: service-url: defaultZone: http://eureka7001.com:7001/eureka/,http://eureka7002.com:7002/eureka/
參考文章:
https://blog.csdn.net/u011863024/article/details/114298282
到此這篇關於springcloud設定ssh的文章就介紹到這了,更多相關springcloud設定ssh內容請搜尋it145.com以前的文章或繼續瀏覽下面的相關文章希望大家以後多多支援it145.com!
相關文章
<em>Mac</em>Book项目 2009年学校开始实施<em>Mac</em>Book项目,所有师生配备一本<em>Mac</em>Book,并同步更新了校园无线网络。学校每周进行电脑技术更新,每月发送技术支持资料,极大改变了教学及学习方式。因此2011
2021-06-01 09:32:01
综合看Anker超能充系列的性价比很高,并且与不仅和iPhone12/苹果<em>Mac</em>Book很配,而且适合多设备充电需求的日常使用或差旅场景,不管是安卓还是Switch同样也能用得上它,希望这次分享能给准备购入充电器的小伙伴们有所
2021-06-01 09:31:42
除了L4WUDU与吴亦凡已经多次共事,成为了明面上的厂牌成员,吴亦凡还曾带领20XXCLUB全队参加2020年的一场音乐节,这也是20XXCLUB首次全员合照,王嗣尧Turbo、陈彦希Regi、<em>Mac</em> Ova Seas、林渝植等人全部出场。然而让
2021-06-01 09:31:34
目前应用IPFS的机构:1 谷歌<em>浏览器</em>支持IPFS分布式协议 2 万维网 (历史档案博物馆)数据库 3 火狐<em>浏览器</em>支持 IPFS分布式协议 4 EOS 等数字货币数据存储 5 美国国会图书馆,历史资料永久保存在 IPFS 6 加
2021-06-01 09:31:24
开拓者的车机是兼容苹果和<em>安卓</em>,虽然我不怎么用,但确实兼顾了我家人的很多需求:副驾的门板还配有解锁开关,有的时候老婆开车,下车的时候偶尔会忘记解锁,我在副驾驶可以自己开门:第二排设计很好,不仅配置了一个很大的
2021-06-01 09:30:48
不仅是<em>安卓</em>手机,苹果手机的降价力度也是前所未有了,iPhone12也“跳水价”了,发布价是6799元,如今已经跌至5308元,降价幅度超过1400元,最新定价确认了。iPhone12是苹果首款5G手机,同时也是全球首款5nm芯片的智能机,它
2021-06-01 09:30:45