注:不要跨过8.16升级至8.17,这样做升级过程会报错

###################################8.2升级至8.16###########################

一,停止服务:

service gitlab stop

二,备份

cd /home/git/gitlab

sudo -u git -H bundle exec rake gitlab:backup:create RAILS_ENV=production

三,更新ruby

mkdir /tmp/ruby && cd /tmp/ruby
curl --remote-name --progress https://cache.ruby-lang.org/pub/ruby/2.3/ruby-2.3.3.tar.gz
echo '1014ee699071aa2ddd501907d18cbe15399c997d ruby-2.3.3.tar.gz' | shasum -c - && tar xzf ruby-2.3.3.tar.gz
cd ruby-2.3.3
./configure --disable-install-rdoc
make
sudo make install

sudo gem install bundler --no-ri --no-rdoc

//四,更新&安装node

五,获取最新代码

cd /home/git/gitlab

sudo -u git -H git fetch --all
sudo -u git -H git checkout -- db/schema.rb

sudo -u git -H git checkout 8-16-stable

六,更新数据库等

登陆MySQL修改权限:

GRANT REFERENCES ON `gitlabhq_production`.* TO 'git'@'localhost';

cd /home/git/gitlab

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

sudo -u git -H bundle clean

sudo -u git -H bundle exec rake db:migrate RAILS_ENV=production

sudo -u git -H bundle exec rake assets:clean assets:precompile cache:clear RAILS_ENV=production

七,更新workhorse

cd /home/git/gitlab

sudo -u git -H bundle exec rake "gitlab:workhorse:install[/home/git/gitlab-workhorse]" RAILS_ENV=production

八,更新gitlab-shell

cd /home/git/gitlab-shell

sudo -u git -H git fetch --all --tags
sudo -u git -H git checkout v4.1.1

九,更新配置文件

cp config/gitlab.yml.example config/gitlab.yml

vim config/gitlab.yml

sudo -u git -H git config --global repack.writeBitmaps true

十,更新nginx文件

vim  lib/support/nginx/gitlab-ssl

vim  lib/support/nginx/gitlab

cp lib/support/nginx/gitlab /etc/nginx/conf.d/gitlab.conf

十一,SMTP配置

vim config/initializers/smtp_settings.rb   ===>ActionMailer::Base.delivery_method = :smtp

十二,更新启动脚本

sudo cp lib/support/init.d/gitlab /etc/init.d/gitlab

十三,启动服务&检查

sudo service gitlab start
sudo service nginx restart

sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production

sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production

##################################################8.16升级至8.17##############################

一,停止服务

service gitlab stop

二,备份

三,更新ruby

ruby > 2.3    ===========》使用2.3.3

npm   2.14.12

node 4.3.0

/gcc  6.3.0====》不升级,会导致后续升级问题

四,获取最新代码

cd /home/git/gitlab

sudo -u git -H git fetch --all
sudo -u git -H git checkout -- db/schema.rb

sudo -u git -H git checkout 8-17-stable

五,更新lib等

sudo -u git -H bundle install --without postgres development test --deployment
sudo -u git -H bundle clean
sudo -u git -H bundle exec rake db:migrate RAILS_ENV=production

npm install --production

sudo -u git -H bundle exec rake gitlab:assets:clean gitlab:assets:compile cache:clear RAILS_ENV=production

六,更新workhorse

sudo -u git -H bundle exec rake "gitlab:workhorse:install[/home/git/gitlab-workhorse]" RAILS_ENV=production

七,更新gitlab-shell

cd /home/git/gitlab-shell

sudo -u git -H git fetch --all --tags

sudo -u git -H git checkout v4.1.1

八,更新配置文件

cd /home/git/gitlab

cd config

cp gitlab.yml.example gitlab.yml

vim gitlab.yml

九,git设置

sudo -u git -H git config --global repack.writeBitmaps true

十,nginx配置

cp lib/support/nginx/gitlab /etc/nginx/conf.d/gitlab_8.17

vim /etc/nginx/nginx.conf

