8000 GitHub - tiaotiao97/Nexus3Plugin
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

tiaotiao97/Nexus3Plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Nexus3Plugin

介绍

项目是Nexus3的插件demo,参考snyk的Nexus3插件编写。运行在Nexus OSS 3.49.0-02 测试,如果需要运行在其他版本下,需要修改pom中nexus-plugins依赖为相应版本(https://mvnrepository.com/artifact/org.sonatype.nexus.plugins/nexus-plugins)

<parent>
    <groupId>org.sonatype.nexus.plugins</groupId>
    <artifactId>nexus-plugins</artifactId>
    <version>3.37.3-02</version>
</parent>

打包

Nexus3支持的插件格式为 kar,使用bundle打包。在pom中已经配置好 7F84 bundle的maven插件。打包时只需在pom目录下执行命令即可

mvn -PbuildKar clean install

打包完成后会在target目录中看到后缀为kar的插件包

部署

将kar包直接放置到Nexus服务器的 /opt/sonatype/nexus/deploy目录下即可完成插件部署,无需重启。

在Nexus后台 System/Bundles页面中,可以看到我们部署的插件。

image

使用

进入Nexus后台 System/Capabilities页面中,点击 create capability进入创建页面,

image

在插件列表中选择Custom Security Configuration

image

再点击创建就可以了。

image

创建好可以在System/Capabilities页面中看到,点进去能看到详情:

image

可以点击按钮进行功能的启用、停用和删除。

参考

https://help.sonatype.com/repomanager3/integrations/bundle-development/installing-bundles

https://github.com/snyk/nexus-snyk-security-plugin

https://docs.snyk.io/integrations/gatekeeper-plugins/nexus-repository-manager-gatekeeper-plugin

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

0