2014-12-14 12 views
27

전용 서버에 gitlab을 설치하는이 자습서 [link]을 따릅니다. 내가 필요 :울퉁불퉁 설치 중 오류가 발생했습니다

sudo -u git -H bundle install --deployment --without development test postgres aws 

그러나 견고한 설치하는 동안 오류가 발생했습니다 : -

Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. 

    /usr/local/bin/ruby extconf.rb 
checking for cmake... no 
ERROR: CMake is required to build Rugged. 
*** extconf.rb failed *** 
Could not create Makefile due to some reason, probably lack of necessary 
libraries and/or headers. Check the mkmf.log file for more details. You may 
need configuration options. 

Provided configuration options: 
    --with-opt-dir 
    --without-opt-dir 
    --with-opt-include 
    --without-opt-include=${opt-dir}/include 
    --with-opt-lib 
    --without-opt-lib=${opt-dir}/lib 
    --with-make-prog 
    --without-make-prog 
    --srcdir=. 
    --curdir 
    --ruby=/usr/local/bin/ruby 


    Gem files will remain installed in /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/rugged-0.21.2 for inspection. 
    Results logged to /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/rugged-0.21.2/ext/rugged/gem_make.out 
    An error occurred while installing rugged (0.21.2), and Bundler cannot continue. 
    Make sure that `gem install rugged -v '0.21.2'` succeeds before bundling. 

그래서 내가 견고한 설치> 내가 CMake & 설정-PKG 설치 :

/home/git/gitlab$ sudo gem install rugged 
Building native extensions. This could take a while... 
Successfully installed rugged-0.21.2 
Parsing documentation for rugged-0.21.2 
unable to convert "\xC0" from ASCII-8BIT to UTF-8 for lib/rugged/rugged.so, skipping 
1 gem installed 

을하지만 나던 변경 사항 :

Errno::EACCES: Permission denied - /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/rugged-0.21.2/LICENSE 
An error occurred while installing rugged (0.21.2), and Bundler cannot continue. 
Make sure that `gem install rugged -v '0.21.2'` succeeds before bundling. 

어떤 아이디어?

+0

은'git' 사용자가 읽을 수'/ 홈/git/gitlab/vendor/bundle/ruby ​​/ 2.0.0/gems/rugged-0.21.2/LICENSE' (그가해야할까요?) 왜냐하면 당신은'sudo gem install rugged'을 설치하지 않았기 때문에 그들은 루트가 소유하고있을 수 있습니다. –

+0

당신은 [gitlab omnibus 패키지] (https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/README.md)를 사용하여 우분투에 GitLab을 설치하는 훨씬 쉬운 방법이 있습니다 – PierreF

답변

38

먼저 설치하십시오 cmake : 다음

sudo apt-get install cmake 

명령 반복이 URL을 참조하시기 바랍니다 나중에

sudo -u git -H bundle install --deployment --without development test postgres aws 
+3

저에게, 'sudo apt-get install cmake '를 실행하면 충분했다. – lucke84

+0

그것도 나를 위해 일하고, 감사합니다 –

+0

이것은'gem 'github-linguist''를 내'github-linguist '라고 사용하려고 할 때 내 문제''gem install rugged -v'0.25.0b2''이 번들링되기 전에 성공했는지 확인했다. 레일에있는'Gemfile'. 건배. –

3

나에게 보석은 pkg-config가 빠져있는 의존성에 대해 불평하고 있었다. 그래서 나는했다 :

sudo apt-get install pkg-config 

그 후 다음

sudo gem install rugged -v '0.22.2' 

, 내가 gitlab과 내 이전 버전으로 되돌아 업그레이드를위한 스크립트를 다시 실행합니다. gitlab의

내 이전 버전이 6.9.2와 OSX를 들어 업그레이드 된 버전 8.0.5

+0

나는 같은 사건을 겪었습니다. 감사합니다. –

36

당신이 사제를 사용하는 경우였다

brew install cmake 
bundle install