Windows 10 安裝 nexus3

Windows 10 安裝 nexus3

  1. 下載程序java

    官網:https://www.sonatype.com/,截止當前(2020/04/03)版本中nexus-3.21.1-01apache

  2. 解壓文件bootstrap

    獲得兩個文件夾 nexus-3.21.1-01sonatype-work瀏覽器

  3. 一些配置app

    nexus-3.21.1-01\etc\nexus-default.properties中修改端口號、項目根目錄等信息eclipse

    ## DO NOT EDIT - CUSTOMIZATIONS BELONG IN $data-dir/etc/nexus.properties
     ##
     # Jetty section
     application-port=8081
     application-host=0.0.0.0
     nexus-args=${jetty.etc}/jetty.xml,${jetty.etc}/jetty-http.xml,${jetty.etc}/jetty-requestlog.xml
     nexus-context-path=/
    
     # Nexus section
     nexus-edition=nexus-pro-edition
     nexus-features=\
      nexus-pro-feature
    
     nexus.hazelcast.discovery.isEnabled=true
  4. 啓動訪問編碼

    控制檯切換到 **nexus-3.21.1-01\bin\**目錄下執行 nexus.exe /run.net

    用文章寫用管理員身份啓動,請留意。因爲本人使用的管理員帳號,因此沒有這方面問題。日誌

    D:\nexus\nexus-3.21.1-01\bin>nexus.exe /run
     2020-04-14 12:13:02,163+0800 INFO  [FelixStartLevel] *SYSTEM org.sonatype.nexus.pax.logging.NexusLogActivator - start
     2020-04-14 12:13:40,749+0800 INFO  [FelixStartLevel] *SYSTEM org.sonatype.nexus.features.internal.FeaturesWrapper - Fast FeaturesService starting
     **********省略一大堆日誌**********
     2020-04-14 12:16:08,823+0800 INFO  [jetty-main-1] *SYSTEM org.eclipse.jetty.server.AbstractConnector - Started ServerConnector@2bd45844{HTTP/1.1,[http/1.1]}{0.0.0.0:8081}
     2020-04-14 12:16:08,823+0800 INFO  [jetty-main-1] *SYSTEM org.eclipse.jetty.server.Server - Started @200721ms
     2020-04-14 12:16:08,823+0800 INFO  [jetty-main-1] *SYSTEM org.sonatype.nexus.bootstrap.jetty.JettyServer -
     -------------------------------------------------
    
     Started Sonatype Nexus OSS 3.21.1-01
    
     -------------------------------------------------

    若是沒修改端口和項目根目錄,則瀏覽器訪問 http://localhost:8081/ ,若修改了則訪問對應的地址便可。code

  5. 登陸操做

    點擊右上角Sign in登陸,帳號爲admin,密碼的位置在sonatype-work\nexus3\admin.password文件中。登陸後系統強制要求修改密碼,修改後密碼需妥善保存,admin.password文件就不存在了。若密碼丟失,請點擊傳送門找回。

    一路點了Next,未進行其餘操做。

  6. 解決org.apache.http.conn.ConnectTimeoutException

    檢查控制檯啓動過程當中日誌會發現拋異常

    java.io.UnsupportedEncodingException: Encoding GBK is not supported yet (feel free to submit a patch)

    這個編碼問題,暫不知道怎麼解決。啓動以後訪問的過程當中會有下面異常

    org.apache.http.conn.ConnectTimeoutException: Connect to sonatype-download.global.ssl.fastly.net:443 [sonatype-download.global.ssl.fastly.net/69.63.178.13] failed: connect timed out

    能夠按下圖操做解決

    點擊Disabled,解決問題。

相關文章
相關標籤/搜索