どのようにlinuxサーバーの上でnpm私服(nexus)を構築しますか?
3223 ワード
1 java、maven環境をインストールする
2ダウンロードnexus
公式ダウンロードは遅すぎます。ポイント無料で住所をダウンロードします。https://download.csdn.net/download/u010792039/12097188
3ダウンロードしたファイルをサーバに提出し、解凍する。
コマンドラインcdは圧縮ファイルを格納するフォルダの下にあります。 入力:tar-zvxf nexus-2.18-01-bundle.tar.gz
4環境変数の設定
/etc/profileに以下の構成情報を追加します。
5オープンnexus
6 nexusの配置 まぜんと
アクセスアドレス:http://yourhostname:8081/nexus もしアクセスできなかったら、
ファイアウォールの停止命令を実行します。sudo systemtl stop firewalld.service&sudo systectl disable firewalld.service
maven/conf/setting.xmlファイルの配置は以下の通りです。
2ダウンロードnexus
公式ダウンロードは遅すぎます。ポイント無料で住所をダウンロードします。https://download.csdn.net/download/u010792039/12097188
3ダウンロードしたファイルをサーバに提出し、解凍する。
コマンドラインcdは圧縮ファイルを格納するフォルダの下にあります。 入力:tar-zvxf nexus-2.18-01-bundle.tar.gz
4環境変数の設定
/etc/profileに以下の構成情報を追加します。
export RUN_AS_USER=root
# ,nexus
#If you insist running as root ,than set the environment variable RUN_AS_USER=root before running this script
そして コマンドライン入力:source/etc/profile 設定を有効にする5オープンnexus
[root@izwz91h49n3mj8r232gqwez weblogic]# /weblogic/nexus-2.14.8-01/bin/nexus start
****************************************
WARNING - NOT RECOMMENDED TO RUN AS ROOT
****************************************
Starting Nexus OSS...
Started Nexus OSS.
6 nexusの配置 まぜんと
アクセスアドレス:http://yourhostname:8081/nexus もしアクセスできなかったら、
ファイアウォールの停止命令を実行します。sudo systemtl stop firewalld.service&sudo systectl disable firewalld.service
maven/conf/setting.xmlファイルの配置は以下の通りです。
nexus
*
http:// :8081/private/npm/
nexus
central
http://central
true always
true
spring-release
Spring Maven Release Repository
http://repo.springsource.org/libs-release
false
central
http://central
true always
true
nexus
releases
admin
admin123
snapshots
admin
admin123