日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

springcloud config服务端配置(一)

發布時間:2025/3/15 编程问答 32 豆豆
生活随笔 收集整理的這篇文章主要介紹了 springcloud config服务端配置(一) 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

?

?

用自己GitHub賬號在GitHub上新建一個microservicecloud-config的新的repository

?

又上一步我們得到了ssh的git地址? ? ?git@github.com:470812087/microservicecloud-config.git

本地目錄新建(F:\JAVA\ideaIU\microservicecloud-config-repository)倉庫并cloneclone git?命令?git?clone?git@github.com:470812087/microservicecloud-config.git

在本地路徑下F:\JAVA\ideaIU\microservicecloud-config-repository\microservicecloud-config 新建application.yml文件,并且utf8格式保存?(這個配置文件可以推送到github)

spring:profiles:active:- dev --- spring: profiles: dev #開發環境application:name: microservicecloud-config-atguigu-dev --- spring:profiles: test #測試環境application:name: microservicecloud-config-atguigu-test

通過git終端命令將新配置好的yml文件推送到github? ? git安裝請參考https://blog.csdn.net/ywl470812087/article/details/103098098

這個文件紅色,說明git倉庫已經發現本地倉庫目錄發生了變化

ywl@DESKTOP-FB92IS1 MINGW64 /f/JAVA/ideaIU/microservicecloud-config-repository/microservicecloud-config (master) $ git add .ywl@DESKTOP-FB92IS1 MINGW64 /f/JAVA/ideaIU/microservicecloud-config-repository/microservicecloud-config (master) $ git commit -m "init file"*** Please tell me who you are.Rungit config --global user.email "you@example.com"git config --global user.name "Your Name"to set your account's default identity. Omit --global to set the identity only in this repository.fatal: unable to auto-detect email address (got 'ywl@DESKTOP-FB92IS1.(none)')ywl@DESKTOP-FB92IS1 MINGW64 /f/JAVA/ideaIU/microservicecloud-config-repository/microservicecloud-config (master) $

因為安裝好的git客戶端后沒有設置(安裝git請參考?https://blog.csdn.net/ywl470812087/article/details/103098098)

git config --global user.email "you@example.com" git config --global user.name "Your Name"

設置之前先使用git?config --list命令查看下git配置信息

設置完成用戶名和郵箱就已經ok

?git push origin master

刷新github?我們發現一個小時之前提交的信的配置文件application.yml

點開application.yml文件我們就可以看到配置文件是否內容正常

?

總結

以上是生活随笔為你收集整理的springcloud config服务端配置(一)的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。