MeterSphere windows環境本地搭建
開發文檔地址:https://metersphere.io/docs/dev_manual/
MeterSphere 源碼地址:https://github.com/metersphere/metersphere
源碼拉取
從“github”源碼地址中 下載 master zip包,本地解壓。
安裝mysql
官方文檔對mysql版本有要求,因此要與官網匹配
安裝kafka:https://www.cnblogs.com/lnice/p/9668750.html
安裝zookeeper:https://www.cnblogs.com/qiuqiu2021/p/15063574.html
啟動 zookeeeper,不關閉cmd
zkserver
單開cmd啟動 kafka ,不關閉cmd
.\bin\windows\kafka-server-start.bat .\config\server.properties
創建topics
安裝依賴
cd metersphere/frontend
#安裝前端依賴
npm install
#構建dist
npm run build
執行 npm run build 報錯
'export' 不是內部或外部命令,也不是可運行的程序
或批處理文件。
是因為
export
命令是Linux系統
命令用來設置或顯示
環境變量,windows系統
中沒有這個命令
我們可以使用set
命令來替代
package.json 文件中 export 改成 set 即可
#啟動前端項目 ide Terminal中先進入到 metersphere\frontend項目,然后執行
npm run serve
運行后端項目
運行 Application
前后端啟動成功后
訪問:http://localhost:8080/login 登錄
以上是本人在搭建過程中的流水記錄,文中有的鏈接是我自己文章記錄,有的是看其他博主寫的比較好的總結轉載,如有詳細問題歡迎討論