Sonatype Nexus
Nexus는 Maven repository manager로 프로젝트 또는 기업에서 필요로 하는 내부 리포지토리 구성을 위한 도구이다.
Category
- SonatypeNexus:Apt: Sonatype Nexus의 apt Repository 설정 방법.
Blacklist IP address
Nexus uses the Jetty container and Jetty provides a handler that can be used to restrict access by IP addresses and subnets.
Attached is a sample jetty config file that allows you to configure the IP Access Handler using Nexus 2.8+.
To configure it:
- Download and store the file at
NEXUS_HOME/conf/jetty-ipaccess.xml
, with the same permissions as the other jetty files - Edit
NEXUS_HOME/conf/jetty-ipaccess.xml
, add white listed and blacklisted addresses using the syntax as documented in the javadoc. By default, all access is allowed - Edit
NEXUS_HOME/bin/jsw/conf/wrapper.conf
, and reference the new jetty file as an app parameter iewrapper.app.parameter.3=./conf/jetty-ipaccess.xml
( 3 by default, however the next available number must be used ) - restart Nexus
구체적인 설정 방법은 Jetty#IPAccessHandler 항목을 참조.
Blacklist of Nexus 3.x version
Nexus 3.x 설정 방법은 아래와 같다.
-
/opt/sonatype/nexus/etc/jetty
경로에jetty-ipaccess.xml
파일을 생성한 후 -
/opt/sonatype/nexus/etc/nexus-default.properties
파일에서nexus-args
속성에${jetty.etc}/jetty-ipaccess.xml
를 추가하면 된다. (다중 인자는,
를 사용하여 구분한다) - 그리고 Nexus를 재 부팅 한다.
Upload artifact
- How can I programmatically upload an artifact into Nexus 2?
- How to manually deploy artifacts in Nexus Repository Manager OSS 3
- Raw Repositories and Maven Sites
$ curl --fail -u admin:admin123 --upload-file foo.jar 'http://my-nexus-server.com:8081/repository/my-raw-repo/'