highlight: an-old-hope
theme: github
Java服务编译过程
源码构建 | Apache Dubbo 官网2.7版本:https://cn.dubbo.apache.org/zh-cn/docsv2.7/dev/build/
mvn仓库:https://repo.maven.apache.org/
105
maven下载地址:https://dlcdn.apache.org/maven/maven-3/
上传软件包:apache-maven-3.9.0-bin.tar.gz cd /usr/local/src tar xvf apache-maven-3.9.0-bin.tar.gz
配置环境变量 vim /etc/profile ... export PATH=/usr/local/src/apache-maven-3.9.0/bin/:$PATH <--
使变量生效 source /etc/profile
查看版本 ```
查看版本
mvn -v <-- Apache Maven 3.9.0 (9b58d2bad23a66be161c4664ef21ce219c2c8584) Maven home: /usr/local/src/apache-maven-3.9.0 Java version: 1.8.0362, vendor: Private Build, runtime: /usr/lib/jvm/java-8-openjdk-amd64/jre Default locale: enUS, platform encoding: UTF-8 OS name: "linux", version: "4.15.0-29-generic", arch: "amd64", family: "unix" ``` dubbo-admin-develop下载地址:https://github.com/apache/dubbo-admin/tree/develop
配置 cd /opt unzip dubbo-admin-develop.zip
配置 ```
进到目录
cd dubbo-admin-develop/
安装说明
vim README_ZH.md
在'application.properies'中指定注册中心地址
vim dubbo-admin-server/src/main/resources/application.properties ... admin.registry.address=zookeeper://192.168.37.104:2181 admin.config-center=zookeeper://192.168.37.104:2181 admin.metadata-report.address=zookeeper://192.168.37.104:2181 构建
cd dubbo-admin-develop/
mvn clean install package -Dmaven.test.skip=true ``` 此过程要30分钟左右
```
拷贝
cd dubbo-admin-distribution/target scp dubbo-admin-0.1.jar 192.168.37.108:/opt ```
108
启动 cd /opt java -jar dubbo-admin-0.1.jar
访问 192.168.37.108:8080