Reverse proxy

 

nexus manager https

  1. keytool 로 생성 Generating Keys and Certificates with JDK’s keytool

    keystore 파일은 nexus 설치 폴더의 etc/ssl/keystore.jks 로 존재해야 함

    keytool -keystore keystore.jks -alias jetty -genkey -keyalg RSA -sigalg SHA256withRSA
    CODE

  2. Generating a CSR with keytool

    keytool -certreq -alias jetty -keystore keystore.jks -file jetty.csr
    CODE
  3. csr 을 보내서 인증서 발급(OpenSSL 로 ROOT CA 생성 및 SSL 인증서 발급 참고)
  4. 발급받은 인증서의 ROOT CA(예: lesstif-root.crt) 를 keystore 에 등록

    keytool -keystore keystore.jks -import -alias lesstif-ca -file lesstif-root.crt) -trustcacerts
    CODE
  5. etc/jetty/jetty-https.xml 편집

    <Set name="KeyStorePassword">OBF:1v2j1uum1xtv1zej1zer1xtn1uvk1v1v</Set>
    <Set name="KeyManagerPassword">OBF:1v2j1uum1xtv1zej1zer1xtn1uvk1v1v</Set>
    <Set name="TrustStorePath"><Property name="ssl.etc"/>/keystore.jks</Set>
    <Set name="TrustStorePassword">OBF:1v2j1uum1xtv1zej1zer1xtn1uvk1v1v</Set>
    XML

    OBF 는 난독화하는 옵션이고 plain text 로 설정하려면 OBF: 를 제거하고 등록

    <Set name="KeyStorePassword">changeit</Set>
    <Set name="KeyManagerPassword">changeit</Set>
    <Set name="TrustStorePath"><Property name="ssl.etc"/>/keystore.jks</Set>
    <Set name="TrustStorePassword">changeit</Set>
    CODE
  6. nexus-default.properties 설정

    nexus-args=${jetty.etc}/jetty.xml,${jetty.etc}/jetty-http.xml,${jetty.etc}/jetty-requestlog.xml,${jetty.etc}/jetty-https.xml
    application-port-ssl=8443
    CODE

    nexus-args 에 ${jetty.etc}/jetty-https.xml 추가
    application-port-ssl 에 포트 추가 

  7. 재구동후 https 로 연결하여 설정 확인