gitlab作springConfig的仓库,报错Cannot clone or checkout repository。

先上配置文件

server:
  port: 8099
  
spring: 
  application: hyl-config-server
  cloud:
    config:
      server:
        git: 
          uri: http://gitlab.hyl.com.cn/hyl/configserver.git
          username: 
          password: 
logging:
  config: classpath:logback-spring.xml
  level: 
    root: debug
  path: logs/
  file: config.log

上网看了大家的解决办法无非是两个:

1,uri没有加.git

2,需要设置skip-ssl-validation为true。

但是依然没有用。

然后我注意到我的uri是http开头的,并不是https。

然后我把这个改为https,居然可以了。。。。

这个地址是我从gitlab上直接copy下来的,不明白为什么默认显示http,而不是https。等周一问下大神。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章