]>
Commit | Line | Data |
---|---|---|
97728af5 | 1 | #!/bin/sh |
1e201ece ER |
2 | # Frontend to Gitlab Rake tasks |
3 | # | |
4 | # http://docs.gitlab.com/ce/raketasks/ | |
5 | # | |
97728af5 ER |
6 | set -e |
7 | ||
8 | # Unset ENV variables that might interfere with | |
9 | # omnibus-gitlab ruby env (looking at you rvm) | |
10 | for ruby_env_var in RUBYOPT \ | |
11 | BUNDLE_BIN_PATH \ | |
12 | BUNDLE_GEMFILE \ | |
13 | GEM_PATH \ | |
14 | GEM_HOME | |
15 | do | |
16 | unset $ruby_env_var | |
17 | done | |
18 | ||
f7036eee ER |
19 | # Rake with no params does nothing useful |
20 | # (currently it switches env production->test and then fails) | |
21 | # so instead show defined tasks | |
22 | test $# = 0 && set -- -T | |
23 | ||
34df8417 | 24 | cd /usr/lib/gitlab |
caa3e1fa | 25 | exec sudo -u git bundle exec rake RAILS_ENV=production "$@" |