Mac安装GitLab CE记录
0 REF
1 环境
1.1 查看系统版本
$ sw_vers -productVersion
10.9.5
$ system_profiler SPSoftwareDataType
Software:
System Software Overview:
System Version: OS X 10.9.5 (13F1507)
Kernel Version: Darwin 13.4.0
Boot Volume: Macintosh HD
Boot Mode: Normal
Computer Name: ...
User Name: ...
Secure Virtual Memory: Enabled
Time since boot: 12:26
创建管理员git/git,分配到git用户组中。
1.2 Ruby环境
使用RVM升级系统自带的Ruby版本:
$ curl -L get.rvm.io | bash -s stable
$ source ~/.rvm/scripts/rvm
$ rvm install 2.3.1
$ rvm use 2.3.1 --default
$ rvm list
$ rvm remove 2.3.1
安装bundle:
$ gem install bundler --no-ri --no-rdoc
2 配置
GitLab版本:8-11-stable, 使用MySQL, 初始化脚本未给默认用户git/git REFERENCES权限,需要加上.
2.1 文件组织
/Users/git
/gitlab
gitlab.default.osx
/config
database.yml
gitlab.yml
resque.yml
secrets.ym
unicorn.rb
/lib/support
/init.d/gitlab
/logrotate/gitlab
/nginx/gitlab
/log # gitlab日志
application.log
gitlab-workhorse.log
production.log
sidekiq.log
unicorn.stderr.log
unicorn.stdout.log
/gitlab-shell
config.yml
/gitlab-workhorse/
/gitlab_repositories/
/usr/local/etc/redis.conf
/etc/init.d/gitlab
/var/log/nginx/ # nginx日志
gitlab_access.log
gitlab_error.log
/usr/local/etc/nginx
nginx.conf
/servers/gitlab
2.2 文件配置
配置文件中用户目录修改为/Users/git/,
/Users/git/gitlab/config/gitlab.yml
port: 8888
/Users/git/gitlab/config/resque.yml
url: unix:/tmp/redis.sock
/Users/git/gitlab/config/unicorn.rb
listen "127.0.0.1:8888", :tcp_nopush => true
/Users/git/gitlab/lib/support/nginx/gitlab
gitlab_workhorse_options="-listenUmask 0 -listenNetwork unix -listenAddr $socket_path/gitlab-workhorse.socket -authBackend http://127.0.0.1:88 -authSocket $rails_socket -documentRoot $app_root/public"
/Users/git/gitlab-shell/config.yml
gitlab_url: http://localhost:8888/
/etc/init.d/gitlab(同/Users/git/gitlab/lib/support/nginx/gitlab)
gitlab_workhorse_options="-listenUmask 0 -listenNetwork unix -listenAddr $socket_path/gitlab-workhorse.socket -authBackend http://127.0.0.1:8888 -authSocket $rails_socket -documentRoot $app_root/public"
/usr/local/etc/nginx/nginx.conf
# 注释掉http.server
/usr/local/etc/nginx/servers/gitlab
listen 0.0.0.0:8888 default_server;
listen [::]:8888 default_server;
3 构建和启停命令
- 构建
涉及gitlab的用git/git用户执行.
# 安装gitlab
$ cd ~/gitlab
$ bundle install --deployment --without development test postgres aws kerberos
# 安装gitlab-shell
$ cd ~/gitlab
$ bundle exec rake gitlab:shell:install[v3.4.0] REDIS_URL=unix:/tmp/redis.sock RAILS_ENV=production
# 安装gitlab-workhorse
$ cd ~/gitlab-workhorse
make
# 初始化gitlab数据库等
$ cd ~/gitlab/
$ bundle exec rake gitlab:setup RAILS_ENV=production
检查应用状态
cd ~/gitlab/ bundle exec rake gitlab:env:info RAILS_ENV=production
GitLab
$ sudo sh /etc/init.d/gitlab start $ sudo sh /etc/init.d/gitlab stop $ sudo sh /etc/init.d/gitlab restart
Redis
$ launchctl load ~/Library/LaunchAgents/homebrew.mxcl.redis.plist ## or $ restart: brew services restart redis
Nginx
$ sudo nginx $ sudo nginx -s stop $ sudo nginx -t # 验证配置
4 使用
GitLab访问
http://localhost:8888/
Git clone
$ git clone http://localhost:8888/zhoujiagen/BookApplication.git Cloning into 'BookApplication'... remote: Counting objects: 1329, done. remote: Compressing objects: 100% (703/703), done. remote: Total 1329 (delta 580), reused 1325 (delta 579) Receiving objects: 100% (1329/1329), 3.75 MiB | 0 bytes/s, done. Resolving deltas: 100% (580/580), done. Checking connectivity... done.
Mac安装GitLab CE记录的更多相关文章
- 安装gitlab ce
切换到root用户,安装相关依赖 yum install curl policycoreutils openssh-server openssh-clients service sshd restar ...
- 20160512关于mac安装caffe的记录
记得2015年在mac系统上安装过一次caffe,非常顺利,但是最近群里许多同学反映mac安装caffe出现了各种问题,同时我也在帮助别人安装caffe的时候也遇到了一些坑,不再像以前这么顺利了.估计 ...
- ubunut18.04 下安装 gitlab ce版,使用清华源
gitlab官方的ubuntu安装说明 https://about.gitlab.com/install/#ubuntu 该安装说明介绍的是gitlab-ee版本 按照该说明也能安装gitlab-ce ...
- Mac安装appium 问题记录
执行脚本报错:Xcode version [object Object] is not yet supported 原因:Xcode8以上的版本不支持Appium-1.5.3版本
- 在MAC上安装gitlab
转载引用:https://www.cnblogs.com/floodwater/p/10138265.html 1.安装docker 2.安装gitlab-ce 1.安装docker 下载地址: ht ...
- centos 6.5安装GitLab全过程和问题记录
GitLab,是一个使用 Ruby on Rails 开发的开源应用程序,与Github类似,能够浏览源代码,管理缺陷和注释,非常适合在团队内部使用. 官方只提供了Debian/Ubuntu系统下的安 ...
- Mac OSX安装 GitLab 5.x
1)安装mac 2) 创建git用户和git组 4) 安装XCode 5) 安装命令行组件 6) 安装 Home brew $ ruby -e "$(curl -fsSL https://r ...
- Python For Mac 开发环境安装 以及问题记录
Python For Mac 开发环境安装记录 把自己安装的过程记录一下,亲测可用 1.Python3环境安装(转载http://www.cnblogs.com/meng1314-shuai/p/90 ...
- 记录Ubuntu 16.04 安装Docker CE
一.Docker的两个版本 Docker有两个版本: 社区版(CE) 企业版(EE) Docker Community Edition(CE)非常适合希望开始使用Docker并尝试使用基于容器的应用程 ...
随机推荐
- ORCALE复制表结构
1.oracle 复制表结构 不要内容 create table 表1 as select * from 表2 where 1=2 2.oracle 复制表结构 要内容 create table 表1 ...
- C++11 变长模版和完美转发实例代码
C++11 变长模版和完美转发实例代码 #include <memory>#include <iostream>#include <vector>#include ...
- 使用VisualVM进行性能分析及调优(转)
VisualVM 是一款免费的\集成了多个 JDK 命令行工具的可视化工具,它能为您提供强大的分析能力,对 Java 应用程序做性能分析和调优.这些功能包括生成和分析海量数据.跟踪内存泄漏.监控垃圾回 ...
- Bootstrap <基础二十九>面板(Panels)
Bootstrap 面板(Panels).面板组件用于把 DOM 组件插入到一个盒子中.创建一个基本的面板,只需要向 <div> 元素添加 class .panel 和 class .pa ...
- js判断是否是移动端 访问移动端网址
1以下为代码,可放置在网站foot底部文件,或者haead顶部文件,建议将代码放在网站顶部,这样可以实现手机访问立即跳转! <script src="http://siteapp.ba ...
- MicroERP开发技术分享:技术选型
为什么要想起开发一个近似一套完整的ERP软件呢,原因有二:一是想在空闲时间把以前的进销存软件丰富一下,结果越搞越大了:二是这些年光搞C#了,不想把VB6忘光了 非微软的东西还真没时间去学,也有主要原因 ...
- android退出MainActivity后onDestroy不回调
问题:有时点击back键,退出MainActivity后,app已不可见,但是onDestroy却没有被调用. 原因: 1. onBackPressed被覆盖 @Override public voi ...
- php 错误堆栈
ob_start(); debug_print_backtrace(); $errpr = ob_get_clean();
- android 测试 Monkey 和 MonkeyRunner 的使用
一.Monkey的使用 Monkey使用起来比较简单,简而言之就是模拟手机点击效果,随机发送N个点击动作给手机,主要对于程序的稳定和承受压力的测试. 1.首先连接上你的手机或者启动模拟器: 2.运行C ...
- DotNetBar for Windows Forms 11.8.0.8冰河之刃重打包版
关于 DotNetBar for Windows Forms 11.8.0.8_冰河之刃重打包版 基于 官方原版的安装包 + http://www.cnblogs.com/tracky 提供的补丁DL ...