十一,更新启动脚本

cd /home/git/gitlab

sudo cp lib/support/init.d/gitlab /etc/init.d/gitlab

十二,启动服务&检查运行

sudo service gitlab start
sudo service nginx restart
sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production
sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production

#######################################8.17升级至9.0############################

一,停止服务

service gitlab stop

二,更新ruby/node&安装yarn

ruby 更新=======》跳过   =====》见上次升级 or 上上次

更新node  =====>跳过

安装yarn:   ===(1.12.3)

curl --silent --location https://dl.yarnpkg.com/rpm/yarn.repo | sudo tee /etc/yum.repos.d/yarn.repo

sudo yum install yarn

三,获取新代码

cd /home/git/gitlab

sudo -u git -H git fetch --all
sudo -u git -H git checkout -- db/schema.rb

sudo -u git -H git checkout 9-0-stable

四,更新gitlab-shell

cd /home/git/gitlab-shell

sudo -u git -H git fetch --all --tags

sudo -u git -H git checkout v$(</home/git/gitlab/GITLAB_SHELL_VERSION)

五,更新workhorse

cd /home/git/gitlab-workhorse

sudo -u git -H git fetch --all --tags

sudo -u git -H git checkout v$(</home/git/gitlab/GITLAB_WORKHORSE_VERSION)

sudo -u git -H make

六,更新配置文件

cd /home/git/gitlab

cp config/gitlab.yml.example config/gitlab.yml

七,git配置

sudo -u git -H git config --global repack.writeBitmaps true

八,nginx配置

cp lib/support/nginx/gitlab /etc/nginx/conf.d/gitlab9.conf

vim /etc/nginx/conf.d/gitlab9.conf

vim /etc/nginx/nginx.conf

九,更新启动脚本

sudo cp lib/support/init.d/gitlab /etc/init.d/gitlab

十,更新lib等

yum install re2-devel

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

sudo -u git -H bundle clean

sudo -u git -H bundle exec rake db:migrate RAILS_ENV=production

mkdir -p /home/git/gitlab/node_modules/compression-webpack-plugin/node_modules

chown -R git:git /home/git/gitlab/node_modules/compression-webpack-plugin/node_modules

su - git

cd /home/git/gitlab

bundle exec rake yarn:install gitlab:assets:clean gitlab:assets:compile RAILS_ENV=production NODE_ENV=production   ===>成功后回到root用户

安装gitly======>暂时跳过

十一,启动服务&监控变化

service gitlab start

service nginx restart

sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production

sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production

转载于:https://www.cnblogs.com/zy1234567/p/9962508.html

