offline dev environment guide

 private no internet access


  • eclipse
  • maven
  • nexus

1. 이클립스 p2 복제 







1.1 도스창에서 아래 명령 실행

eclipsec.exe -nosplash -verbose
  -application org.eclipse.equinox.p2.metadata.repository.mirrorApplication 
  -source http://download.eclipse.org/releases/neon 
  -destination file:D:/dev/repo/eclipse-neon


eclipsec.exe -nosplash -verbose 
  -application org.eclipse.equinox.p2.artifact.repository.mirrorApplication 
  -source http://download.eclipse.org/releases/neon 
  -destination file:D:/dev/repo/eclipse-neon





다운로드가 완료 되면 neon 기준으로 6.35 G 정도 나온다.


2.Maven Repository Replication


2.1 wget 을 이용해 다운로드



  • 다운로드 http://gnuwin32.sourceforge.net/packages/wget.htm
  • 도스창에서 아래 명령 실행


wget --mirror -p -r --no-parent http://repo.maven.apache.org/maven2/ -e robots=off -U "Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36"


  • index.html 삭제


del /s index.html

  • maven2 폴더 루트에 있는 파일들만 삭제 , 폴더 구조는 그대로 둔다.


2.4 lftp 이용 해 다운로드

 https://nwgat.ninja/lftp-4-7-5-for-windows/

https://f001.backblazeb2.com/file/nwgat-cdn/lftp/win32/lftp-4.7.5.win32-openssl.zip
https://f001.backblazeb2.com/file/nwgat-cdn/lftp/win64/lftp-4.7.5.win64-openssl.zip


lftp http://repo.maven.apache.org/maven2 mirror --no-empty-dirs --parallel=3 . mvn.repo
https://stackoverflow.com/questions/2439891/downloading-complete-maven-remote-repository-to-local-repository

[BackStreet Browser]
홈페이지 : http://www.spadixbd.com/backstreet/
다운로드 : http://www.convertjunction.com/download/bs.exe


3. nexus 설치

3.1 설치
https://www.sonatype.com/nexus-repository-oss 에서 다운로드 한다.

c:/dev/nexus-2.14.4-03-bundle 에 압축을 푼다.

cmd 를 관리자 권한으로 실행 한다.

cd C:\dev\nexus-2.14.4-03-bundle\nexus-2.14.4-03\bin
nexus install
nexus start

브라우저에서 확인 한다.
http://localhost:8081/nexus

id : admin
pw: admin123

3.2 레파지토리 추가

왼쪽 메뉴에서 Repositories 를 선택
add 버튼으로 추가

repository id: maven-central
repository name : maven central
repository type : hosted

3.3 파일 복사
C:\dev\nexus-2.14.4-03-bundle\sonatype -work\storage\maven-central

폴더에 2번에서 다운로드 받은 폴더 복사

3.4 다시 넥서스 관리 콘솔로 이동 후 레파지토리 이름에 마우스 오른쪽 버튼을
눌러 rebuild metadata 메뉴를 클릭한다.


4. nexus p2 추가

다음 가이드 참고 하여 셋팅 함
* https://books.sonatype.com/nexus-book/reference/p2-sect-intro.html

4.1. nexus-p2-repository-plugin 번들 다운로드 


http://search.maven.org 에서 검색어 입력
a:"nexus-p2-repository-plugin" AND l:"bundle"

또는 다음링크 클릭

http://search.maven.org/#search|ga|1|a%3A%22nexus-p2-repository-plugin%22%20AND%20l%3A%22bundle%22


http://search.maven.org/remotecontent?filepath=org/sonatype/nexus/plugins/nexus-p2-repository-plugin/2.14.4-03/nexus-p2-repository-plugin-2.14.4-03-bundle.zip

4.2. nexus-p2-bridge-plugin 번들 다운로드


http://search.maven.org 에서 검색어 입력
검색어 : a:"nexus-p2-bridge-plugin" AND l:"bundle"

http://search.maven.org/#search|ga|1|a%3A%22nexus-p2-bridge-plugin%22%20AND%20l%3A%22bundle%22

http://search.maven.org/remotecontent?filepath=org/sonatype/nexus/plugins/nexus-p2-bridge-plugin/2.14.4-03/nexus-p2-bridge-plugin-2.14.4-03-bundle.zip

4.3 Extract the two files 

into sonatype-work/nexus/plugin-repository and restart the repository manager.



댓글