• #3 楼 @flowerwrong 感谢热心回复的朋友,问题已解决;

    bash-3.2$./configure --with-openssl-dir=/usr/local/opt/openssl
    bash-3.2$make
    bash-3.2$make install 
    bash-3.2$ gem source -a https://gems.ruby-china.org
    https://gems.ruby-china.org added to sources
    bash-3.2$ gem sources
    *** CURRENT SOURCES ***
    
    http://rubygems.org/
    https://gems.ruby-china.org
    bash-3.2$ gem sources -r http://rubygems.org/
    http://rubygems.org/ removed from sources
    bash-3.2$ gem sources
    *** CURRENT SOURCES ***
    
    https://gems.ruby-china.org
    bash-3.2$  gem sources -u 
    source cache successfully updated
    
  • #8 楼 @flowerwrong 好的;今天都去尝试一下;非常感谢

  • #5 楼 @jasl 好的,我在 Mac 系统上 安装 gitlab 时,在安装 ruby 提示,不建议要用 rvm 来管理 ruby;所有就没有用 rvm;

  • #3 楼 @flowerwrong 好的,非常感谢;我今天在尝试一下;

  • #1 楼 @flowerwrong

    针对ruby小白的我茫然啊;
    bash-3.2$ brew info openssl
    openssl: stable 1.0.2j (bottled) [keg-only]
    SSL/TLS cryptography library
    https://openssl.org/
    /usr/local/Cellar/openssl/1.0.2a-1 (1,633 files, 12.2M)
      Poured from bottle on 2015-04-27 at 15:37:46
    /usr/local/Cellar/openssl/1.0.2e (1,646 files, 11.9M)
      Built from source on 2015-12-22 at 21:15:01
    /usr/local/Cellar/openssl/1.0.2h_1 (1,691 files, 12M)
      Poured from bottle on 2016-10-11 at 12:54:35
    /usr/local/Cellar/openssl/1.0.2j (1,695 files, 12M)
      Poured from bottle on 2016-10-14 at 17:15:04
    From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/openssl.rb
    ==> Dependencies
    Build: makedepend ✔
    ==> Options
    --universal
        Build a universal binary
    --without-test
        Skip build-time tests (not recommended)
    ==> Caveats
    A CA file has been bootstrapped using certificates from the system
    keychain. To add additional certificates, place .pem files in
      /usr/local/etc/openssl/certs
    
    and run
      /usr/local/opt/openssl/bin/c_rehash
    
    This formula is keg-only, which means it was not symlinked into /usr/local.
    
    Apple has deprecated use of OpenSSL in favor of its own TLS and crypto libraries
    
    Generally there are no consequences of this for you. If you build your
    own software and it requires this formula, you'll need to add to your
    build variables:
    
        LDFLAGS:  -L/usr/local/opt/openssl/lib
        CPPFLAGS: -I/usr/local/opt/openssl/include
        PKG_CONFIG_PATH: /usr/local/opt/openssl/lib/pkgconfig
    

    恩啊,找到以后怎么处理啊?大神

  • 按照楼主的提示,仍然错误;搞了两天一直报 ERROR: While executing gem ... (Gem::Exception)

    Unable to require openssl, install OpenSSL and rebuild ruby (preferred) or use non-HTTPS sources!!😫 😩

    操作环境:mac10.11.3;目的搭建 gitlab 服务时遇到的奇葩问题如下:

    1. Ruby Note: The current supported Ruby versions are 2.1.x and 2.3.x. 2.3.x is preferred, and support for 2.1.x will be dropped in the future.

    The use of Ruby version managers such as RVM, rbenv or chruby with GitLab in production, frequently leads to hard to diagnose problems. For example, GitLab Shell is called from OpenSSH, and having a version manager can prevent pushing and pulling over SSH. Version managers are not supported and we strongly advise everyone to follow the instructions below to use a system Ruby. Remove the old Ruby 1.8 if present:

    sudo apt-get remove ruby1.8 Download Ruby and compile it:

    mkdir /tmp/ruby && cd /tmp/ruby

    curl --remote-name --progress https://cache.ruby-lang.org/pub/ruby/2.3/ruby-2.3.1.tar.gz echo 'c39b4001f7acb4e334cb60a0f4df72d434bef711 ruby-2.3.1.tar.gz' | shasum -c - && tar xzf ruby-2.3.1.tar.gz

    cd ruby-2.3.1 ./configure --disable-install-rdoc make sudo make install

    安装完这一步后, 执行 ruby -v iMac$ ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-darwin15.3.0] gem -v iMac$ gem -v 2.5.1

    接下出现错误的地方: Install the Bundler Gem: sudo gem install bundler --no-ri --no-rdoc 一直报下面错误;💀

    RROR: While executing gem ... (Gem::Exception) Unable to require openssl, install OpenSSL and rebuild ruby (preferred) or use non-HTTPS sources!

    求大神们指点一下;查询 openssl version 时,结果:OpenSSL 0.9.8zg 14 July 2015

    相关链接:https://github.com/gitlabhq/gitlabhq/blob/master/doc/install/installation.md