Docker相关开发环境安装( 三 )


7.1全局模式
【Docker相关开发环境安装】maven的配置文件 .xml
maven-public*http://192.168.153.8:8081/repository/maven-public/alimavencentralaliyun mavenhttp://maven.aliyun.com/nexus/content/repositories/central/repo1centralHuman Readable Name for this Mirror.http://repo1.maven.org/maven2/repo2centralHuman Readable Name for this Mirror.http://repo2.maven.org/maven2/
7.2项目独享模式
项目中的pom.xml
#### 使用nexus私服nexusnexushttp://192.168.44.8:8081/repository/maven-public/true>falsenexusmy-nexus-repositoryhttp://192.168.153.8:8081/repository/maven-public/true>false#### 使用阿里云publicaliyun nexushttp://maven.aliyun.com/nexus/content/groups/public/truepublicaliyun nexushttp://maven.aliyun.com/nexus/content/groups/public/true>false
8、打包本地jar上传私服
本地jar上传到私服,有两种方式,一种是maven客户端配置,上传;一种是在管理后台手动上传 。下面分别介绍这两种方法 。
8.客户端上传 8.1.1.需要配置maven的.xm
在 标签中添加配置
nexus-releasesadminadmin123nexus-snapshotsadminadmin123
8.1.2.在项目中配置
需要在 pom文件中配置加入
nexus-releaseshttp://192.168.44.8:8081/repository/maven-releases/nexus-snapshotshttp://192.168.44.8:8081/repository/maven-snapshots/true
8.1.3.发布打包5.2私服web地址上传
进入上传页面进行上传操作
安装nacos 1、拉取镜像
docker pull nacos/nacos-server
2、挂载目录
mkdir -p /data/nacos/logs/#新建logs目录mkdir -p /data/nacos/conf/#新建配置文件vi /data/nacos/conf/application.properties#修改配置文件
3、配置持久化数据库脚本
.
# springserver.servlet.contextPath=/nacosserver.contextPath=/nacosserver.port=8848spring.datasource.platform=mysqlnacos.cmdb.dumpTaskInterval=3600nacos.cmdb.eventTaskInterval=10nacos.cmdb.labelTaskInterval=300nacos.cmdb.loadDataAtStart=falsedb.num=1db.url.0=jdbc:mysql://192.168.1.101:3306/nacos?characterEncoding=utf8&connectTimeout=10000&socketTimeout=30000&autoReconnect=true&allowPublicKeyRetrieval=true&serverTimezone=UTCdb.user=rootdb.password=123456### The auth system to use, currently only 'nacos' is supported:nacos.core.auth.system.type=nacos### The token expiration in seconds:nacos.core.auth.default.token.expire.seconds=18000### The default token:nacos.core.auth.default.token.secret.key=SecretKey012345678901234567890123456789012345678901234567890123456789### Turn on/off caching of auth information. By turning on this switch, the update of auth information would have a 15 seconds delay.nacos.core.auth.caching.enabled=falsenacos.core.auth.enable.userAgentAuthWhite=falsenacos.core.auth.server.identity.key=serverIdentitynacos.core.auth.server.identity.value=http://www.kingceram.com/post/securityserver.tomcat.accesslog.enabled=falseserver.tomcat.accesslog.pattern=%h %l %u %t"%r" %s %b %D# default current work dirserver.tomcat.basedir=## spring security config### turn off securitynacos.security.ignore.urls=/,/error,/**/*.css,/**/*.js,/**/*.html,/**/*.map,/**/*.svg,/**/*.png,/**/*.ico,/console-fe/public/**,/v1/auth/**,/v1/console/health/**,/actuator/**,/v1/console/server/**# metrics for elastic searchmanagement.metrics.export.elastic.enabled=falsemanagement.metrics.export.influx.enabled=falsenacos.naming.distro.taskDispatchThreadCount=10nacos.naming.distro.taskDispatchPeriod=200nacos.naming.distro.batchSyncKeyCount=1000nacos.naming.distro.initDataRatio=0.9nacos.naming.distro.syncRetryDelay=5000nacos.naming.data.warmup=true