安装nexus repository manager oss 或pro版本时,会创建两个目录:一个目录包含运行环境及应用,通常符号链接为nexus;一个目录包含所有的配置和数据,通常为sonatype-work/nexus。升级nexus时只需要替换nexus目录,保留sonatype-work/nexus目录下所有配置和仓库。

sonatype-work/nexus及其他目录等配置通过nexus/conf/nexus.properties文件设置。

sonatype-work/nexus子目录结构:

access/

       用于存放允许访问仓库的IP地址的记录。通过网页nexus-Administration-Licensing查看

       这些临时文件创建于用户界面查询Maven依赖时。

backup/

       如果创建了定时备份配置文件的任务,该目录会定期产生包含了配置文件快照的ZIP压缩文件。每个压缩包都包含了conf/目录。(oss版本需要配置,pro版本自动备份)

broker/

       该目录及其子目录包含了SmartProxy messaging组件的后端存储

conf/

       该目录包含了所有配置。管理着仓库列表、日志配置,以及安全设置。

conf/keystore/

       保存着自动生成的key,用于Smart Proxy识别仓库管理?(identifythis repository manager for Smart Proxy usage)

db/

       如果开启了相关功能,将会存储用户token相关信息。

error-report-bundles/

       用于存储问题报告数据的集合。

felix-cache/

       存储OSGiframework Apache Felix的缓存,该框架用于仓库管理的插件体系。

health-check/

       存放缓存了的健康检查报告,报告由仓库健康检查插件产生。

indexer/ 和 indexer-pro/

       包括了所有管理下的所有仓库及仓库组的索引。索引是一个全文搜索引擎,用于搜索和索引Maven仓库。仓库管理为所有仓库维护着一个本地索引,也可以从远程仓库下载索引。

logs/

       目录下存放着nexus.log文件。该文件包含了一个仓库管理运行实例等信息。

nuget/

       Containsthe database supporting queries against NuGet repositories used for .NETpackage support.

p2/

       如果使用了pro版本的p2 仓库管理功能,该目录包含了本地缓存的p2仓库组件。

plugin-repository/

       该目录包含了所有第三方安装的插件

proxy/

       存储着远程仓库文件的数据。Eachproxy repository has a subdirectory in the proxy/attributes/ directory andevery file that the repository manager has interacted with in the remoterepository has an XML file that captures the last requested time stamp, theremote URL for a particular file, the length of the file, the digests for aparticular file, and others. If you need to backup the local cached contents ofa proxy repository, you should also back up the contents of the proxyrepository’s directory under proxy/attributes/

storage/

       存储着仓库的基本元数据。每个仓库都是一个子目录,子目录包含着仓库的组件。如果仓库是一个代理仓库,那么本地会缓存远程仓库的组件。如果仓库是一个宿主仓库,那么目录下会存储仓库的所有组件。如果需要备份仓库,备份该目录即可

support/

       Thesupport zip archive documented in Section 5.15, “Support Tools” is created andstored in this folder.

template-store/

       Containsthe Maven settings template files documented in detail in Chapter 13, ManagingMaven Settings.

timeline/

       存储着仓库管理用来存储事件及其他信息以支持内部操作的索引。用户界面通过系统展示这些内容。

tmp/

       临时存储

trash/

       在配置了定时任务来删除快照或者仓库的其他信息时,被删除的东西会存储在这个文件夹下。在用户界面点击Trash按钮来清空这个文件夹。

 

conf/目录下包含了一系列的仓库管理可以配置的文件。目录下的所有文件都能被管理员权限用户在用户界面修改。版本不同可能导致配置文件的差异。

broker.groovy

       用于配置Smart Proxy底层属性的groovy脚本

capabilities.xml

       进一步的Smart Proxy后端配置

healthcheck.properties

       仓库健康检查配置

logback.properties, logback.xml andlogback-*.xml

       日志的配置文件。用于定制日志信息的细节、日志的频率,或者将日志输出到自己定制的输出源,配置在logback-nexus.xml文件中。如果觉得log4j.properties不错,可以将其他残留文件从老版本中移除。

lvo-plugin.xml

       包含最新版本插件的配置。该xml文件存储了仓库管理用于查询检查更新版本的属性文件的位置。

nexus.xml

       大多数的配置保存在此文件中。该文件维护着仓库的列表以及所有服务器层面的配置,例如STMP配置、安全方面的、仓库组、targets、路径映射等等。

pgp.xml

       pgp加密服务器的配置

nexus-obr-plugin.properties

       pro版本的,NexusOSGi Bundle repository插件配置。

procurement.xml

       pro版本的,procurement插件配置

security-configuration.xml

       总体的安全配置

security.xml

       用户及权限的安全配置

staging.xml

       pro版本的,NexusStaging Plugin配置

 posted on 2017-03-28 21:39  TerrellChen  阅读(1265)  评论(0编辑  收藏  举报