$ O' W" f% `2 v# ~( C! y/ K0 V# j- Q. i D) x+ u. [
. |! X# E$ b2 C) e! ?, E5 H
ERROR: Could not find a valid gem 'bundler' (= 1.17.3), here is why:( x1 z4 ~2 p! J+ e- Y
# B% ~/ t# [. v. e8 }% }+ H! mUnable to download data from https://rubygems.org/ - Errno::ENETUNREACH: Network is unreachable - connect(2) for "api.rubygems.org" port 443 (https://api.rubygems.org/specs.4.8.gz) % y+ }6 z' N8 s 3 s+ N3 t# e8 R ; X9 S, ]. T7 `$ Y, z" t8 o9 d& n1 j+ t. ~ 1.添加国内源: ( x5 f8 g2 G& ]' C! E$ L 3 z; g5 p) }7 E- R% s% c* t ; _, P4 P0 ]& p+ Q# S: ?6 V# g / H. a. }3 m3 h S: T4 @* Lgem sources --add https://gems.ruby-china.com/ --remove https://rubygems.org/ 0 r8 I* [5 \( i9 g2 \! F" O, w ; q6 q. ?: B' y! x; O' V + F/ `$ _, t4 K% B ) F2 {' a2 P( H8 m0 {- m注意:如果之前自己瞎捣鼓已配置过源,建议先清理: * c: f4 i$ _7 r0 [ - q# N) a2 y) z3 s: f 3 q. m. X/ ]+ j& R, k$ O$ V& Y
gem sources --remove https://rubygems.org/ + T. W( l( i' ^* r8 S7 j( K3 M+ v! _9 N. A2 p. ]
gem sources --add https://gems.ruby-china.com/, m1 r7 D8 F& i' K& t
1 k- i# H/ v. p' v# m* o8 S* {- h" Q; T
0 z8 I8 k; g& _+ _0 y9 Q, [2.验证当前源: " x! A, C5 p8 I4 b' D* x8 u. e) L; u5 c. w5 i
; [$ T$ a) Z5 c7 g* T0 B
, r) ]- j; ?8 }) Dgem sources -l " S7 D- q- X" l5 Q5 v - G! p* F- H- r# e, M / f1 \+ B4 T7 t& A1 y' o # }: r; i# U1 f: F应该显示: : ^. F+ \. T' d. ?# E: h) d7 I, X/ n4 C* K# N& s {
" \% P; R3 ^% [
- g# N2 V- A! l2 T*** CURRENT SOURCES *** `& n! I! `- A- s & V" J- S- ]4 b8 @6 ?+ Phttps://gems.ruby-china.com/ " j6 T+ b: L) T1 I/ }1 f 1 S& X4 _3 L! V {+ N, b" }( w9 I- U |% }% a! A
/ {& p6 ?3 L- `" M2 j8 f5 T$ a* N: |8 _0 X2 R* U2 @
0 z" m4 A Z' Y h
cd /home/root/dldl-gm && sh restart-alpha.sh 7 h; n' K2 }4 ~. n& I H( o( p ?; f$ W$ @
! J: q6 S% U/ d. l / I- G# ]* W$ M会报错如下: & |, g2 {7 L* F6 e& {' W8 N) ]3 ^* Z1 { T4 x: ^
- O9 Y4 w5 F6 G
: O& C$ J! C4 U- n& ]8 r
Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will break this $ t/ M( L! e1 ? 3 a, w+ }8 D1 A e; s; E6 ]5 {/ sapplication for all non-root users on this machine.( `3 \4 R3 J% N. K) Q
9 x- V; ^: ^: k. T1 v# `Fetching source index from http://rubygems.org/ $ l$ ?' `6 o9 G% m' ^; }/ g- s1 q p1 }4 r
0 l+ H/ g/ L' n, n i0 |' S7 s! D
' u6 O0 X- t5 d2 @$ b
Retrying fetcher due to error (2/4): Bundler::HTTPError Could not fetch specs from http://rubygems.org/ & E4 N% Q; O5 U7 @* F& C7 I: m+ x; @# E2 P m/ w+ p& q0 Y
Retrying fetcher due to error (3/4): Bundler::HTTPError Could not fetch specs from http://rubygems.org/& E, [% r3 d, I7 ], _
l" K! _; u! _3 _0 T8 g $ P2 Q* l# w/ P0 C9 V) _: v3 i; e3 c* W7 d
Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will break this 7 s7 a- l8 H# d! L; X( `: b/ q7 s I, P; F ~& p
application for all non-root users on this machine. 7 D/ l9 g" C, U2 P j% {( o5 s, w/ t6 T$ y
Fetching gem metadata from https://gems.ruby-china.com/..........# n$ @2 ?3 y" N s
9 @; K o& o0 c, x$ w/ J7 a4 _6 H
Fetching rake 12.3.1 - M7 M9 F& A9 L , z, v! l& U4 n: G$ qInstalling rake 12.3.1 : x; S, X* F' G6 ^0 | p $ V' ?$ B( K2 ]) |4 d8 GFetching concurrent-ruby 1.0.5 5 |$ z7 u% W, e# D( e* V ) o. `% I8 G* |" l d5 q9 x+ T3 J9 M) W
% {# H# Y H, d; J/ U, i 恭喜您,这就是已经在正常安装依赖了!5 n7 _8 \$ `" D3 f7 {; k* C