gitlab8.2-8.16-8.17-9.0升级相关推荐

  1. 规则引擎选型及应用 邴越 2017-04-27 16:31:17 浏览614 评论0 HTTPS 模块 配置 string exception void input 规则引擎 摘要: 规则引擎具体执

    规则引擎选型及应用 邴越 2017-04-27 16:31:17 浏览614 评论0 HTTPS 模块 配置 string exception void input 规则引擎 摘要: 规则引擎具体执行 ...

  2. 10.15 iptables filter表小案例10.16/10.17/10.18 iptables nat表应用

    2019独角兽企业重金招聘Python工程师标准>>> 10.15 iptables filter表小案例 iptables 命令.语法总结 iptables-nvL //查看ipt ...

  3. stm32f051 TIM15、16、17 无法出PWM

    今天调了一块stm32f051,号称有11个timers,其中有6个可以产生pwm波.由于项目需要一块板子带着5个步进电机,所以需要五个单独的timer产生PWM,所以上手了这样一块板子,TIM2.T ...

  4. 预习:11.16/11.17 Apache默认虚拟主机-11.24 静态元素过期时间

    预习: 11.16/11.17 Apache默认虚拟主机 11.18 Apache用户认证 11.19/11.20 域名跳转 11.21 Apache访问日志 11.22 访问日志不记录静态文件 11 ...

  5. Spark报错Service ‘sparkWorker‘ failed after 16 retries (starting from 0)记录

    目录 问题描述 查找网络中修改案例 查找问题思路 问题解决 由此可见 问题描述 下方是我找问题的思路,如果您赶时间,请直接翻到文章最末查看即可. 启动Spark时,只有Master启动成功,其他两台W ...

  6. 分享如何在Ubuntu 16.04下CUDA8.0

    分享一篇在Ubuntu 16.04下CUDA8.0的安装过程的记录笔记. 1.安装驱动 最简单的安装方式是直接在"系统设置->软件和更新->附加驱动"中安装 这样的话, ...

  7. (转载)你好,C++(17)0.1*10不等于1.0——4.1.4 关系操作符4.1.5 逻辑操作符

    你好,C++(17)0.1*10不等于1.0--4.1.4 关系操作符4.1.5 逻辑操作符 4.1.4  关系操作符 在C++中,除了需要用算术操作符对数据进行加减乘除的算术操作之外,我们有时候还需 ...

  8. Matlab中Ksdensity()函数的用途 (2011-04-02 16:55:17)

    Matlab中Ksdensity()函数的用途 (2011-04-02 16:55:17) 转载▼ 标签: 杂谈 分类: Matlab应用 我们在统计数据处理时,经常计算一个样本的概率密度估计,也就是 ...

  9. 稳扎稳打Silverlight(17) - 2.0数据之详解DataGrid, 绑定数据到ListBox

    [索引页] [源码下载] 稳扎稳打Silverlight(17) - 2.0数据之详解DataGrid, 详解ListBox 作者:webabcd 介绍 Silverlight 2.0 详解DataG ...

  10. Need to upgrade docker package to 17.06.0+. Docker升级到最新版本

    文章目录 1. 现象 2. 查找 3. 在线卸载 4. 升级docker 5. 重启Docker 6. 设置Docker开机自启 7. 查看版本 背景: 在搭建docker私有仓库的时候出现以下错误, ...

最新文章

  1. sass的继承,混合宏,占位符的用法总结
  2. 【NLP】【七】fasttext源码解析
  3. 如何写出让同事好维护的代码?
  4. 网狐棋牌(二) CQueueServiceEvent初步分析
  5. EE JSP:使用自定义标签库生成动态内容
  6. java学习(176):第一个xml的编写
  7. HDU Integer's Power(容斥原理)
  8. nextcloud icon_聊一聊爱车吉利ICON带给我的用车感受
  9. 计算机课程教改论文,高职计算机教改的课程设计研究论文
  10. java B2B2C Springboot电子商城系统-路由网关(zuul)
  11. 【一分钟知识】七种损失函数
  12. 【热血传奇】 怪物添加(下)
  13. 真是恍然大悟啊!java从入门到精通pdf百度云
  14. 穷爸爸富爸爸的作者破产了,这本书是垃圾还是宝藏?
  15. mysql r opt_mysql_ping()以及MYSQL_OPT_RECONNECT
  16. 钉钉邮箱登录入口_清博舆情钉钉小程序上线 ,五大优势三大亮点助力工作更高效...
  17. 梁漱溟:人生的三种态度 | 合道的生活
  18. ubuntu终端如何放大字体?
  19. SQL Server视频
  20. 模拟用户登录过程,验证用户名、密码和校验码,如果全部正确提示用户登录成功,否则,提示用户相关输入错误

热门文章

  1. DevExpress Components16.2.6 Source Code 编译
  2. Data source rejected establishment of connection, message from server: Too many connections解决办法...
  3. bzoj1108[POI2007]天然气管道Gaz*
  4. Node.js项目实践:构建可扩展的Web应用
  5. Cocos2d-x3.2 重力感应
  6. vbs直接执行批处理,修改注册表
  7. WIN7 常见问题及解决方法
  8. 得到当前日期前一天的零时零分零秒及当前日的零时零分零秒
  9. Elasticsearch Aggregation 多个字段分组统计 Java API实现
  10. js 、jq强化复习