2013-04-30 07:29:30 +00:00
|
|
|
# From 4.1 to 4.2
|
|
|
|
|
2014-04-24 22:48:22 +00:00
|
|
|
## 1. Stop server & Resque
|
2013-04-30 07:29:30 +00:00
|
|
|
|
|
|
|
sudo service gitlab stop
|
|
|
|
|
2014-04-24 22:48:22 +00:00
|
|
|
## 2. Update code & DB
|
2013-04-30 07:29:30 +00:00
|
|
|
|
|
|
|
```bash
|
2013-05-07 02:12:02 +00:00
|
|
|
|
|
|
|
#Set the working directory
|
|
|
|
cd /home/gitlab/gitlab/
|
|
|
|
|
2013-04-30 07:29:30 +00:00
|
|
|
# Get latest code
|
2013-10-02 07:29:40 +00:00
|
|
|
sudo -u gitlab -H git fetch
|
2013-04-30 07:29:30 +00:00
|
|
|
|
2013-10-02 07:29:40 +00:00
|
|
|
sudo -u gitlab -H git checkout 4-2-stable
|
2013-04-30 07:29:30 +00:00
|
|
|
|
|
|
|
# Install libs
|
2013-10-02 07:29:40 +00:00
|
|
|
sudo -u gitlab -H bundle install --without development test postgres --deployment
|
2013-04-30 07:29:30 +00:00
|
|
|
|
|
|
|
# update db
|
2013-10-02 07:29:40 +00:00
|
|
|
sudo -u gitlab -H bundle exec rake db:migrate RAILS_ENV=production
|
2013-04-30 07:29:30 +00:00
|
|
|
|
|
|
|
```
|
|
|
|
|
2014-04-24 22:48:22 +00:00
|
|
|
## 3. Check GitLab's status
|
2013-04-30 07:29:30 +00:00
|
|
|
|
|
|
|
```bash
|
|
|
|
sudo -u gitlab -H bundle exec rake gitlab:check RAILS_ENV=production
|
|
|
|
```
|
|
|
|
|
2014-04-24 22:48:22 +00:00
|
|
|
## 4. Start all
|
2013-04-30 07:29:30 +00:00
|
|
|
|
|
|
|
sudo service gitlab start
|